VaKeR CYBER ARMY
Logo of a company Server : Apache/2.4.41 (Ubuntu)
System : Linux absol.cf 5.4.0-198-generic #218-Ubuntu SMP Fri Sep 27 20:18:53 UTC 2024 x86_64
User : www-data ( 33)
PHP Version : 7.4.33
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Directory :  /var/www/html/libs/absol-tutor/dist/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /var/www/html/libs/absol-tutor/dist/absol-tutor.js
/******/ (function(modules) { // webpackBootstrap
/******/ 	// The module cache
/******/ 	var installedModules = {};
/******/
/******/ 	// The require function
/******/ 	function __webpack_require__(moduleId) {
/******/
/******/ 		// Check if module is in cache
/******/ 		if(installedModules[moduleId]) {
/******/ 			return installedModules[moduleId].exports;
/******/ 		}
/******/ 		// Create a new module (and put it into the cache)
/******/ 		var module = installedModules[moduleId] = {
/******/ 			i: moduleId,
/******/ 			l: false,
/******/ 			exports: {}
/******/ 		};
/******/
/******/ 		// Execute the module function
/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/
/******/ 		// Flag the module as loaded
/******/ 		module.l = true;
/******/
/******/ 		// Return the exports of the module
/******/ 		return module.exports;
/******/ 	}
/******/
/******/
/******/ 	// expose the modules object (__webpack_modules__)
/******/ 	__webpack_require__.m = modules;
/******/
/******/ 	// expose the module cache
/******/ 	__webpack_require__.c = installedModules;
/******/
/******/ 	// define getter function for harmony exports
/******/ 	__webpack_require__.d = function(exports, name, getter) {
/******/ 		if(!__webpack_require__.o(exports, name)) {
/******/ 			Object.defineProperty(exports, name, { enumerable: true, get: getter });
/******/ 		}
/******/ 	};
/******/
/******/ 	// define __esModule on exports
/******/ 	__webpack_require__.r = function(exports) {
/******/ 		if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
/******/ 			Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
/******/ 		}
/******/ 		Object.defineProperty(exports, '__esModule', { value: true });
/******/ 	};
/******/
/******/ 	// create a fake namespace object
/******/ 	// mode & 1: value is a module id, require it
/******/ 	// mode & 2: merge all properties of value into the ns
/******/ 	// mode & 4: return value when already ns object
/******/ 	// mode & 8|1: behave like require
/******/ 	__webpack_require__.t = function(value, mode) {
/******/ 		if(mode & 1) value = __webpack_require__(value);
/******/ 		if(mode & 8) return value;
/******/ 		if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
/******/ 		var ns = Object.create(null);
/******/ 		__webpack_require__.r(ns);
/******/ 		Object.defineProperty(ns, 'default', { enumerable: true, value: value });
/******/ 		if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
/******/ 		return ns;
/******/ 	};
/******/
/******/ 	// getDefaultExport function for compatibility with non-harmony modules
/******/ 	__webpack_require__.n = function(module) {
/******/ 		var getter = module && module.__esModule ?
/******/ 			function getDefault() { return module['default']; } :
/******/ 			function getModuleExports() { return module; };
/******/ 		__webpack_require__.d(getter, 'a', getter);
/******/ 		return getter;
/******/ 	};
/******/
/******/ 	// Object.prototype.hasOwnProperty.call
/******/ 	__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
/******/
/******/ 	// __webpack_public_path__
/******/ 	__webpack_require__.p = "";
/******/
/******/
/******/ 	// Load entry module and return exports
/******/ 	return __webpack_require__(__webpack_require__.s = 111);
/******/ })
/************************************************************************/
/******/ ([
/* 0 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return _; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return $; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return $$; });
/* harmony import */ var _css_default_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(117);
/* harmony import */ var _css_default_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_default_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1);



var ACore = new absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_1__[/* default */ "b"]({ creator: Object.assign({}, absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_1__[/* default */ "b"].ShareInstance.creator) });
var _ = ACore._;
var $ = ACore.$;
var $$ = ACore.$$;

/* harmony default export */ __webpack_exports__["d"] = (ACore);

/***/ }),
/* 1 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";

// EXPORTS
__webpack_require__.d(__webpack_exports__, "e", function() { return /* binding */ isDomNode; });
__webpack_require__.d(__webpack_exports__, "f", function() { return /* binding */ traceOutBoundingClientRect; });
__webpack_require__.d(__webpack_exports__, "d", function() { return /* binding */ getScreenSize; });
__webpack_require__.d(__webpack_exports__, "g", function() { return /* binding */ waitImageLoaded; });
__webpack_require__.d(__webpack_exports__, "c", function() { return /* binding */ depthClone; });
__webpack_require__.d(__webpack_exports__, "a", function() { return /* binding */ copyStyleRule; });

// UNUSED EXPORTS: FeatureClass, activeFullScreen, deactiveFullScreen, isFullScreen, fontFaceIsLoaded, waitIFrameLoaded, imageToCanvas, getScrollSize, depthCloneWithStyle, getConstructDescriptor

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/JSPath.js
var JSPath = __webpack_require__(47);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/OOP.js
var OOP = __webpack_require__(2);

// CONCATENATED MODULE: ./node_modules/absol/src/String/getFunctionName.js
/**
 * 
 * @param {Function} func 
 */
function getFunctionName(func) {
    var ret = func.toString();
    ret = ret.substr('function '.length);
    ret = ret.substr(0, ret.indexOf('('));
    return ret;
}
// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/ElementNS.js
var ElementNS = __webpack_require__(65);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/AElement.js
var AElement = __webpack_require__(8);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/ResizeSystem.js
var ResizeSystem = __webpack_require__(11);

// EXTERNAL MODULE: ./node_modules/absol/src/JSX/attribute.js
var attribute = __webpack_require__(48);

// CONCATENATED MODULE: ./node_modules/absol/src/HTML5/Dom.js








/***
 * @typedef {{"accept-charset":string, "http-equiv": string, accept : string, accesskey : string, action : string, align : string, allow : string, alt : string, async : string, autocapitalize : string, autocomplete : string, autofocus : string, autoplay : string, background : string, bgcolor : string, border : string, buffered : string, capture : string, challenge : string, charset : string, checked : string, cite : string, class : string, code : string, codebase : string, color : string, cols : string, colspan : string, content : string, contenteditable : string, contextmenu : string, controls : string, coords : string, crossorigin : string, csp : string, data : string, "data-*" : string, datetime : string, decoding : string, default : string, defer : string, dir : string, dirname : string, disabled : string, download : string, draggable : string, dropzone : string, enctype : string, enterkeyhint : string, for : string,     form : string, formaction : string, formenctype : string, formmethod : string, formnovalidate : string, formtarget : string, headers : string, height : string, hidden : string, high : string, href : string, hreflang : string, icon : string, id : string, importance : string, integrity : string, intrinsicsize : string, inputmode : string, ismap : string, itemprop : string, keytype : string, kind : string, label : string, lang : string, language : string, loading : string, list : string, loop : string, low : string, manifest : string, max : string, maxlength : string, minlength : string, media : string, method : string, min : string, multiple : string, muted : string, name : string, novalidate : string, open : string, optimum : string, pattern : string, ping : string, placeholder : string, poster : string, preload : string, radiogroup : string, readonly : string, referrerpolicy : string, rel : string, required : string, reversed : string, rows : string, rowspan : string, sandbox : string, scope : string, scoped : string, selected : string, shape : string, size : string, sizes : string, slot : string, span : string, spellcheck : string, src : string, srcdoc : string, srclang : string, srcset : string, start : string, step : string, style : string, summary : string, tabindex : string, target : string, title : string, translate : string, type : string, usemap : string, value : string, width : string, wrap : string, }} AElementAttributeDescriptor
 */

/**
 * @typedef {{"arabic-form":string,"baseline-shift": string, "accent-height": string,  "alignment-baseline": string,  "cap-height": string,  "clip-path": string,  "clip-rule": string,  "color-dinterpolation": string,  "color-interpolation-filters": string,  "color-profile": string,  "color-rendering": string,  "dominant-baseline": string,  "enable-background": string,  "fill-opacity": string,  "fill-rule": string,  "flood-color": string,  "flood-opacity": string,  "font-family": string,  "font-size": string,  "font-size-adjust": string,  "font-stretch": string,  "font-style": string,  "font-variant": string,  "font-weight": string,  "glyph-name": string,  "glyph-orientation-horizontal": string,  "glyph-orientation-vertical": string,  "horiz-adv-x": string,  "horiz-origin-x": string,  "image-rendering": string,  "letter-spacing": string,  "lighting-color": string,  "marker-end": string,  "marker-mid": string,  "marker-start": string,  "overline-position": string,  "overline-thickness": string,  "panose-1": string,  "paint-order": string,  "pointer-events": string,  "rendering-intent": string,  "shape-rendering": string,  "stop-color": string,  "stop-opacity": string,  "strikethrough-position": string,  "strikethrough-thickness": string,  "stroke-dasharray": string,  "stroke-dashoffset": string,  "stroke-linecap": string,  "stroke-linejoin": string,  "stroke-miterlimit": string,  "stroke-opacity": string,  "stroke-width": string,  "text-anchor": string,  "text-decoration": string,  "text-rendering": string,  "transform-origin": string,  "underline-position": string,  "underline-thickness": string,  "unicode-bidi": string,  "unicode-range": string,  "units-per-em": string,  "v-alphabetic": string,  "v-hanging": string,  "v-ideographic": string,  "v-mathematical": string,  "vector-effect": string,  "vert-adv-y": string,  "vert-origin-x": string,  "vert-origin-y": string,  "word-spacing": string,  "writing-mode": string,  "x-height": string,  "xlink:actuate": string,  "xlink:arcrole": string,  "xlink:href": string,  "xlink:role": string,  "xlink:show": string,  "xlink:title": string,  "xlink:type": string,  "xml:base": string,  "xml:lang": string,  "xml:space": string, accumulate:string, additive:string, allowReorder:string, alphabetic:string, amplitude:string, ascent:string, attributeName:string, attributeType:string, autoReverse:string, azimuth:string, baseFrequency:string, baseProfile:string, bbox:string, begin:string, bias:string, by:string, calcMode:string, class:string, clip:string, clipPathUnits:string, color:string, contentScriptType:string, contentStyleType:string, cursor:string, cx:string, cy:string, d:string, decelerate:string, descent:string, diffuseConstant:string, direction:string, display:string, divisor:string, dur:string, dx:string, dy:string, edgeMode:string, elevation:string, end:string, exponent:string, externalResourcesRequired:string, fill:NamedColor|Color|string, filter:string, filterRes:string, filterUnits:string, format:string, from:string, fr:string, fx:string, fy:string, g1:string, g2:string, glyphRef:string, gradientTransform:string, gradientUnits:string, hanging:string, height:string, href:string, hreflang:string, id:string, ideographic:string, in:string, in2:string, intercept:string, k:string, k1:string, k2:string, k3:string, k4:string, kernelMatrix:string, kernelUnitLength:string, kerning:string, keyPoints:string, keySplines:string, keyTimes:string, lang:string, lengthAdjust:string, limitingConeAngle:string, local:string, markerHeight:string, markerUnits:string, markerWidth:string, mask:string, maskContentUnits:string, maskUnits:string, mathematical:string, max:string, media:string, method:string, min:string, mode:string, name:string, numOctaves:string, offset:string, opacity:string, operator:string, order:string, orient:string, orientation:string, origin:string, overflow:string, path:string, pathLength:string, patternContentUnits:string, patternTransform:string, patternUnits:string, ping:string, points:string, pointsAtX:string, pointsAtY:string, pointsAtZ:string, preserveAlpha:string, preserveAspectRatio:string, primitiveUnits:string, r:string, radius:string, referrerPolicy:string, refX:string, refY:string, rel:string, repeatCount:string, repeatDur:string, requiredExtensions:string, requiredFeatures:string, restart:string, result:string, rotate:string, rx:string, ry:string, scale:string, seed:string, slope:string, spacing:string, specularConstant:string, specularExponent:string, speed:string, spreadMethod:string, startOffset:string, stdDeviation:string, stemh:string, stemv:string, stitchTiles:string, string:string, stroke:string, style:string, surfaceScale:string, systemLanguage:string, tabindex:string, tableValues:string, target:string, targetX:string, targetY:string, textLength:string, to:string, transform:string, type:string, u1:string, u2:string, unicode:string, values:string, version:string, viewBox:string, viewTarget:string, visibility:string, width:string, widths:string, x:string, x1:string, x2:string, xChannelSelector:string, y:string, y1:string, y2:string, yChannelSelector:string, z:string, zoomAndPan:string, }}  AElementNSAttributeDescriptor
 */

/***
 * @typedef {{abort:function(event:(UiEvent|Event)):void,afterprint:function(event:Event):void,animationend:function(event:AnimationEvent):void,animationiteration:function(event:AnimationEvent):void,animationstart:function(event:AnimationEvent):void,beforeprint:function(event:Event):void,beforeunload:function(event:(UiEvent|Event)):void,blur:function(event:FocusEvent):void,canplay:function(event:Event):void,canplaythrough:function(event:Event):void,change:function(event:Event):void,click:function(event:MouseEvent):void,contextmenu:function(event:MouseEvent):void,copy:function(event:ClipboardEvent):void,cut:function(event:ClipboardEvent):void,dblclick:function(event:MouseEvent):void,drag:function(event:DragEvent):void,dragend:function(event:DragEvent):void,dragenter:function(event:DragEvent):void,dragleave:function(event:DragEvent):void,dragover:function(event:DragEvent):void,dragstart:function(event:DragEvent):void,drop:function(event:DragEvent):void,durationchange:function(event:Event):void,ended:function(event:Event):void,error:function(event:(ProgressEvent|UiEvent|Event)):void,focus:function(event:FocusEvent):void,focusin:function(event:FocusEvent):void,focusout:function(event:FocusEvent):void,fullscreenchange:function(event:Event):void,fullscreenerror:function(event:Event):void,hashchange:function(event:HashChangeEvent):void,input:function(event:(InputEvent|Event)):void,invalid:function(event:Event):void,keydown:function(event:KeyboardEvent):void,keypress:function(event:KeyboardEvent):void,keyup:function(event:KeyboardEvent):void,load:function(event:(UiEvent|Event)):void,loadeddata:function(event:Event):void,loadedmetadata:function(event:Event):void,loadstart:function(event:ProgressEvent):void,message:function(event:Event):void,mousedown:function(event:MouseEvent):void,mouseenter:function(event:MouseEvent):void,mouseleave:function(event:MouseEvent):void,mousemove:function(event:MouseEvent):void,mouseover:function(event:MouseEvent):void,mouseout:function(event:MouseEvent):void,mouseup:function(event:MouseEvent):void,mousewheel:function(event:WheelEvent):void,offline:function(event:Event):void,online:function(event:Event):void,open:function(event:Event):void,pagehide:function(event:PageTransitionEvent):void,pageshow:function(event:PageTransitionEvent):void,paste:function(event:ClipboardEvent):void,pause:function(event:Event):void,play:function(event:Event):void,playing:function(event:Event):void,popstate:function(event:PopStateEvent):void,progress:function(event:Event):void,ratechange:function(event:Event):void,resize:function(event:(UiEvent|Event)):void,reset:function(event:Event):void,scroll:function(event:(UiEvent|Event)):void,search:function(event:Event):void,seeked:function(event:Event):void,seeking:function(event:Event):void,select:function(event:(UiEvent|Event)):void,show:function(event:Event):void,stalled:function(event:Event):void,storage:function(event:StorageEvent):void,submit:function(event:Event):void,suspend:function(event:Event):void,timeupdate:function(event:Event):void,toggle:function(event:Event):void,touchcancel:function(event:TouchEvent):void,touchend:function(event:TouchEvent):void,touchmove:function(event:TouchEvent):void,touchstart:function(event:TouchEvent):void,transitionend:function(event:TransitionEvent):void,unload:function(event:(UiEvent|Event)):void,volumechange:function(event:Event):void,waiting:function(event:Event):void,wheel:function(event:WheelEvent):void}} AElementEventDescriptor
 */


/***
 * @typedef AbsolConstructDescriptor
 * @property {string | function |null} tag
 * @property {CSSStyleDeclaration} style
 * @property {Array | string} extendEvent
 * @property {Array | string} class
 * @property {AElementAttributeDescriptor|AElementNSAttributeDescriptor} attr
 * @property {string|AElement | AElementNS | AbsolConstructDescriptor | string[] |AElement[] | AElementNS[] | AbsolConstructDescriptor[]} child
 * @property {string} text to create a TextNode, not Element
 * @property {AElement} elt
 * @property {AElementEventDescriptor|{}} on
 * @property {Object} props
 *
 */


/****
 *
 * @returns {AElement}
 */
var attachhookCreator = function () {
    var res = Dom.ShareInstance._({
        tag: 'img',
        class: 'absol-attachhook',
        extendEvent: ['attached'],
        style: {
            display: 'none'
        },
        attr: {
            src: ''
        },
        on: {
            error: function (event) {
                if (!this._attached && this.isDescendantOf(document.body)) {
                    this._attached = true;
                    this.emit('attached', event, this);
                }
            }
        }
    });
    res._attached = false;
    Object.defineProperty(res, 'attached', {
        get: function () {
            return this._attached;
        }
    });
    res.resetState = function () {
        this._attached = false;
        this.src = '';
    };
    return res;
};

var svgCreator = function () {
    var temp = document.createElement('div');
    temp.innerHTML = '<svg version="1.1" xmlns="http://www.w3.org/2000/svg"></svg>';
    var element = temp.childNodes[0];
    var prototypes = Object.getOwnPropertyDescriptors(AElement["a" /* default */].prototype);
    Object.defineProperties(element, prototypes);
    AElement["a" /* default */].call(element);
    return element;
};

/***
 *
 * @param {*=} option
 * @constructor
 */
function Dom(option) {
    this.defaultTag = 'div';

    option = option || {};
    this.creator = option.creator || {};

    Object.defineProperties(this.creator,
        {
            svg: {
                set: function () {
                    //do nothing
                },
                get: function () {
                    return svgCreator;
                }
            },
            attachhook: {
                set: function () {
                    //do nothing
                },
                get: function () {
                    return attachhookCreator;
                }
            }
        });


    this['$ '.trim()] = this.$.bind(this);
    this['_ '.trim()] = this._.bind(this);
    this['$' + '$'] = this.$$.bind(this);
    this.buildDom = this._;
}


Dom.prototype.fromCode = function (code) {
    code = code.trim().replace(/>\s+</gm, '><');
    var temTag = 'div';
    if (code.startsWith('<td') || (code.startsWith('<th') && !code.startsWith('<thead'))) temTag = 'tr';
    else if (code.startsWith('<tr')) temTag = 'tbody';
    else if (code.startsWith('<thead') || code.startsWith('<tbody')) temTag = 'table';
    var tempDiv = document.createElement(temTag);
    tempDiv.innerHTML = code;
    var element = tempDiv.childNodes[0];
    var prototypes = Object.getOwnPropertyDescriptors(AElement["a" /* default */].prototype);
    Object.defineProperties(element, prototypes);
    AElement["a" /* default */].call(element);
    return element;
};


/**
 * DFS
 * @param {string | AElement} query
 * @param {AElement} root
 * @param {function} onFound - return true to stop find
 * @returns {AElement | AElementNS}
 */


Dom.prototype.$ = function (query, root, onFound) {
    var res;
    if (Dom.isDomNode(query)) res = query;
    else
        res = this.select(query, root, onFound);
    if (res) this.attach(res);
    return res;
};

/***
 *
 * @type {function(string, AElement, Function): AElement}
 */
Dom.prototype.selectAttacth = Dom.prototype.$;


/**
 * DFS
 * @param {string} query
 * @param {AElement} root
 * @param {function} onFound - return true to stop find
 */
Dom.prototype.select = function (query, root, onFound) {
    root = root || document.documentElement;
    var matcher = JSPath["a" /* default */].compileJSPath(query);
    return matcher.findFirst(root, onFound);
};


var FeatureClass = {
    AElementNS: {
        constructor: ElementNS["a" /* default */],
        prototypeKeys: Object.keys(ElementNS["a" /* default */].prototype)
    },
    AElement: {
        constructor: AElement["a" /* default */],
        prototypeKeys: Object.keys(AElement["a" /* default */].prototype)
    }
};
/**
 *
 * @param {AElement | AElementNS } element
 */
Dom.prototype.attach = function (element) {
    if (element.attr) return;
    var feature = (element.getBBox && element.tagName !== 'svg') ? FeatureClass.AElementNS : FeatureClass.AElement;
    var elementConstructor = feature.constructor;
    var proto = elementConstructor.prototype;
    var prototypeKeys = feature.prototypeKeys;
    var n = prototypeKeys.length;
    var key;
    for (var i = 0; i < n; ++i) {
        key = prototypeKeys[i];
        element[key] = proto[key];
    }
    Object.assign(element, elementConstructor.prototype)
    elementConstructor.call(element);
};


Dom.prototype.makeNewElement = function (tagName) {
    return document.createElement(tagName);
};

Dom.prototype.makeNewTextNode = function (data) {
    return document.createTextNode(data);
};


/**
 *
 * @param {AbsolConstructDescriptor | string | {} } option
 * @param {boolean=} isInherited
 * @returns {AElementNS| AElement | Text}
 */
Dom.prototype._ = function (option, isInherited) {
    var res;
    var creator;
    if (Dom.isDomNode(option)) {
        res = option;
        option = {};
        /** fix reinit component */
        isInherited = true;
    }
    else {
        if (option.charAt) {
            option = option.trim();
            if (option[0] == '<') {
                res = this.fromCode(option);
                option = {};
            }
            else {
                var queryObj = JSPath["a" /* default */].parseQuery(option);
                option = {};
                option.tag = queryObj.tagName || this.defaultTag;
                if (queryObj.classList && queryObj.classList.length > 0)
                    option.class = queryObj.classList;
                if (queryObj.id) option.id = queryObj.id;
                if (queryObj.attributes) option.attr = queryObj.attributes;
            }
        }
    }

    if (option.text || option.text === '') {//is textNode
        return this.makeNewTextNode(option.text);
    }

    option.tag = option.tag || this.defaultTag;
    creator = option.tag.prototype ? option.tag : this.creator[option.tag];
    if (option.tag.prototype) option.tag = option.tag.tag;
    if (option.elt) {
        res = this._(option.elt);
    }
    else {
        if (!res) {
            if (creator) {
                if (creator.render) {
                    res = creator.render(option.data);
                }
                else {
                    res = creator(option.data);
                }

            }
            else {
                res = this.makeNewElement(option.tag);
                Object.assign(res, option.data);
            }
        }
    }

    this.attach(res);

    if (creator) {
        res._azar_extendTags = res._azar_extendTags || {};
        res._azar_extendTags[option.tag] = creator;
        creator.property && Object.defineProperties(res, creator.property);
        creator.prototype && OOP["a" /* default */].extends(res, creator.prototype);
        creator.attribute && res.defineAttributes(creator.attribute);
        if (creator.render) {
            if (creator.eventHandler) {
                res.eventHandler = res.eventHandler || {};
                var eventHandler = OOP["a" /* default */].bindFunctions(res, creator.eventHandler || creator.prototype.eventHandler);
                for (var eventHandlerKey in eventHandler) {
                    if (res.eventHandler[eventHandlerKey]) {
                        throw new Error("Same name of eventHandler[" + eventHandlerKey + "]");
                    }
                    else {
                        res.eventHandler[eventHandlerKey] = eventHandler[eventHandlerKey];
                    }
                }
            }
            creator.call(res);
        }
    }

    option.extendEvent && res.defineEvent(option.extendEvent);

    option.attr && res.attr(option.attr);
    option.on && res.on(option.on);
    option.once && res.once(option.once);
    option.class && res.addClass(option.class);
    option.style && res.addStyle(option.style);
    option.id && res.attr('id', option.id);
    if (!isInherited) res.init(option.props);
    if (option.child) {
        option.child = option.child instanceof Array ? option.child : [option.child];
        for (var i = 0; i < option.child.length; ++i) {
            res.addChild(this._(option.child[i], false, true));
        }
    }
    return res;
};

/***
 *
 * @type {function(Object, boolean): AElement}
 */
Dom.prototype.create = Dom.prototype._;


/***
 *
 * @param query
 * @param root
 * @returns {Array<AElement|AElementNS>}
 */
Dom.prototype.$$ = function (query, root) {
    var thisD = this;
    var res = [];
    this.selectAttacth(query, root, function (elt) {
        thisD.attach(elt);
        res.push(elt);
    });
    return res;
};

Dom.prototype.install = function (arg0, arg1) {
    var _this = this;
    if (arguments.length == 1) {
        if (arg0.creator && arg0.create && arg0.select) {
            // is a dom core
            var creator = arg0.creator;
            Object.keys(creator).forEach(function (key) {
                if (key.startsWith('_') || key.startsWith('$')) return;
                var func = creator[key];
                if (typeof (func) == 'function')
                    if (_this.creator[key] != func)
                        _this.creator[key] = func;
            });
        }
        else if (typeof (arg0) == 'function') {
            var name = arg0.tag || getFunctionName(arg0) || arg0.name;
            if (name) {
                this.creator[name.toLowerCase()] = arg0;
            }
            else {
                console.error('No ident name of creator function', arg0);
            }
        }
        else if (arg0 instanceof Array) {
            arg0.forEach(function (func) {
                var name = func.tag || getFunctionName(func) || func.name;
                if (name) {
                    _this.creator[name.toLowerCase()] = func;
                }
            });
        }
        else if (typeof arg0 == 'object') {
            Object.keys(arg0).forEach(function (key) {
                if (key.startsWith('_') || key.startsWith('$')) return;
                var func = arg0[key];
                if (typeof (func) == 'function')
                    if (_this.creator[key] != func)
                        _this.creator[key] = func;
            });
        }
        else {
            console.error('Unknown data', arg0);
        }
    }
    else if (arguments.length == 2) {
        if (arg0 instanceof Array) {
            if (arg1.creator) arg1 = arg1.creator;
            arg0.forEach(function (key) {
                var func = arg1[key];
                if (typeof (func) == 'function')
                    if (_this.creator[key] != func)
                        _this.creator[key] = func;
            });
        }
        else if (arg0 instanceof RegExp) {
            if (arg1.creator) arg1 = arg1.creator;
            Object.keys(arg1).forEach(function (key) {
                if (key.match(arg0)) {
                    var func = arg1[key];
                    if (typeof (func) == 'function')
                        if (_this.creator[key] != func)
                            _this.creator[key] = func;
                }
            });
        }
        else if (typeof (arg0) == 'string' && arg0.length > 0) {
            if (typeof (arg1) == 'function') {
                this.creator[arg0] = arg1;
            }
            else {
                console.error('arg1 is not a function');
            }
        }
    }
    else {
        console.error('Invalid param');
    }

    return this;
};

/***
 *
 * @param {String | null} tagName
 */
Dom.prototype.require = function (tagName) {
    return this.creator[tagName] || null;
};


/**
 *
 * @param {*} o
 * @returns {Boolean}
 */
function isDomNode(o) {
    return (
        typeof Node === "object" ? o instanceof Node :
            o && typeof o === "object" && typeof o.nodeType === "number" && typeof o.nodeName === "string"
    );
}

Dom.isDomNode = isDomNode;

/**
 * @param {AElement|Node|HTMLElement} element
 */
function activeFullScreen(element) {
    if (element.requestFullscreen) {
        element.requestFullscreen();
    }
    else if (element.mozRequestFullScreen) {
        element.mozRequestFullScreen();
    }
    else if (element.webkitRequestFullscreen) {
        element.webkitRequestFullscreen(AElement["a" /* default */].ALLOW_KEYBOARD_INPUT);
    }
    else if (element.msRequestFullscreen) {
        element.msRequestFullscreen();
    }
}

Dom.activeFullScreen = activeFullScreen;


function deactiveFullScreen() {
    if (document.exitFullscreen) {
        document.exitFullscreen();
    }
    else if (document.mozCancelFullScreen) {
        document.mozCancelFullScreen();
    }
    else if (document.webkitExitFullscreen) {
        document.webkitExitFullscreen();
    }
    else if (document.msExitFullscreen) {
        document.msExitFullscreen();
    }
}

Dom.deactiveFullScreen = deactiveFullScreen;

function isFullScreen() {
    var fullScreenElement = document.fullscreenElement ||
        document.webkitFullscreenElement ||
        document.mozFullScreenElement ||
        document.msFullscreenElement;
    return !!fullScreenElement;
}

Dom.isFullScreen = isFullScreen;

/**
 * @param {AElement|Node|HTMLElement} current
 * @returns {ClientRect}
 */
function traceOutBoundingClientRect(current) {
    var screenSize = Dom.getScreenSize();
    var left = 0;
    var right = screenSize.width;
    var top = 0;
    var bottom = screenSize.height;
    while (current) {
        var ox = AElement["a" /* default */].prototype.getComputedStyleValue.call(current, 'overflow-x') !== "visible";
        var oy = AElement["a" /* default */].prototype.getComputedStyleValue.call(current, 'overflow-y') !== "visible";
        var isHtml = current.tagName.toLowerCase() === 'html';
        if (ox || oy || isHtml) {
            var bound = current.getBoundingClientRect();
            if (ox || isHtml) {
                left = Math.max(left, bound.left);
                right = Math.min(right, bound.right);
            }
            if (oy || isHtml) {
                top = Math.max(top, bound.top);
                bottom = Math.min(bottom, bound.bottom);
            }
        }

        if (isHtml) break;
        current = current.parentElement;
    }
    return { left: left, right: right, top: top, bottom: bottom, width: right - left, height: bottom - top };
}

Dom.traceOutBoundingClientRect = traceOutBoundingClientRect;

/***
 *
 * @param {string} fontFace
 * @param {number} timeout
 * @returns {Promise<boolean>}
 */
function fontFaceIsLoaded(fontFace, timeout) {
    timeout = timeout || 0;

    var element = this.ShareInstance._({
        tag: 'span',
        style: {
            visibility: 'hidden',
            position: 'fixed',
            top: '-9999px',
            left: '-9999px',
            'font-size': '256px'

        }, props: {
            innerHTML: "Test string long long long"
        }
    });
    element.addTo(document.body);
    return element.afterAttached().then(function () {
        var lastOffsetWidth = element.getBoundingClientRect().width;
        element.addStyle('font-family', fontFace);
        return new Promise(function (resolve, reject) {
            function check(remainTime) {
                if (remainTime < 0) {
                    resolve(false);
                    element.selfRemove();
                }
                else
                    requestAnimationFrame(function () {
                        var currentOffsetWidth = element.getBoundingClientRect().width;
                        if (currentOffsetWidth != lastOffsetWidth) {
                            resolve(true);
                            element.selfRemove();
                        }
                        else
                            check(remainTime - 10);
                    });
            }

            check(timeout);
        });
    });
}

Dom.fontFaceIsLoaded = fontFaceIsLoaded;

/***
 *
 * @returns {{width: number, WIDTH: number, HEIGHT: number, height: number}}
 */
function getScreenSize() {
    var width = window.innerWidth ||
        document.documentElement.clientWidth ||
        document.body.clientWidth;

    var height = window.innerHeight ||
        document.documentElement.clientHeight ||
        document.body.clientHeight;

    return { WIDTH: width, HEIGHT: height, width: width, height: height };
}

Dom.getScreenSize = getScreenSize;

/***
 *
 * @param {HTMLImageElement} img
 * @param {number=} timeout
 * @returns {Promise<void>}
 */
function waitImageLoaded(img, timeout) {
    var isLoaded = true;
    if (!img.complete) {
        isLoaded = false;
    }
    if (img.naturalWidth === 0) {
        isLoaded = false;
    }
    if (isLoaded) return Promise.resolve();
    return new Promise(function (rs) {
        if (img.addEventListener) {
            img.addEventListener('load', rs, false);
        }
        else {
            img.attachEvent('onload', rs, false);
        }
        setTimeout(rs, timeout || 5000);
    });
    // No other way of checking: assume it’s ok.
}

Dom.waitImageLoaded = waitImageLoaded;


/***
 *
 * @param {HTMLIFrameElement| Worker} iframe
 * @returns {Promise}
 */
function waitIFrameLoaded(iframe) {
    return new Promise(function (rs, rj) {
        if (document.all) {
            iframe.onreadystatechange = function () {
                if (iframe.readyState === "complete" || iframe.readyState === "loaded")
                    rs();
            };
        }
        else {
            iframe.onload = rs;
        }
        setTimeout(rs, 5000)
    });
}

Dom.waitIFrameLoaded = waitIFrameLoaded;

/***
 *
 * @param {Image} element
 * @returns {Promise<HTMLCanvasElement>}
 */
function imageToCanvas(element) {
    if (typeof element == 'string') {
        element = Dom.ShareInstance.$(element);
    }
    if (element.tagName.toLowerCase() === 'img') {
        var preRender = Dom.ShareInstance._('div');
        preRender.addStyle({
            position: 'fixed',
            top: '0',
            left: '0',
            zIndex: '-10000',
            opacity: '0'
        }).addTo(document.body);

        var canvas = document.createElement("canvas");
        preRender.addChild(canvas);


        return Dom.waitImageLoaded(element).then(function () {
            canvas.width = element.width;
            canvas.height = element.height;
            var context = canvas.getContext("2d");
            context.drawImage(element, 0, 0);
            preRender.selfRemove();
            return canvas;
        });
    }
    else {
        throw new Error("AElement must be image");
    }
}

Dom.imageToCanvas = imageToCanvas;


Dom.ShareInstance = new Dom();


Dom.scrollWidthPromise;

Dom.documentReady = new Promise(function (resolve) {
    if (document.body) {
        resolve();
    }
    else {
        window.addEventListener("load", resolve);
    }
});

function getScrollSize() {
    if (!Dom.scrollWidthPromise)
        Dom.scrollWidthPromise = new Promise(function (resolve) {
            function prerender() {
                var parent = Dom.ShareInstance._({
                    style: {
                        'z-index': '-100',
                        opacity: '0',
                        width: '100px',
                        height: '100px',
                        overflow: 'scroll',
                        top: '0',
                        left: '0',
                        'box-sizing': 'content-box',
                        position: 'fixed'
                    }
                })
                    .addTo(document.body);
                var child = Dom.ShareInstance._({ style: { width: '100%', height: '100%' } }).addTo(parent);
                requestAnimationFrame(function () {
                    var parentBound = parent.getBoundingClientRect();
                    var childBound = child.getBoundingClientRect();
                    resolve({
                        width: parentBound.width - childBound.width,
                        height: parentBound.height - childBound.height
                    });
                    parent.selfRemove();
                });
            }

            Dom.documentReady.then(prerender);
        });
    return Dom.scrollWidthPromise;
}

Dom.getScrollSize = getScrollSize;


/***
 *
 * @param {(AElement|AElementNS|Node)} originElt
 * @param {function(originElt: (AElement|AElementNS|Node), originElt: (AElement|AElementNS|Node)):void } afterCloneCb
 * @return {AElement|AElementNS|Node}
 */
function depthClone(originElt, afterCloneCb) {
    /***
     *
     * @type {AElement|AElementNS|Node}
     */
    var newElt = originElt.cloneNode();//no deep
    if (originElt.childNodes) {
        /***
         *
         * @type {(AElement|AElementNS)[]}
         */
        var children = Array.prototype.map.call(originElt.childNodes, function (child) {
            return depthClone(child, afterCloneCb)
        });
        for (var i = 0; i < children.length; ++i) {
            newElt.appendChild(children[i]);
        }
    }

    return (afterCloneCb && afterCloneCb(originElt, newElt)) || newElt;
}


/***
 *
 * @param originElt
 * @returns {AElement|HTMLElement|Node}
 */
function depthCloneWithStyle(originElt, afterCloneCb) {
    return depthClone(originElt, function (originElt, newElt) {
        if (!originElt.getAttribute && !originElt.getAttributeNS) return;
        copyStyleRule(originElt, newElt);
        afterCloneCb && afterCloneCb(originElt, newElt);
    });
}

Dom.depthClone = depthClone;
Dom.depthCloneWithStyle = depthCloneWithStyle;

/***
 *
 * @param  {AElement|HTMLElement|Node}sourceElt
 * @param  {AElement|HTMLElement|Node} destElt
 * @returns  {AElement|HTMLElement|Node}
 */
function copyStyleRule(sourceElt, destElt) {
    if (!sourceElt.getAttribute && !sourceElt.getAttributeNS) return destElt;//is text node
    if (!destElt.getAttribute && !destElt.getAttributeNS) return destElt;//is text node, nothing to copy
    var cssRules = AElement["a" /* default */].prototype.getCSSRules.call(sourceElt);

    var cssKey = cssRules.reduce(function (ac, rule) {
        for (var i = 0; i < rule.style.length; ++i) {
            ac[rule.style[i]] = true;
        }
        return ac;
    }, {});
    for (var key in cssKey) {
        destElt.style[key] = AElement["a" /* default */].prototype.getComputedStyleValue.call(sourceElt, key);
    }
    return destElt;
}

Dom.copyStyleRule = copyStyleRule;

/***
 * get absol construct descriptor for HTML element only
 * @param {AElement | Text} elt
 * @returns {AbsolConstructDescriptor}
 */
function getConstructDescriptor(elt) {
    var obj = {};
    obj.tag = elt.tagName.toLowerCase();
    var classAttr = elt.getAttribute('class');
    var classList;
    if (classAttr)
        classList = Object(attribute["parseClassAttr"])(classAttr);
    if (classList && classList.length > 0)
        obj.class = classList;
    var styleAttr = elt.getAttribute('style');
    var style;
    if (styleAttr)
        style = Object(attribute["parseStyleAttr"])(styleAttr);


    var attributes = elt.attributes;
    var attNode;
    var attrName;
    var attrValue;
    var attr = {};
    var on = {};
    var props = {};
    var eventMatch, eventName;
    var propMatch, propName;
    for (var i = 0; i < attributes.length; ++i) {
        attNode = attributes[i];
        attrName = attNode.nodeName;
        attrValue = attNode.nodeValue;
        if (attrName == 'style' || attrName == 'class') continue;
        eventMatch = attrName.match(/^on(.+)/)
        if (eventMatch) {
            eventName = eventMatch[1];
            on[eventName] = new Function('event', 'sender', attrValue);
            continue;
        }
        propMatch = attrName.match(/^prop-(.+)/);
        if (propMatch) {
            propName = propMatch[1];
            props[propName] = attrValue;
            continue;
        }
        attr[attrName] = attrValue;
    }
    var key;
    for (key in style) {
        //style is not empty
        obj.style = style;
        break;
    }
    for (key in attr) {
        obj.attr = attr;
        break;
    }
    for (key in on) {
        obj.on = on;
        break;
    }
    for (key in props) {
        obj.props = props;
        break;
    }

    return obj;
}

Dom.getConstructDescriptor = getConstructDescriptor;

Dom.addToResizeSystem = function (element) {
    ResizeSystem["a" /* default */].add(element);
};

Dom.updateResizeSystem = function () {
    ResizeSystem["a" /* default */].update();
}

Dom.updateSizeUp = function (fromElt) {
    ResizeSystem["a" /* default */].updateUp(fromElt);
};


/* harmony default export */ var HTML5_Dom = __webpack_exports__["b"] = (Dom);

/***/ }),
/* 2 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
var OOP = {};

/**
 * @param {Object} object
 * @param {String} key
 * @param {Function} method
 */
OOP.overrideMethod = function (object, key, method) {
    if (object[key] === undefined) object[key] = method;
    else {
        var _superMethod = object[key];
        object[key] = (function (_superMethod, method) {
            return function () {
                var _super = this.super;
                this.super = _superMethod;
                var result = method.apply(this, arguments);
                this.super = _super;
                return result;
            };

        })(_superMethod, method);
    }
};


OOP.extends = function (object, prototype) {
    // do not use setter, getter
    for (var key in prototype) {
        if (key !== 'constructor' && key !== '__proto__') {
            if ((typeof prototype[key] == 'function')) {
                OOP.overrideMethod(object, key, prototype[key]);
            }
            else if (prototype[key] !== undefined && prototype[key] !== null) {
                object[key] = prototype[key];//just copy
            }
        }
    }
};

OOP.inherit = function (child, parent) {
    // do not use setter, getter

    Object.keys(parent).forEach(function (key) {
        if (key !== 'constructor' && (typeof parent[key] == 'function')) {
            var superMethod = parent[key];
            var currentMethod = child[key];
            if (!currentMethod) child[key] = superMethod;
            else {
                child[key] = function () {
                    var _super = this.super;
                    this.super = superMethod;
                    var result = currentMethod.apply(this, arguments);
                    this.super = _super;
                    return result;
                };
            }
        }
    });
};


OOP.drillProperty = function (topObject, botObject, keyTop, keyBot) {
    if (typeof (keyTop) == 'string') {
        keyBot = keyBot || keyTop;
        Object.defineProperty(topObject, keyTop, {
            set: function (value) {
                botObject[keyBot] = value;
            },
            get: function () {
                return botObject[keyBot];
            }
        });
    }
    else {
        if (keyTop instanceof Array) {
            for (var i = 0; i < keyTop.length; ++i) {
                OOP.drillProperty(topObject, botObject, keyTop[i], keyTop[i]);
            }
        }
        else {
            for (var key in keyTop) {
                OOP.drillProperty(topObject, botObject, key, keyTop[key]);
            }
        }
    }
};

OOP.bindFunctions = function (_this, handlers) {
    var res = {};
    for (var key in handlers) {
        res[key] = handlers[key].bind(_this);
    }
    return res;
};


OOP.inheritCreator = function (parent, child) {
    var i;
    if (child.property) {
        if (parent.property) {
            for (i in parent.property) {
                if (!child.property[i]) child.property[i] = parent.property[i];
            }
        }
    }
    for (i in parent.prototype) {
        if (!child.prototype[i]) {
            child.prototype[i] = parent.prototype[i];
        }
        else {
            child.prototype[i] = (function (superFunction, childFunction) {
                return function () {
                    var _super = this.super;
                    this.super = superFunction;
                    var result = childFunction.apply(this, arguments);
                    this.super = _super;
                    return result;
                };
            })(parent.prototype[i], child.prototype[i]);
        }
    }
};

/***
 *
 * @param {Function} constructor
 */
OOP.mixClass = function (constructor) {
    var descriptors = {};
    for (var i = 1; i < arguments.length; ++i) {
        Object.assign(descriptors, Object.getOwnPropertyDescriptors(arguments[i].prototype));
    }
    delete  descriptors.constructor;
    Object.defineProperties(constructor.prototype, descriptors);
};

/* harmony default export */ __webpack_exports__["a"] = (OOP);

/***/ }),
/* 3 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* unused harmony export eventProperties */
/* unused harmony export touchProperties */
/* unused harmony export isMouseRight */
/* unused harmony export isMouseLeft */
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return hitElement; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return copyEvent; });
/* unused harmony export copyTouch */
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return findChangedTouchByIdent; });
/* unused harmony export findTouchByIdent */
/* harmony import */ var _Code_safeThrow__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(31);


function EventEmitter() {
    if (!this._azar_extendEvents) {
        Object.defineProperty(this, '_azar_extendEvents', {
            enumerable: false,
            value: this._azar_extendEvents || { supported: {}, prioritize: {}, nonprioritize: {} }
        });
        Object.defineProperty(this, '__azar_force', {
            value: !(typeof Node === "object" ? this instanceof Node : this && typeof this === "object" && typeof this.nodeType === "number" && typeof this.nodeName === "string"),
            enumerable: false
        });
    }
}


EventEmitter.prototype.defineEvent = function (name) {
    if (name instanceof Array) {
        for (var i = 0; i < name.length; ++i)
            this._azar_extendEvents.supported[name[i]] = true;
    }
    else
        this._azar_extendEvents.supported[name] = true;
    return this;
};

EventEmitter.prototype.isSupportedEvent = function (name) {
    return this.__azar_force || !!this._azar_extendEvents.supported[name];
};


EventEmitter.prototype.emit = function (eventName, data) {
    this.fire.apply(this, arguments);
};

EventEmitter.prototype.fire = function (eventName, data) {
    var others = Array.prototype.slice.call(arguments, 1);
    if (this.isSupportedEvent(eventName)) {
        var listenerList;
        var i;
        if (this._azar_extendEvents.prioritize[eventName]) {
            listenerList = this._azar_extendEvents.prioritize[eventName].slice();
            for (i = 0; i < listenerList.length; ++i) {
                try {
                    listenerList[i].wrappedCallback.apply(this, others);
                } catch (e) {
                    Object(_Code_safeThrow__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"])(e);
                }
            }
        }

        if (this._azar_extendEvents.nonprioritize[eventName]) {
            listenerList = this._azar_extendEvents.nonprioritize[eventName].slice();
            for (i = 0; i < listenerList.length; ++i) {
                try {
                    listenerList[i].wrappedCallback.apply(this, others);
                } catch (e) {
                    Object(_Code_safeThrow__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"])(e);
                }
            }
        }
    }
    else {
        if (this.dispatchEvent) {
            var event = new Event(eventName);
            data && Object.assign(event, data);
            this.dispatchEvent(event);
        }
        else
            throw new Error("Not support event " + eventName);
    }
    return this;
};


EventEmitter.prototype.eventEmittorOnWithTime = function (isOnce, arg0, arg1, arg2) {
    if (typeof arg0 == 'object') {
        for (var key in arg0) {
            this.eventEmittorOnWithTime(isOnce, key, arg0[key]);
        }
        return this;
    }
    else {
        if (typeof arg1 == 'object') {
            return this.eventEmittorOnWithTime(isOnce, arg0, arg1.callback, arg1.cap);
        }
        else {
            var eventArr = this._azar_extendEvents[arg2 ? 'prioritize' : 'nonprioritize'][arg0] || [];
            var eventIndex = -1;
            for (var i = 0; i < eventArr.length; ++i) {
                if (eventArr[i].wrappedCallback == arg1) {
                    eventIndex = i;
                    break;
                }
            }
            if (eventIndex < 0) {
                var event = { isOnce: isOnce, eventName: arg0, callback: arg1, cap: !!arg2 };
                //wrappedCallback will be call
                if (isOnce) {
                    event.wrappedCallback = function () {
                        event.callback.apply(this, arguments);
                        this.off(event.eventName, event.wrappedCallback, event.cap);
                    };
                }
                else {
                    event.wrappedCallback = event.callback;
                }

                if (!this.isSupportedEvent(arg0)) {
                    if (this.addEventListener) {
                        this.addEventListener(arg0, event.wrappedCallback, !!arg2);
                    }
                    else {
                        this.attachEvent('on' + arg0, arg1, !!arg2);
                    }
                }

                eventArr.push(event);
                this._azar_extendEvents[arg2 ? 'prioritize' : 'nonprioritize'][arg0] = eventArr;
            }
            else {
                console.warn("dupplicate event");
            }

        }
        return this;
    }
};


EventEmitter.prototype.on = function (arg0, arg1, arg2) {
    this.eventEmittorOnWithTime(false, arg0, arg1, arg2);
    return this;
};


EventEmitter.prototype.once = function (arg0, arg1, arg2) {
    this.eventEmittorOnWithTime(true, arg0, arg1, arg2);
    return this;
};

EventEmitter.prototype.off = function (arg0, arg1, arg2) {
    if (typeof arg0 == 'object') {
        for (var key in arg0) {
            this.off(key, arg0[key]);
        }
        return this;
    }
    else {
        if (typeof arg1 == 'object') {
            return this.off(arg0, arg1.callback, arg1.cap);
        }
        else {
            var eventArr = this._azar_extendEvents[arg2 ? 'prioritize' : 'nonprioritize'][arg0] || [];
            var newEventArray = [];
            for (var i = 0; i < eventArr.length; ++i) {
                var event = eventArr[i];
                if (event.wrappedCallback == arg1) {
                    //Dont add to newEventArray
                    if (this.isSupportedEvent(arg0)) {
                    }
                    else {
                        if (this.removeEventListener) {
                            this.removeEventListener(event.eventName, event.wrappedCallback, !!event.cap);
                        }
                        else {
                            this.detachEvent('on' + event.eventName, event.wrappedCallback, !!event.cap);
                        }
                    }
                }
                else {
                    newEventArray.push(event);
                }
            }
            this._azar_extendEvents[arg2 ? 'prioritize' : 'nonprioritize'][arg0] = newEventArray;
            return this;
        }
    }

};

var eventProperties = ["altKey", "bubbles", "button", "buttons", "cancelBubble", "cancelable", "clientX", "clientY", "composed",
    "ctrlKey", "currentTarget", "defaultPrevented", "deltaMode", "deltaX", "deltaY", "deltaZ", "detail", "eventPhase",
    "explicitOriginalTarget", "isTrusted", "layerX", "layerY", "metaKey", "movementX", "movementY", "mozInputSource",
    "mozPressure", "offsetX", "offsetY", "originalTarget", "pageX", "pageY", "rangeOffset", "rangeParent", "region",
    "relatedTarget", "returnValue", "screenX", "screenY", "shiftKey", "srcElement", "target", "timeStamp", "type",
    "deltaMode", "deltaX", "deltaY", "deltaZ", 'preventDefault'];

var touchProperties = ['clientX', 'clientY', 'force', 'identifier', 'pageX', 'pageY', 'rotationAngle', 'screenX',
    'screenY', 'target'];

function isMouseRight(event) {
    var isRightMB = false;
    if ("which" in event)  // Gecko (Firefox), WebKit (Safari/Chrome) & Opera
        isRightMB = event.which == 3;
    else if ("button" in event)  // IE, Opera
        isRightMB = event.button == 2;
    return isRightMB;
}

function isMouseLeft(event) {
    var isLeftMB = false;
    if ("which" in event)  // Gecko (Firefox), WebKit (Safari/Chrome) & Opera
        isLeftMB = event.which == 1;
    else if ("button" in event)  // IE, Opera
        isLeftMB = event.button == 1;
    return isLeftMB;
}

function hitElement(element, event) {
    var current = event.target;
    while (current) {
        if (current == element) return true;
        current = current.parentElement;
    }
    return false;
}

function copyEvent(event, props) {
    var result = {};
    var key, value;
    //copy native property
    for (var i = 0; i < eventProperties.length; ++i) {
        key = eventProperties[i];
        value = event[key];
        if (value !== undefined) {
            if (typeof value == "function") {
                result[key] = event[key].bind(event);
            }
            else {
                result[key] = event[key];
            }
        }
    }
    Object.assign(result, event);
    if (props)
        Object.assign(result, props)
    if (event.changedTouches) {
        result.changedTouches = Array.prototype.map.call(event.changedTouches, function (touch) {
            return copyTouch(touch);
        });
    }
    if (event.touches) {
        result.touches = Array.prototype.map.call(event.touches, function (touch) {
            return copyTouch(touch);
        });
    }
    return result;
}

function copyTouch(touch, props) {
    var result = {};
    var key, value;
    //copy native property
    for (var i = 0; i < touchProperties.length; ++i) {
        key = touchProperties[i];
        value = touch[key];
        if (value !== undefined) {
            if (typeof value == "function") {
                result[key] = touch[key].bind(touch);
            }
            else {
                result[key] = touch[key];
            }
        }
    }
    Object.assign(result, touch);
    if (props)
        Object.assign(result, props);
    return result;
}

/***
 *
 * @param {TouchEvent} event
 * @return {Touch | null}
 */
function findChangedTouchByIdent(event, identifier) {
    if (event.changedTouches) {
        for (var i = 0; i < event.changedTouches.length; ++i) {
            if (event.changedTouches[i].identifier === identifier) {
                return event.changedTouches[i];
            }
        }
    }
    return null;
}


/***
 *
 * @param event
 * @param identifier
 * @return {Touch|null}
 */
function findTouchByIdent(event, identifier) {
    if (event.touches) {
        for (var i = 0; i < event.touches.length; ++i) {
            if (event.touches[i].identifier === identifier) {
                return event.touches[i];
            }
        }
    }
    return null;
}


EventEmitter.isMouseRight = isMouseRight;

EventEmitter.isMouseLeft = isMouseLeft;

EventEmitter.hitElement = hitElement;

EventEmitter.copyEvent = copyEvent;

EventEmitter.eventProperties = eventProperties;


/* harmony default export */ __webpack_exports__["b"] = (EventEmitter);

/***/ }),
/* 4 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "insertTextAtCursor", function() { return insertTextAtCursor; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "contenteditableTextOnly", function() { return contenteditableTextOnly; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getSelectionText", function() { return getSelectionText; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "positiveIntMod", function() { return positiveIntMod; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "measureText", function() { return measureText; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getCaretPosition", function() { return getCaretPosition; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "preventNotNumberInput", function() { return preventNotNumberInput; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "buildCss", function() { return buildCss; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "openFileDialog", function() { return openFileDialog; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "charWidth", function() { return charWidth; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "estimateWidth14", function() { return estimateWidth14; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "absCeil", function() { return absCeil; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "zeroPadding", function() { return zeroPadding; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "cleanMenuItemProperty", function() { return cleanMenuItemProperty; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "swapElt", function() { return swapElt; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "vScrollIntoView", function() { return vScrollIntoView; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "fileSize2Text", function() { return fileSize2Text; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isDateTimeFormatToken", function() { return isDateTimeFormatToken; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isRealNumber", function() { return isRealNumber; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isURLAddress", function() { return isURLAddress; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "fileAccept", function() { return fileAccept; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "addElementsBefore", function() { return addElementsBefore; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "addElementAfter", function() { return addElementAfter; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isScrolledToBottom", function() { return isScrolledToBottom; });
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_AElement__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8);



function insertTextAtCursor(text) {
    var sel, range;
    if (window.getSelection) {
        sel = window.getSelection();
        if (sel.getRangeAt && sel.rangeCount) {
            range = sel.getRangeAt(0);
            range.deleteContents();
            range.insertNode(document.createTextNode(text));
        }
    }
    else if (document.selection && document.selection.createRange) {
        document.selection.createRange().text = text;
    }
}


function contenteditableTextOnly(element, processText) {
    if (element.__contenteditableTextOnly__) return;
    element.__contenteditableTextOnly__ = true;
    element.addEventListener("paste", function (e) {
        e.preventDefault();
        if (e.clipboardData && e.clipboardData.getData) {
            var text = e.clipboardData.getData("text/plain");
            if (processText) text = processText(text)
            document.execCommand("insertHTML", false, text);
        }
        else if (window.clipboardData && window.clipboardData.getData) {
            var text = window.clipboardData.getData("Text");
            if (processText) text = processText(text)
            insertTextAtCursor(text);
        }
    });
}

function getSelectionText() {
    var text = "";
    var activeEl = document.activeElement;
    var activeElTagName = activeEl ? activeEl.tagName.toLowerCase() : null;
    if (
        (activeElTagName == "textarea") || (activeElTagName == "input" &&
            /^(?:text|search|password|tel|url)$/i.test(activeEl.type)) &&
        (typeof activeEl.selectionStart == "number")
    ) {
        text = activeEl.value.slice(activeEl.selectionStart, activeEl.selectionEnd);
    }
    else if (window.getSelection) {
        text = window.getSelection().toString();
    }
    return text;
}

/***
 *
 * @param num
 * @param maxVal
 * @return {number}
 */
function positiveIntMod(num, maxVal) {
    if (maxVal <= 0) return 0;
    if (num >= 0 && num < maxVal) {
        return Math.floor(num);
    }
    else if (num === Infinity) {
        if (maxVal === Infinity)
            return Infinity;
        else
            return 0;
    }
    else if (num < 0) {
        return (num + (Math.ceil(-num / maxVal) * maxVal)) % maxVal;
    }
    else if (num >= maxVal) {
        return Math.floor(num) % maxVal
    }
    else return 0;

}


function measureText(text, font) {
    // re-use canvas object for better performance
    var canvas = measureText.canvas || (measureText.canvas = document.createElement("canvas"));
    var context = canvas.getContext("2d");
    if (font)
        context.font = font;
    var metrics = context.measureText(text);
    return metrics;
}


function getCaretPosition(oField) {
    var iCaretPos = 0;
    if (document.selection) {
        oField.focus();
        var oSel = document.selection.createRange();
        oSel.moveStart('character', -oField.value.length);
        iCaretPos = oSel.text.length;
    }
    else if (oField.selectionStart || oField.selectionStart == '0')
        iCaretPos = oField.selectionDirection == 'backward' ? oField.selectionStart : oField.selectionEnd;
    return iCaretPos;
}


/**
 *
 * @param {AElement} elt
 */
function preventNotNumberInput(elt) {
    elt.addEventListener('keyup', function () {
        var lastValue = (elt.tagName === "DIV" || elt.tagName === "SPAN") ? elt.innerHTML : elt.attributes.value;
        var cValue = parseFloat(this.value);
        if (this.value != lastValue) {
            elt.attributes.value = cValue;
            elt.emit('change', cValue, elt);
        }
    });
    elt.addEventListener("paste", function (e) {
        e.preventDefault();
        var text = "";
        if (e.clipboardData && e.clipboardData.getData) {
            text = e.clipboardData.getData("text/plain");

        }
        else if (window.clipboardData && window.clipboardData.getData) {
            text = window.clipboardData.getData("Text");
        }
        var matched = text.match(/[+-]?([0-9]*[.])?[0-9]+/);
        if (matched) {
            this.value = matched[0];
        }
    });
    elt.addEventListener('keydown', function (event) {
        var key = event.key;
        if (key && key.length == 1 && !event.ctrlKey && !event.altKey) {
            if (key.match(/[0-9.\-\+]/)) {
                if (key == '.' && this.value.indexOf('.') >= 0) event.preventDefault();
                if ((key == '+' || key == '-') && (this.value.indexOf('+') >= 0 || this.value.indexOf('-') >= 0 || getCaretPosition(this) > 0)) event.preventDefault();
            }
            else event.preventDefault();
        }
    });
}


function buildCss(StyleSheet) {
    _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"]._({
        tag: 'style',
        props: {
            innerHTML: Object.keys(StyleSheet).map(function (key) {
                var style = StyleSheet[key];
                return key + ' {\n' +
                    Object.keys(style).map(function (propName) {
                        return propName + ': ' + style[propName] + ';';
                    }).join('\n') +
                    '}';
            }).join('\n')
        }
    }).addTo(document.head);
}

/***
 *
 * @param {"camera"|"microphone"|"camcorder"|{accept:("image/*"|"audio/*"|"video/*"|undefined), capture:boolean|undefined, multiple:boolean|undefined}|{}} props
 * @return {Promise<File[]>}
 */
function openFileDialog(props, unSafe) {
    return new Promise(function (resolve) {
        var input = _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"]._({
            tag: 'input',
            style: {
                display: 'none'
            },
            attr: {
                type: 'file'
            }
        }).addTo(document.body);
        props = props || {};
        if (props === 'camera') {
            props = {
                accept: 'image/*',
                capture: 'camera'
            }
        }
        else if (props === 'microphone') {
            props = {
                accept: 'audio/*',
                capture: "microphone"
            }
        }
        else if (props === 'camcorder') {
            props = {
                accept: 'video/*',
                capture: 'camcorder'
            }
        }

        if (props.accept) {
            if (props.accept instanceof Array)
                input.attr('accept', props.accept.join(','));
            else
                input.attr('accept', props.accept);
        }
        else {
            input.attr('accept', null);
        }

        if (props.capture) {
            input.attr('capture', props.capture);
        }
        if (props.multiple) {
            input.attr('multiple', 'true');
        }
        else {
            input.attr('multiple');
        }
        input.value = null;

        function focusHandler() {
            setTimeout(function () {
                window.removeEventListener('focus', focusHandler);
                if (unSafe) {
                    input.off('change', changeHandler);
                    input.remove();
                    resolve([]);
                }
            }, 1000);
        }

        function changeHandler() {
            input.off('change', changeHandler);
            window.removeEventListener('focus', focusHandler);
            var files = Array.prototype.slice.call(input.files)
            resolve(files);
            input.remove();
        }

        input.on('change', changeHandler);
        input.click();

        setTimeout(function () {
            window.addEventListener('focus', focusHandler);
        }, 10);
    });
}


var charWidth = {
    "A": 9.337890625,
    "Á": 9.337890625,
    "À": 9.337890625,
    "Ả": 9.337890625,
    "Ã": 9.337890625,
    "Ạ": 9.337890625,

    "a": 7.7861328125,
    "á": 7.7861328125,
    "à": 7.7861328125,
    "ả": 7.7861328125,
    "ã": 7.7861328125,
    "ạ": 7.7861328125,

    "Ă": 9.337890625,
    "Ắ": 9.337890625,
    "Ằ": 9.337890625,
    "Ẳ": 9.337890625,
    "Ẵ": 9.337890625,
    "Ặ": 9.337890625,

    "ă": 7.7861328125,
    "ắ": 7.7861328125,
    "ằ": 7.7861328125,
    "ẳ": 7.7861328125,
    "ẵ": 7.7861328125,
    "ặ": 7.7861328125,

    "Â": 9.337890625,
    "Ấ": 9.337890625,
    "Ầ": 9.337890625,
    "Ẩ": 9.337890625,
    "Ẫ": 9.337890625,
    "Ậ": 9.337890625,

    "â": 7.7861328125,
    "ấ": 7.7861328125,
    "ầ": 7.7861328125,
    "ẩ": 7.7861328125,
    "ẫ": 7.7861328125,
    "ậ": 7.7861328125,

    "B": 9.337890625,
    "b": 7.7861328125,
    "C": 10.1103515625,
    "c": 7,
    "D": 10.1103515625,
    "d": 7.7861328125,
    "Đ": 10.1103515625,
    "đ": 7.7861328125,

    "E": 9.337890625,
    "É": 9.337890625,
    "È": 9.337890625,
    "Ẻ": 9.337890625,
    "Ẽ": 9.337890625,
    "Ẹ": 9.337890625,

    "e": 7.7861328125,
    "é": 7.7861328125,
    "è": 7.7861328125,
    "ẻ": 7.7861328125,
    "ẽ": 7.7861328125,
    "ẹ": 7.7861328125,

    "Ê": 9.337890625,
    "Ế": 9.337890625,
    "Ề": 9.337890625,
    "Ể": 9.337890625,
    "Ễ": 9.337890625,
    "Ệ": 9.337890625,

    "ê": 7.7861328125,
    "ế": 7.7861328125,
    "ề": 7.7861328125,
    "ể": 7.7861328125,
    "ễ": 7.7861328125,
    "ệ": 7.7861328125,

    "G": 10.8896484375,
    "g": 7.7861328125,
    "H": 10.1103515625,
    "h": 7.7861328125,

    "I": 3.8896484375,
    "Í": 3.8896484375,
    "Ì": 3.8896484375,
    "Ỉ": 3.8896484375,
    "Ĩ": 3.8896484375,
    "Ị": 3.8896484375,

    "i": 3.1103515625,
    "í": 3.1103515625,
    "ì": 3.1103515625,
    "ỉ": 3.1103515625,
    "ĩ": 3.1103515625,
    "ị": 3.1103515625,

    "K": 9.337890625,
    "k": 7,
    "L": 7.7861328125,
    "l": 3.1103515625,
    "M": 11.662109375,
    "m": 11.662109375,
    "N": 10.1103515625,
    "n": 7.7861328125,

    "O": 10.8896484375,
    "Ó": 10.8896484375,
    "Ò": 10.8896484375,
    "Ỏ": 10.8896484375,
    "Õ": 10.8896484375,
    "Ọ": 10.8896484375,

    "o": 7.7861328125,
    "ó": 7.7861328125,
    "ò": 7.7861328125,
    "ỏ": 7.7861328125,
    "õ": 7.7861328125,
    "ọ": 7.7861328125,

    "Ô": 10.8896484375,
    "Ố": 10.8896484375,
    "Ồ": 10.8896484375,
    "Ổ": 10.8896484375,
    "Ỗ": 10.8896484375,
    "Ộ": 10.8896484375,

    "ô": 7.7861328125,
    "ố": 7.7861328125,
    "ồ": 7.7861328125,
    "ổ": 7.7861328125,
    "ỗ": 7.7861328125,
    "ộ": 7.7861328125,


    "Ơ": 12.00390625,
    "Ớ": 12.00390625,
    "Ờ": 12.00390625,
    "Ở": 12.00390625,
    "Ỡ": 12.00390625,
    "Ợ": 12.00390625,

    "ơ": 9.1806640625,
    "ớ": 9.1806640625,
    "ờ": 9.1806640625,
    "ở": 9.1806640625,
    "ỡ": 9.1806640625,
    "ợ": 9.1806640625,

    "P": 9.337890625,
    "p": 7.7861328125,
    "Q": 10.8896484375,
    "q": 7.7861328125,
    "R": 10.1103515625,
    "r": 4.662109375,
    "S": 9.337890625,
    "s": 7,
    "T": 8.5517578125,
    "t": 3.8896484375,

    "U": 10.1103515625,
    "Ú": 10.1103515625,
    "Ù": 10.1103515625,
    "Ủ": 10.1103515625,
    "Ũ": 10.1103515625,
    "Ụ": 10.1103515625,

    "u": 7.7861328125,
    "ú": 7.7861328125,
    "ù": 7.7861328125,
    "ủ": 7.7861328125,
    "ũ": 7.7861328125,
    "ụ": 7.7861328125,

    "Ư": 11.9560546875,
    "Ứ": 11.9560546875,
    "Ừ": 11.9560546875,
    "Ử": 11.9560546875,
    "Ữ": 11.9560546875,
    "Ự": 11.9560546875,

    "ư": 9.3720703125,
    "ứ": 9.3720703125,
    "ừ": 9.3720703125,
    "ử": 9.3720703125,
    "ữ": 9.3720703125,
    "ự": 9.3720703125,

    "V": 9.337890625,
    "v": 7,
    "X": 9.337890625,
    "x": 7,

    "Y": 9.337890625,
    "Ý": 9.337890625,
    "Ỳ": 9.337890625,
    "Ỷ": 9.337890625,
    "Ỹ": 9.337890625,
    "Ỵ": 9.337890625,

    "y": 7,
    "ý": 7,
    "ỳ": 7,
    "ỷ": 7,
    "ỹ": 7,
    "ỵ": 7,
    " ": 3.8896484375
};


function estimateWidth14(text) {
    // return absol.text.measureText(text, '14px arial').width
    var l = 0;
    for (var j = 0; j < text.length; ++j) {
        l += (charWidth[text.charAt(j)]) || 9.337890625;
    }
    return l;
}

/***
 *
 * @param {number} v
 * @returns {number}
 */
function absCeil(v) {
    var a = Math.ceil(Math.abs(v));
    return v < 0 ? -a : a;
}

/***
 *
 * @param {number} x
 * @param {number} l
 * @returns {String}
 */
function zeroPadding(x, l) {
    var res = Math.abs(x) + '';
    while (res.length < l) {
        res = '0' + res;
    }
    if (x < 0) res = '-' + res;
    return res;
}

var propertyFilter =
    ["$trigger",
        "$content", "_isShow", "defineEvent", "isSupportedEvent",
        "emit", "fire", "eventEmittorOnWithTime", "on", "once",
        "off", "init", "eventHandler", "super", "defineAttribute",
        "defineAttributes", "attr", "addStyle", "removeStyle", "addChild", "addTo", "selfRemove",
        "selfReplace", "clearChild", "containsClass", "addClass", "removeClass", "getComputedStyleValue",
        "getFontSize", "findChildAfter", "findChildBefore", "addChildBefore", "addChildAfter",
        "getBoundingRecursiveRect", "isDescendantOf", "getCSSRules", "afterAttached", "afterDisplayed",
        "_azar_extendEvents", "__azar_force", "_azar_extendAttributes", "_azar_extendTags",
        "findAvailablePosition", "$container", "autoFixParrentSize", "sync", "$dropper", "$vmenu",
        "$button", "$text", "$key", "$arrow", "$iconCtn", "_textMarginRight", "_tabIndex",
        '$icon', '_icon', '$textNode', '$primaryBtn', '$extendBtn', '_menuHolder', '_items'].reduce(function (ac, cr) {
        ac[cr] = true;
        return ac;
    }, {});

/**
 * This is a solution for menu, before a better one.
 * @param obj
 * @returns {{}}
 */
function cleanMenuItemProperty(obj) {
    var res = {};
    var keys = Object.keys(obj);
    var key;
    for (var i = 0; i < keys.length; ++i) {
        key = keys[i];
        if (!propertyFilter[key]) {
            res[key] = obj[key];
        }
    }
    res.text = obj.text;
    if (obj.icon) {
        res.icon = obj.icon;
    }
    if (obj.items) {
        res.items = obj.items;
    }

    return res;
}

/***
 *
 * @param {AElement} e1
 * @param {AElement} e2
 */
function swapElt(e1, e2) {
    var temp = _('div');
    e1.parentElement.replaceChild(temp, e1);
    e2.parentElement.replaceChild(e1, e2);
    temp.parentElement.replaceChild(e2, temp);
}

/**
 *
 * @param {HTMLElement} elt
 */
function vScrollIntoView(elt) {
    var parent = elt.parentElement;
    var overflowStyle;
    while (parent) {
        overflowStyle = window.getComputedStyle(parent)['overflow'];
        if ((overflowStyle === 'auto scroll' || overflowStyle === 'auto' || overflowStyle === 'hidden auto' || overflowStyle === 'scroll' || parent.tagName === 'HTML')
            && (parent.clientHeight < parent.scrollHeight)) {
            break;
        }
        parent = parent.parentElement;
    }
    if (!parent || parent === document || parent.tagName == "HTML" || parent.tagName == "html") {
        elt.scrollIntoView(true);
        return;
    }

    var eBound = elt.getBoundingClientRect();
    var viewportBound = parent.getBoundingClientRect();
    var currentScrollTop = parent.scrollTop;
    var newScrollTop = currentScrollTop;
    if (eBound.bottom > viewportBound.bottom) {
        newScrollTop = currentScrollTop + (eBound.bottom - viewportBound.bottom);
    }
    if (eBound.top < viewportBound.top) {
        newScrollTop = currentScrollTop - (viewportBound.top - eBound.top);
    }

    if (newScrollTop != currentScrollTop) {
        parent.scrollTop = newScrollTop;
    }
}

function fileSize2Text(s) {
    if (typeof s !== "number" || isNaN(s)) return '';
    var units = ['B', 'KB', 'MB', 'GB', 'TB'];
    var b = 1;
    for (var i = 0; i < units.length; ++i) {
        if (s <= b * 1024) {
            return Math.floor(s / b * 100) / 100 + units[i];
        }
        b *= 1024;
    }
    return Math.floor(s / b * 10) / 100 + 'PB';
}

function isDateTimeFormatToken(text) {
    return ['d', 'dd', 'M', 'MM', 'y', 'yyyy', 'h', 'hh', 'H', 'HH', 'm', 'mm', 'a', 'w', 'ww'].indexOf(text) >= 0;
}

function isRealNumber(value) {
    return (isFinite(value) && (typeof value === "number"));
}

/***
 *
 * @param {String} text
 * @returns {Boolean}
 */
function isURLAddress(text) {
    if (typeof text != "string") return false;
    return text.startsWith('.') || text.startsWith('http://') || text.startsWith('https://') || text.startsWith('/');
}

/***
 *
 * @param {string | null} pattern
 * @param {string} typeString
 * @returns {boolean}
 */
function fileAccept(pattern, typeString) {
    if (!pattern) return true;
    var parts = pattern.split(',').map(function (x) {
        return x.trim().toLowerCase();
    });
    var ext = typeString.split('.').pop().toLowerCase();
    var mineType = typeString.split('/').shift().toLowerCase();
    return parts.some(function (part) {
        if (part === '*') return true;
        if (part === 'audio/*') {
            return mineType === 'audio' || ['.3gp', '.aa', '.aac', '.aax', '.act', '.aiff', '.alac', '.amr', '.ape',
                '.au', '.awb', '.dss', '.flac', '.gsm', '.m4a', '.m4b', '.m4p', '.mp3', '.mpc', '.ogg, .oga, .mogg'
                , '.opus', '.ra', '.rm', '.raw', '.rf64', '.sln', '.tta', '.voc', '.vox', '.wav', '.wma', '.wv', '.webm',
                '.8svx', '.cda'].indexOf(ext) >= 0;
        }
        else if (part === 'video/*') {
            return mineType === 'video' || ['.webm', '.mkv', '.flv', '.flv', '.vob', '.drc', '.gif', '.gifv', '.mng',
                '.avi', '.wmv', '.yuv', '.rm', '.rmvb', '.viv', '.asf', '.amv', '.m4v', '.svi',
                '.3gp', '.3g2', '.mxf', '.roq', '.nsv'].indexOf(ext) >= 0;
        }
        else if (part === 'image/*') {
            return mineType === 'video' || [
                "ase", "art", "bmp", "blp", "cd5", "cit", "cpt", "cr2", "cut", "dds", "dib", "djvu", "egt", "exif", "gif", "gpl",
                "grf", "icns", "ico", "iff", "jng", "jpeg", "jpg", "jfif", "jp2", "jps", "lbm", "max", "miff", "mng", "msp", "nef",
                "nitf", "ota", "pbm", "pc1", "pc2", "pc3", "pcf", "pcx", "pdn", "pgm", "PI1", "PI2", "PI3", "pict", "pct", "pnm",
                "pns", "ppm", "psb", "psd", "pdd", "psp", "px", "pxm", "pxr", "qfx", "raw", "rle", "sct", "sgi", "rgb", "int", "bw",
                "tga", "tiff", "tif", "vtf", "xbm", "xcf", "xpm", "3dv", "amf", "ai", "awg", "cgm", "cdr", "cmx", "dxf", "e2d", "egt",
                "eps", "fs", "gbr", "odg", "svg", "stl", "vrml", "x3d", "sxd", "v2d", "vnd", "wmf", "emf", "art", "xar", "png", "webp",
                "jxr", "hdp", "wdp", "cur", "ecw", "iff", "lbm", "liff", "nrrd", "pam", "pcx", "pgf", "sgi", "rgb", "rgba", "bw", "int",
                "inta", "sid", "ras", "sun", "tga", "heic", "heif"
            ].indexOf(ext) >= 0;
        }
        else if (part.startsWith('.')) {
            return '.' + ext === part;
        }
        else {
            return part === ext || part === mineType;
        }
    });
}


function addElementsBefore(inElement, elements, at) {
    for (var i = 0; i < elements.length; ++i) {
        (inElement.addChildBefore || inElement.insertBefore).call(inElement, elements[i], at);
    }
}

function addElementAfter(inElement, elements, at) {
    var atIdx;
    var before;
    var i;
    if (at) {
        atIdx = Array.prototype.indexOf.call(inElement.childNodes, at);
        if (at && atIdx <= 0) throw new Error("The node before which the new node is to be inserted is not a child of this node.");
        before = inElement.childNodes[atIdx + 1];
        if (before) {
            for (i = 0; i < elements.length; ++i) {
                (inElement.addChildBefore || inElement.insertBefore).call(inElement, elements[i], before);
            }
        }
        else {
            for (i = 0; i < elements.length; ++i) {
                (inElement.addChild || inElement.appendChild)(elements[i]);
            }
        }

    }
    else {
        before = inElement.firstChild;
        for (i = 0; i < elements.length; ++i) {
            (inElement.addChildBefore || inElement.insertBefore)(elements[i], before);
        }
    }
}


/***
 *
 * @param {AElement|HTMLElement} element
 * @param {number} padding
 */
function isScrolledToBottom(element, padding){
    if (!isRealNumber(padding)) padding = 0;
    return (element.scrollHeight - element.scrollTop - padding<= element.clientHeight);
}

/***/ }),
/* 5 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MILLIS_PER_DAY", function() { return MILLIS_PER_DAY; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MILLIS_PER_HOUR", function() { return MILLIS_PER_HOUR; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MILLIS_PER_MINUTE", function() { return MILLIS_PER_MINUTE; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ddmmyyyy", function() { return ddmmyyyy; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "language2LocalDateFormat", function() { return language2LocalDateFormat; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "dateFormat2LocationList", function() { return dateFormat2LocationList; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "dateFormatList", function() { return dateFormatList; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "yyymmdd", function() { return yyymmdd; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "dayNames", function() { return dayNames; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "shortDayNames", function() { return shortDayNames; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "monthNames", function() { return monthNames; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "shortMonthNames", function() { return shortMonthNames; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "formatTokenRegex", function() { return formatTokenRegex; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "DATE_TIME_TOKEN_RGX", function() { return DATE_TIME_TOKEN_RGX; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "formatDateString", function() { return formatDateString; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LOCAL_DATE_FORMAT", function() { return LOCAL_DATE_FORMAT; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LOCAL_DATE_TIME_FORMAT", function() { return LOCAL_DATE_TIME_FORMAT; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "formartDateString", function() { return formartDateString; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "parseDateString", function() { return parseDateString; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "prevDate", function() { return prevDate; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "nextDate", function() { return nextDate; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "weekIndexOf", function() { return weekIndexOf; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "weekInYear", function() { return weekInYear; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "beginOfHour", function() { return beginOfHour; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "beginOfDay", function() { return beginOfDay; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "beginOfWeek", function() { return beginOfWeek; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "beginOfMonth", function() { return beginOfMonth; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "beginOfYear", function() { return beginOfYear; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "compareDate", function() { return compareDate; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "compareMonth", function() { return compareMonth; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "compareYear", function() { return compareYear; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "nextMonth", function() { return nextMonth; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "prevMonth", function() { return prevMonth; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "daysInMonth", function() { return daysInMonth; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "parseDateTime", function() { return parseDateTime; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "formatDateTime", function() { return formatDateTime; });
/* harmony import */ var _String_stringFormat__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(15);
/* harmony import */ var _Math_int__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(14);



var MILLIS_PER_DAY = 24 * 3600000;
var MILLIS_PER_HOUR = 3600000;
var MILLIS_PER_MINUTE = 60000;

/**
 *
 * @param {Date} date
 * @returns {String}
 */
function ddmmyyyy(date) {
    var mm = date.getMonth() + 1; // getMonth() is zero-based
    var dd = date.getDate();

    return [(dd > 9 ? '' : '0') + dd,
        (mm > 9 ? '' : '0') + mm,
        date.getFullYear()
    ].join('/');
};

var language2LocalDateFormat = {
    "af-ZA": "yyyy/mm/dd",
    "am-ET": "d/m/yyyy",
    "ar-AE": "dd/mm/yyyy",
    "ar-BH": "dd/mm/yyyy",
    "ar-DZ": "dd-mm-yyyy",
    "ar-EG": "dd/mm/yyyy",
    "ar-IQ": "dd/mm/yyyy",
    "ar-JO": "dd/mm/yyyy",
    "ar-KW": "dd/mm/yyyy",
    "ar-LB": "dd/mm/yyyy",
    "ar-LY": "dd/mm/yyyy",
    "ar-MA": "dd-mm-yyyy",
    "ar-OM": "dd/mm/yyyy",
    "ar-QA": "dd/mm/yyyy",
    "ar-SA": "dd/mm/yy",
    "ar-SY": "dd/mm/yyyy",
    "ar-TN": "dd-mm-yyyy",
    "ar-YE": "dd/mm/yyyy",
    "arn-CL": "dd-mm-yyyy",
    "as-IN": "dd-mm-yyyy",
    "az-Cyrl-AZ": "dd.mm.yyyy",
    "az-Latn-AZ": "dd.mm.yyyy",
    "ba-RU": "dd.mm.yy",
    "be-BY": "dd.mm.yyyy",
    "bg-BG": "dd.m.yyyy",
    "bn-BD": "dd-mm-yy",
    "bn-IN": "dd-mm-yy",
    "bo-CN": "yyyy/m/d",
    "br-FR": "dd/mm/yyyy",
    "bs-Cyrl-BA": "d.m.yyyy",
    "bs-Latn-BA": "d.m.yyyy",
    "ca-ES": "dd/mm/yyyy",
    "co-FR": "dd/mm/yyyy",
    "cs-CZ": "d.m.yyyy",
    "cy-GB": "dd/mm/yyyy",
    "da-DK": "dd-mm-yyyy",
    "de-AT": "dd.mm.yyyy",
    "de-CH": "dd.mm.yyyy",
    "de-DE": "dd.mm.yyyy",
    "de-LI": "dd.mm.yyyy",
    "de-LU": "dd.mm.yyyy",
    "dsb-DE": "d. m. yyyy",
    "dv-MV": "dd/mm/yy",
    "el-GR": "d/m/yyyy",
    "en-029": "mm/dd/yyyy",
    "en-AU": "d/mm/yyyy",
    "en-BZ": "dd/mm/yyyy",
    "en-CA": "dd/mm/yyyy",
    "en-GB": "dd/mm/yyyy",
    "en-IE": "dd/mm/yyyy",
    "en-IN": "dd-mm-yyyy",
    "en-JM": "dd/mm/yyyy",
    "en-MY": "d/m/yyyy",
    "en-NZ": "d/mm/yyyy",
    "en-PH": "m/d/yyyy",
    "en-SG": "d/m/yyyy",
    "en-TT": "dd/mm/yyyy",
    "en-US": "m/d/yyyy",
    "en-ZA": "yyyy/mm/dd",
    "en-ZW": "m/d/yyyy",
    "es-AR": "dd/mm/yyyy",
    "es-BO": "dd/mm/yyyy",
    "es-CL": "dd-mm-yyyy",
    "es-CO": "dd/mm/yyyy",
    "es-CR": "dd/mm/yyyy",
    "es-DO": "dd/mm/yyyy",
    "es-EC": "dd/mm/yyyy",
    "es-ES": "dd/mm/yyyy",
    "es-GT": "dd/mm/yyyy",
    "es-HN": "dd/mm/yyyy",
    "es-MX": "dd/mm/yyyy",
    "es-NI": "dd/mm/yyyy",
    "es-PA": "mm/dd/yyyy",
    "es-PE": "dd/mm/yyyy",
    "es-PR": "dd/mm/yyyy",
    "es-PY": "dd/mm/yyyy",
    "es-SV": "dd/mm/yyyy",
    "es-US": "m/d/yyyy",
    "es-UY": "dd/mm/yyyy",
    "es-VE": "dd/mm/yyyy",
    "et-EE": "d.mm.yyyy",
    "eu-ES": "yyyy/mm/dd",
    "fa-IR": "mm/dd/yyyy",
    "fi-FI": "d.m.yyyy",
    "fil-PH": "m/d/yyyy",
    "fo-FO": "dd-mm-yyyy",
    "fr-BE": "d/mm/yyyy",
    "fr-CA": "yyyy-mm-dd",
    "fr-CH": "dd.mm.yyyy",
    "fr-FR": "dd/mm/yyyy",
    "fr-LU": "dd/mm/yyyy",
    "fr-MC": "dd/mm/yyyy",
    "fy-NL": "d-m-yyyy",
    "ga-IE": "dd/mm/yyyy",
    "gd-GB": "dd/mm/yyyy",
    "gl-ES": "dd/mm/yy",
    "gsw-FR": "dd/mm/yyyy",
    "gu-IN": "dd-mm-yy",
    "ha-Latn-NG": "d/m/yyyy",
    "he-IL": "dd/mm/yyyy",
    "hi-IN": "dd-mm-yyyy",
    "hr-BA": "d.m.yyyy.",
    "hr-HR": "d.m.yyyy",
    "hsb-DE": "d. m. yyyy",
    "hu-HU": "yyyy. mm. dd.",
    "hy-AM": "dd.mm.yyyy",
    "id-ID": "dd/mm/yyyy",
    "ig-NG": "d/m/yyyy",
    "ii-CN": "yyyy/m/d",
    "is-IS": "d.m.yyyy",
    "it-CH": "dd.mm.yyyy",
    "it-IT": "dd/mm/yyyy",
    "iu-Cans-CA": "d/m/yyyy",
    "iu-Latn-CA": "d/mm/yyyy",
    "ja-JP": "yyyy/mm/dd",
    "ka-GE": "dd.mm.yyyy",
    "kk-KZ": "dd.mm.yyyy",
    "kl-GL": "dd-mm-yyyy",
    "km-KH": "yyyy-mm-dd",
    "kn-IN": "dd-mm-yy",
    "ko-KR": "yyyy-mm-dd",
    "kok-IN": "dd-mm-yyyy",
    "ky-KG": "dd.mm.yy",
    "lb-LU": "dd/mm/yyyy",
    "lo-LA": "dd/mm/yyyy",
    "lt-LT": "yyyy.mm.dd",
    "lv-LV": "yyyy.mm.dd.",
    "mi-NZ": "dd/mm/yyyy",
    "mk-MK": "dd.mm.yyyy",
    "ml-IN": "dd-mm-yy",
    "mn-MN": "yy.mm.dd",
    "mn-Mong-CN": "yyyy/m/d",
    "moh-CA": "m/d/yyyy",
    "mr-IN": "dd-mm-yyyy",
    "ms-BN": "dd/mm/yyyy",
    "ms-MY": "dd/mm/yyyy",
    "mt-MT": "dd/mm/yyyy",
    "nb-NO": "dd.mm.yyyy",
    "ne-NP": "m/d/yyyy",
    "nl-BE": "d/mm/yyyy",
    "nl-NL": "d-m-yyyy",
    "nn-NO": "dd.mm.yyyy",
    "nso-ZA": "yyyy/mm/dd",
    "oc-FR": "dd/mm/yyyy",
    "or-IN": "dd-mm-yy",
    "pa-IN": "dd-mm-yy",
    "pl-PL": "yyyy-mm-dd",
    "prs-AF": "dd/mm/yy",
    "ps-AF": "dd/mm/yy",
    "pt-BR": "d/m/yyyy",
    "pt-PT": "dd-mm-yyyy",
    "qut-GT": "dd/mm/yyyy",
    "quz-BO": "dd/mm/yyyy",
    "quz-EC": "dd/mm/yyyy",
    "quz-PE": "dd/mm/yyyy",
    "rm-CH": "dd/mm/yyyy",
    "ro-RO": "dd.mm.yyyy",
    "ru-RU": "dd.mm.yyyy",
    "rw-RW": "m/d/yyyy",
    "sa-IN": "dd-mm-yyyy",
    "sah-RU": "mm.dd.yyyy",
    "se-FI": "d.m.yyyy",
    "se-NO": "dd.mm.yyyy",
    "se-SE": "yyyy-mm-dd",
    "si-LK": "yyyy-mm-dd",
    "sk-SK": "d. m. yyyy",
    "sl-SI": "d.m.yyyy",
    "sma-NO": "dd.mm.yyyy",
    "sma-SE": "yyyy-mm-dd",
    "smj-NO": "dd.mm.yyyy",
    "smj-SE": "yyyy-mm-dd",
    "smn-FI": "d.m.yyyy",
    "sms-FI": "d.m.yyyy",
    "sq-AL": "yyyy-mm-dd",
    "sr-Cyrl-BA": "d.m.yyyy",
    "sr-Cyrl-CS": "d.m.yyyy",
    "sr-Cyrl-ME": "d.m.yyyy",
    "sr-Cyrl-RS": "d.m.yyyy",
    "sr-Latn-BA": "d.m.yyyy",
    "sr-Latn-CS": "d.m.yyyy",
    "sr-Latn-ME": "d.m.yyyy",
    "sr-Latn-RS": "d.m.yyyy",
    "sv-FI": "d.m.yyyy",
    "sv-SE": "yyyy-mm-dd",
    "sw-KE": "m/d/yyyy",
    "syr-SY": "dd/mm/yyyy",
    "ta-IN": "dd-mm-yyyy",
    "te-IN": "dd-mm-yy",
    "tg-Cyrl-TJ": "dd.mm.yy",
    "th-TH": "d/m/yyyy",
    "tk-TM": "dd.mm.yy",
    "tn-ZA": "yyyy/mm/dd",
    "tr-TR": "dd.mm.yyyy",
    "tt-RU": "dd.mm.yyyy",
    "tzm-Latn-DZ": "dd-mm-yyyy",
    "ug-CN": "yyyy-m-d",
    "uk-UA": "dd.mm.yyyy",
    "ur-PK": "dd/mm/yyyy",
    "uz-Cyrl-UZ": "dd.mm.yyyy",
    "uz-Latn-UZ": "dd/mm yyyy",
    "vi-VN": "dd/mm/yyyy",
    "wo-SN": "dd/mm/yyyy",
    "xh-ZA": "yyyy/mm/dd",
    "yo-NG": "d/m/yyyy",
    "zh-CN": "yyyy/m/d",
    "zh-HK": "d/m/yyyy",
    "zh-MO": "d/m/yyyy",
    "zh-SG": "d/m/yyyy",
    "zh-TW": "yyyy/m/d",
    "zu-ZA": "yyyy/mm/dd",
};

var dateFormat2LocationList = Object.keys(language2LocalDateFormat).reduce(function (ac, cr) {
    ac[language2LocalDateFormat[cr]] = ac[language2LocalDateFormat[cr]] || [];
    ac[language2LocalDateFormat[cr]].push(cr);
    return ac;
}, {});

var dateFormatList = Object.keys(dateFormat2LocationList);

/**
 *
 * @param {Date} date
 * @returns {String}
 */
function yyymmdd(date) {
    var mm = date.getMonth() + 1; // getMonth() is zero-based
    var dd = date.getDate();

    return [
        date.getFullYear(),
        (mm > 9 ? '' : '0') + mm,
        (dd > 9 ? '' : '0') + dd
    ].join('/');
};


var dayNames = ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'];
var shortDayNames = ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'];
var monthNames = ["January", "February", "March", "April", "May", "June",
    "July", "August", "September", "October", "November", "December"
];

var shortMonthNames = ["Jan", "Feb", "Mar", "Apr", "May", "Jun",
    "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"];


var formatTokenRegex = /([,.\-\/])|([a-zA-Z0-9]+)/g;//more

var DATE_TIME_TOKEN_RGX = /([^\s.\/:\-,]+)|([.\/:\-,]+)/i;

/**
 *
 * @param {Date} date
 * @param {String=} format
 * @returns {String}
 */
function formatDateString(date, format) {
    format = format || 'dd/mm/yyyy';
    var dt = date.getDate();
    var day = date.getDay();
    var month = date.getMonth();
    var year = date.getFullYear()
    return format.replace(formatTokenRegex, function (x) {
        switch (x) {
            case "dddd":
                return dayNames[day];
            case "ddd":
                return shortDayNames[day];
            case "dd":
                return dt < 10 ? '0' + dt : '' + dt;
            case "d":
                return '' + dt;
            case "mmmm":
                return monthNames[month];
            case "mmm":
                return shortMonthNames[month];
            case "mm":
                return (month + 1) < 10 ? '0' + (month + 1) : '' + (month + 1);
            case "m":
                return '' + (month + 1);
            case 'yy':
                return (year + '').match(/..$/)[0];
            case 'yyyy':
                return year + '';
            default:
                return x;
        }
    });
}


var LOCAL_DATE_FORMAT = (function () {
    var d = new Date(2021, 4, 4);
    var s = d.toLocaleDateString();
    var fm = s.replace(new RegExp(DATE_TIME_TOKEN_RGX.source, 'g'), function (token) {
        switch (token) {
            case '2021':
                return 'yyyy';
            case '5':
                return 'M';
            case '05':
                return 'MM';
            case '4':
                return 'd';
            case '04':
                return 'dd';
            default:
                return token;
        }
    });

    return fm;
})();

var LOCAL_DATE_TIME_FORMAT = (function () {
    var d = new Date(2021, 4, 4, 6, 7, 3);
    var s = d.toLocaleString();
    var fm = s.replace(new RegExp(DATE_TIME_TOKEN_RGX.source, 'g'), function (token) {
        switch (token) {
            case '2021':
                return 'yyyy';
            case '5':
                return 'M';
            case '05':
                return 'MM';
            case '4':
                return 'd';
            case '04':
                return 'dd';
            case '06':
                if (new Date(2021, 4, 4, 18, 7, 3).toLocaleString().indexOf(18) >= 0)
                    return 'HH';
                return 'hh';
            case '6':
                return 'h';
            case '07':
                return 'mm';
            case '7':
                return 'm';
            case '03':
                return 'ss';
            case '3':
                return 's';
            case 'AM':
                return 'a'
            default:
                return token;
        }
    });
    return fm;
})();


function formartDateString() {
    window.ALogger.warn("spelled incorrectly: formartDateString");
    return formatDateString.apply(null, arguments);
}

/**
 *
 * @param {String} text
 * @param {String} format
 * @returns {Date}
 */
function parseDateString(text, format) {
    text = Object(_String_stringFormat__WEBPACK_IMPORTED_MODULE_0__["nonAccentVietnamese"])(text).toLowerCase();
    format = Object(_String_stringFormat__WEBPACK_IMPORTED_MODULE_0__["nonAccentVietnamese"])(format).toLowerCase();
    var textTokens = text.match(formatTokenRegex) || [];
    var formatTokens = format.match(formatTokenRegex) || [];
    var year = new Date().getFullYear();
    var month = 0;
    var day = 1;
    var n = Math.min(textTokens.length, formatTokens.length);
    var textToken;
    var formatToken;
    for (var i = 0; i < n; ++i) {
        textToken = textTokens[i];
        formatToken = formatTokens[i];
        switch (formatToken) {
            case "dd":
                day = parseInt(textToken);
                break;
            case "d":
                day = parseInt(textToken);
                break;
            case "mmmm":
                month = monthNames.indexOf(textToken.substr(0, 1).toUpperCase() + textToken.substr(1).toLowerCase());
                break;
            case "mmm":
                month = shortMonthNames.indexOf(textToken.substr(0, 1).toUpperCase() + textToken.substr(1).toLowerCase());
                break;
            case "mm":
                month = parseInt(textToken) - 1;
                break;
            case "m":
                month = parseInt(textToken) - 1;
                break;
            case 'yy':
                year = Math.floor((new Date().getFullYear()) / 100) * 100 + parseInt(textToken);
                break;
            case 'yyyy':
                year = parseInt(textToken);
                break;
            default:
                if (textToken !== formatToken)
                    throw new Error('Unexpected token ' + textToken);
        }
    }

    if (isNaN(year)) throw new Error('Invalid year');
    if (isNaN(month) && month !== -1) {
        throw new Error('Invalid month');
    } else {
        month = Math.max(0, Math.min(11, month));
    }
    if (!isNaN(day)) {
        day = Math.max(1, Math.min(31, day));
        if (!isNaN(month)) {
            day = Math.min(daysInMonth(2000, month), day);
            if (!isNaN(year)) day = Math.min(daysInMonth(year, month), day);
        }
    } else {
        throw new Error('Invalid day');
    }
    return new Date(year, month, day);
}


/**
 * @param {Date} date
 * @return {Date}
 */
function prevDate(date) {
    return new Date(date.getTime() - MILLIS_PER_DAY);
}

/**
 * @param {Date} date
 * @return {Date}
 */
function nextDate(date) {
    return new Date(date.getTime() + MILLIS_PER_DAY);
}


/****
 *
 * @param {Date} date
 * @param {boolean=}gmt
 * @param {number=}startDayOfWeek
 * @returns {number}
 */
function weekIndexOf(date, gmt, startDayOfWeek) {
    var by = beginOfYear(date, !!gmt);
    var byw = beginOfWeek(by, !!gmt, startDayOfWeek);
    var bw = beginOfWeek(date, !!gmt, startDayOfWeek);
    if (compareYear(by, bw) > 0) {
        return weekIndexOf(bw, gmt, startDayOfWeek);
    }
    var i = compareYear(byw, by) < 0 ? -1 : 0;
    return Math.floor(compareDate(date, byw, !!gmt) / 7) + i;
}

/***
 *
 * @param {number} year
 * @param {number} weekIdx
 * @param {boolean=} gmt
 * @param {number=} startDayOfWeek
 * @returns {Date}
 */
function weekInYear(year, weekIdx, gmt, startDayOfWeek) {
    var bg = new Date(year, 0, 1);
    if (gmt) bg.setUTCHours(0);
    var byw = beginOfWeek(bg, !!gmt, startDayOfWeek || 0);
    var d = compareYear(bg, byw) > 0 ? MILLIS_PER_DAY * 7 : 0;
    return new Date(byw.getTime() + d + weekIdx * 7 * MILLIS_PER_DAY);
}

/**
 * @param {Date} date
 * @return {Date} date at 00:00
 */
function beginOfHour(date) {
    var res = new Date(date.getTime());
    res.setMilliseconds(0);
    res.setSeconds(0);
    res.setMinutes(0);
    return res;
}


/**
 * @param {Date} date
 * @param {Boolean=} gmt default:false
 * @return {Date} date at 00:00
 */
function beginOfDay(date, gmt) {
    var res = new Date(date.getTime());
    res.setMilliseconds(0);
    res.setSeconds(0);
    res.setMinutes(0);
    if (gmt)
        res.setUTCHours(0);
    else res.setHours(0);
    return res;
};


/**
 * @param {Date} date
 * @param {Boolean=} gmt default:false
 * @param {number=} begin default:0
 * @return {Date} date at 00:00
 */
function beginOfWeek(date, gmt, begin) {
    begin = begin || 0;
    var res = beginOfDay(date, gmt);
    while ((gmt ? res.getUTCDay() : res.getDay()) !== begin) {
        res = prevDate(res);
    }
    return res;
};

/**
 * @param {Date} date
 * @param {Boolean=} gmt default:false
 * @return {Date} date at 00:00 AM
 */
function beginOfMonth(date, gmt) {
    gmt = !!gmt;
    var d = gmt ? date.getUTCDate() : date.getDate();
    var m = gmt ? date.getUTCMonth() : date.getMonth();
    var y = gmt ? date.getUTCFullYear() : date.getFullYear();
    var res = new Date();
    if (gmt)
        res.setUTCFullYear(y, m, 1);
    else
        res.setFullYear(y, m, 1);
    return beginOfDay(res, gmt);
};

/**
 * @param {Date} date
 * @param {Boolean=} gmt default:false
 * @return {Date} date at 00:00 AM
 */
function beginOfYear(date, gmt) {
    gmt = !!gmt;
    var d = gmt ? date.getUTCDate() : date.getDate();
    var m = gmt ? date.getUTCMonth() : date.getMonth();
    var y = gmt ? date.getUTCFullYear() : date.getFullYear();
    var res = new Date();
    if (gmt)
        res.setUTCFullYear(y, 0, 1);
    else
        res.setFullYear(y, 0, 1);
    return beginOfDay(res, gmt);
}


/**
 * @param {Date} date0
 * @param {Date} date1
 * @param {Boolean=} gmt default:false
 * @return {number}
 */
function compareDate(date0, date1, gmt) {
    var date0 = beginOfDay(date0, !!gmt);
    var date1 = beginOfDay(date1, !!gmt);
    return (date0.getTime() - date1.getTime()) / (86400000);
}


/**
 * @param {Date} date0
 * @param {Date} date1
 * @param {Boolean=} gmt default:false
 * @return {number}
 */

function compareMonth(date0, date1, gmt) {
    gmt = !!gmt;
    var m0 = gmt ? date0.getUTCMonth() : date0.getMonth();
    var y0 = gmt ? date0.getUTCFullYear() : date0.getFullYear();

    var m1 = gmt ? date1.getUTCMonth() : date1.getMonth();
    var y1 = gmt ? date1.getUTCFullYear() : date1.getFullYear();

    return (y0 - y1) * 12 + (m0 - m1);
}


/***
 *
 * @param {Date} date0
 * @param {Date} date1
 * @param {boolean=}gmt
 * @returns {number}
 */
function compareYear(date0, date1, gmt) {
    gmt = !!gmt;
    var y0 = gmt ? date0.getUTCFullYear() : date0.getFullYear();
    var y1 = gmt ? date1.getUTCFullYear() : date1.getFullYear();
    return y0 - y1;
}


/**
 *
 * @param {Date} date
 * @returns {Date}
 */
function nextMonth(date) {
    var m = date.getMonth();
    var y = date.getFullYear();
    if (m == 11) {
        return new Date(y + 1, 0, 1, 0, 0, 0, 0);
    } else {
        return new Date(y, m + 1, 1, 0, 0, 0, 0);
    }
}

/**
 *
 * @param {Date} date
 * @returns {Date}
 */
function prevMonth(date) {
    var m = date.getMonth();
    var y = date.getFullYear();
    if (m == 0) {
        return new Date(y - 1, 11, 1, 0, 0, 0, 0);
    } else {
        return new Date(y, m - 1, 1, 0, 0, 0, 0);
    }
}

/**
 *
 * @param {Number} year
 * @param {Number} month
 * @returns {Number}
 */
function daysInMonth(year, month) {
    var start = new Date(year, month, 1);
    var end = nextMonth(start);
    return compareDate(end, start);
}


/****
 *
 * @param text
 * @param format support d, M, Y, Q
 * @param {*=} opt
 * @returns {Date}
 */
function parseDateTime(text, format, opt) {
    opt = Object.assign({
        startDayOfWeek: 0
    }, opt);
    var tokenMap = {};
    var txtRgx = new RegExp(DATE_TIME_TOKEN_RGX.source, 'g');
    var fmRgx = new RegExp(DATE_TIME_TOKEN_RGX.source, 'g');
    var tkMatched, fmMatched;
    tkMatched = txtRgx.exec(text);
    fmMatched = fmRgx.exec(format);
    var tkText, fmText;
    while (tkMatched && fmMatched) {
        tkText = tkMatched[0];
        fmText = fmMatched[0];
        switch (fmText) {
            case 'd':
            case 'dd':
                tokenMap.day = parseInt(tkText, 10);
                break;
            case 'w':
            case 'ww':
                tokenMap.week = parseInt(tkText, 10) - 1;
                break;
            case 'M':
            case 'MM':
                tokenMap.month = parseInt(tkText, 10) - 1;
                break;
            case 'y':
            case 'yyyy':
                tokenMap.year = parseInt(tkText, 10);
                break;
            case 'h':
            case 'hh':
            case 'H':
            case 'HH':
                tokenMap.hour = parseInt(tkText, 10);
                break;
            case 'm':
            case 'mm':
                tokenMap.minute = parseInt(tkText, 10);
                break;
            case 'a':
                if (tkText === 'AM' || tkText === 'PM')
                    tokenMap.period = tkText;
                else throw new Error('Invalid period(a):' + tkText)
                break;
            case 'Q':
            case 'QQ':
                tokenMap.month = (parseInt(tkText, 10) - 1) * 3;
                break;
            default:
                if (tkText !== fmText) {
                    throw  new Error('Unexpected token ' + JSON.stringify(tkText) +
                        ' at ' + tkMatched.index + ', expected ' + fmText);
                }
        }

        tkMatched = txtRgx.exec(text);
        fmMatched = fmRgx.exec(format);
    }

    if (tokenMap.period) {
        if (tokenMap.period === 'AM' && tokenMap.hour === 12) tokenMap.hour = 0;
        else if (tokenMap.period === "PM" && tokenMap.hour < 12) tokenMap.hour += 12;
    }

    var paramNames = ['year', 'month', 'day', 'hour', 'minute', 'second'];
    var paramShortNames = ['y', 'M', 'd', 'h', 'm', 's'];
    var paramDefaultValues = [new Date().getFullYear(), 0, 1, 0, 0, 0];
    var resParam = paramDefaultValues.slice();
    var paramList = paramNames.reduce(function (ac, cr, i) {
        var sN = paramShortNames[i];
        if (cr in tokenMap) {
            ac += sN;
        }
        return ac;
    }, '');


    var paramName;
    for (var i = 0; i < paramNames.length; ++i) {
        paramName = paramNames[i];
        resParam[i] = tokenMap[paramName] === undefined ? paramDefaultValues[i] : tokenMap[paramName];
    }

    var weekDate;
    if ('week' in tokenMap && !isNaN(tokenMap.week)) {
        weekDate = weekInYear(resParam[0], tokenMap.week, false, opt.startDayOfWeek);
        resParam[1] = weekDate.getMonth();
        resParam[2] = weekDate.getDate();
    }

    switch (paramList) {
        case 'hm':
            resParam.splice(1, 2, new Date().getMonth(), new Date().getDate());
            break;
    }

    return new Date(resParam[0], resParam[1], resParam[2], resParam[3], resParam[4], resParam[5]);
}

/***
 *
 * @param {Date} date
 * @param {string} format
 * @param {*=} opt
 * @return {string}
 */
function formatDateTime(date, format, opt) {
    opt = Object.assign({
        startDayOfWeek: 0
    }, opt);

    var fmRgx = new RegExp(DATE_TIME_TOKEN_RGX.source, 'g');
    return format.replace(fmRgx, function (s) {
        var res = s;
        switch (s) {
            case 'd':
            case 'dd':
                res = Object(_Math_int__WEBPACK_IMPORTED_MODULE_1__["integerZeroPadding"])(date.getDate(), s.length);
                break;
            case 'w':
            case 'ww':
                res = Object(_Math_int__WEBPACK_IMPORTED_MODULE_1__["integerZeroPadding"])(weekIndexOf(date, false, opt.startDayOfWeek || 0) + 1, s.length);
                break;
            case 'M':
            case 'MM':
                res = Object(_Math_int__WEBPACK_IMPORTED_MODULE_1__["integerZeroPadding"])(date.getMonth() + 1, s.length);
                break;
            case 'MMM':
                res = shortMonthNames[date.getMonth()];
                break;
            case 'MMMM':
                res = monthNames[date.getMonth()];
                break;
            case 'y':
            case 'yyyy':
                res = Object(_Math_int__WEBPACK_IMPORTED_MODULE_1__["integerZeroPadding"])(date.getFullYear(), s.length);
                break;
            case 'yy':
                res = Object(_Math_int__WEBPACK_IMPORTED_MODULE_1__["integerZeroPadding"])(date.getFullYear() % 100, s.length);
                break;
            case 'a':
                res = date.getHours() < 12 ? "AM" : "PM";
                break;
            case "H":
            case 'HH':
                res = Object(_Math_int__WEBPACK_IMPORTED_MODULE_1__["integerZeroPadding"])(date.getHours(), s.length);
                break;
            case 'h':
            case 'hh':
                res = Object(_Math_int__WEBPACK_IMPORTED_MODULE_1__["integerZeroPadding"])(1 + (date.getHours() - 1) % 12, s.length);
                break;
            case 'm':
            case 'mm':
                res = Object(_Math_int__WEBPACK_IMPORTED_MODULE_1__["integerZeroPadding"])(date.getMinutes(), s.length);
                break;
            case 'Q':
            case 'QQ':
                res = Object(_Math_int__WEBPACK_IMPORTED_MODULE_1__["integerZeroPadding"])(Math.floor(date.getMonth() / 3) + 1, s.length)
                break;
        }
        return res;
    });
}


function test() {
    var y = new Date().getFullYear();
    var M = new Date().getMonth();
    var d = new Date().getDate();

    [['22/12/2021', 'dd/MM/yyyy', new Date(2021, 11, 22)],
        ['12:55 AM', 'hh:mm a', new Date(y, M, d, 0, 55)],
        ['12:55 PM', 'hh:mm a', new Date(y, M, d, 12, 55)],
        ['22-12', 'dd-MM', new Date(y, 11, 22, 0, 0)],
        ['2020-11', 'yyyy-MM', new Date(2020, 10, 1, 0, 0)],
        ['11-2020', 'MM-yyyy', new Date(2020, 10, 1, 0, 0)],
        ['quarter 04, 2020', 'quarter QQ, yyyy', new Date(2020, 9, 1, 0, 0)],

    ].forEach(function (pr) {
        var d = parseDateTime(pr[0], pr[1]);
        if ((d && d.getTime()) === pr[2].getTime()) {
            console.info("Pass ", pr);
        } else {
            console.error("Text fail with ", pr.slice(0, 2), ', expect ', pr[2], ', return ' + d);
        }
    });
    console.log(formatDateTime(new Date(), "Mùa QQ, năm y, H giờ m phút"));

}

// setTimeout(test, 100);

/***/ }),
/* 6 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


/*
  MIT License http://www.opensource.org/licenses/mit-license.php
  Author Tobias Koppers @sokra
*/
// css base code, injected by the css-loader
module.exports = function (useSourceMap) {
  var list = []; // return the list of modules as css string

  list.toString = function toString() {
    return this.map(function (item) {
      var content = cssWithMappingToString(item, useSourceMap);

      if (item[2]) {
        return '@media ' + item[2] + '{' + content + '}';
      } else {
        return content;
      }
    }).join('');
  }; // import a list of modules into the list


  list.i = function (modules, mediaQuery) {
    if (typeof modules === 'string') {
      modules = [[null, modules, '']];
    }

    var alreadyImportedModules = {};

    for (var i = 0; i < this.length; i++) {
      var id = this[i][0];

      if (id != null) {
        alreadyImportedModules[id] = true;
      }
    }

    for (i = 0; i < modules.length; i++) {
      var item = modules[i]; // skip already imported module
      // this implementation is not 100% perfect for weird media query combinations
      // when a module is imported multiple times with different media queries.
      // I hope this will never occur (Hey this way we have smaller bundles)

      if (item[0] == null || !alreadyImportedModules[item[0]]) {
        if (mediaQuery && !item[2]) {
          item[2] = mediaQuery;
        } else if (mediaQuery) {
          item[2] = '(' + item[2] + ') and (' + mediaQuery + ')';
        }

        list.push(item);
      }
    }
  };

  return list;
};

function cssWithMappingToString(item, useSourceMap) {
  var content = item[1] || '';
  var cssMapping = item[3];

  if (!cssMapping) {
    return content;
  }

  if (useSourceMap && typeof btoa === 'function') {
    var sourceMapping = toComment(cssMapping);
    var sourceURLs = cssMapping.sources.map(function (source) {
      return '/*# sourceURL=' + cssMapping.sourceRoot + source + ' */';
    });
    return [content].concat(sourceURLs).concat([sourceMapping]).join('\n');
  }

  return [content].join('\n');
} // Adapted from convert-source-map (MIT)


function toComment(sourceMap) {
  // eslint-disable-next-line no-undef
  var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap))));
  var data = 'sourceMappingURL=data:application/json;charset=utf-8;base64,' + base64;
  return '/*# ' + data + ' */';
}

/***/ }),
/* 7 */
/***/ (function(module, exports, __webpack_require__) {

/*
	MIT License http://www.opensource.org/licenses/mit-license.php
	Author Tobias Koppers @sokra
*/

var stylesInDom = {};

var	memoize = function (fn) {
	var memo;

	return function () {
		if (typeof memo === "undefined") memo = fn.apply(this, arguments);
		return memo;
	};
};

var isOldIE = memoize(function () {
	// Test for IE <= 9 as proposed by Browserhacks
	// @see http://browserhacks.com/#hack-e71d8692f65334173fee715c222cb805
	// Tests for existence of standard globals is to allow style-loader
	// to operate correctly into non-standard environments
	// @see https://github.com/webpack-contrib/style-loader/issues/177
	return window && document && document.all && !window.atob;
});

var getTarget = function (target, parent) {
  if (parent){
    return parent.querySelector(target);
  }
  return document.querySelector(target);
};

var getElement = (function (fn) {
	var memo = {};

	return function(target, parent) {
                // If passing function in options, then use it for resolve "head" element.
                // Useful for Shadow Root style i.e
                // {
                //   insertInto: function () { return document.querySelector("#foo").shadowRoot }
                // }
                if (typeof target === 'function') {
                        return target();
                }
                if (typeof memo[target] === "undefined") {
			var styleTarget = getTarget.call(this, target, parent);
			// Special case to return head of iframe instead of iframe itself
			if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) {
				try {
					// This will throw an exception if access to iframe is blocked
					// due to cross-origin restrictions
					styleTarget = styleTarget.contentDocument.head;
				} catch(e) {
					styleTarget = null;
				}
			}
			memo[target] = styleTarget;
		}
		return memo[target]
	};
})();

var singleton = null;
var	singletonCounter = 0;
var	stylesInsertedAtTop = [];

var	fixUrls = __webpack_require__(114);

module.exports = function(list, options) {
	if (typeof DEBUG !== "undefined" && DEBUG) {
		if (typeof document !== "object") throw new Error("The style-loader cannot be used in a non-browser environment");
	}

	options = options || {};

	options.attrs = typeof options.attrs === "object" ? options.attrs : {};

	// Force single-tag solution on IE6-9, which has a hard limit on the # of <style>
	// tags it will allow on a page
	if (!options.singleton && typeof options.singleton !== "boolean") options.singleton = isOldIE();

	// By default, add <style> tags to the <head> element
        if (!options.insertInto) options.insertInto = "head";

	// By default, add <style> tags to the bottom of the target
	if (!options.insertAt) options.insertAt = "bottom";

	var styles = listToStyles(list, options);

	addStylesToDom(styles, options);

	return function update (newList) {
		var mayRemove = [];

		for (var i = 0; i < styles.length; i++) {
			var item = styles[i];
			var domStyle = stylesInDom[item.id];

			domStyle.refs--;
			mayRemove.push(domStyle);
		}

		if(newList) {
			var newStyles = listToStyles(newList, options);
			addStylesToDom(newStyles, options);
		}

		for (var i = 0; i < mayRemove.length; i++) {
			var domStyle = mayRemove[i];

			if(domStyle.refs === 0) {
				for (var j = 0; j < domStyle.parts.length; j++) domStyle.parts[j]();

				delete stylesInDom[domStyle.id];
			}
		}
	};
};

function addStylesToDom (styles, options) {
	for (var i = 0; i < styles.length; i++) {
		var item = styles[i];
		var domStyle = stylesInDom[item.id];

		if(domStyle) {
			domStyle.refs++;

			for(var j = 0; j < domStyle.parts.length; j++) {
				domStyle.parts[j](item.parts[j]);
			}

			for(; j < item.parts.length; j++) {
				domStyle.parts.push(addStyle(item.parts[j], options));
			}
		} else {
			var parts = [];

			for(var j = 0; j < item.parts.length; j++) {
				parts.push(addStyle(item.parts[j], options));
			}

			stylesInDom[item.id] = {id: item.id, refs: 1, parts: parts};
		}
	}
}

function listToStyles (list, options) {
	var styles = [];
	var newStyles = {};

	for (var i = 0; i < list.length; i++) {
		var item = list[i];
		var id = options.base ? item[0] + options.base : item[0];
		var css = item[1];
		var media = item[2];
		var sourceMap = item[3];
		var part = {css: css, media: media, sourceMap: sourceMap};

		if(!newStyles[id]) styles.push(newStyles[id] = {id: id, parts: [part]});
		else newStyles[id].parts.push(part);
	}

	return styles;
}

function insertStyleElement (options, style) {
	var target = getElement(options.insertInto)

	if (!target) {
		throw new Error("Couldn't find a style target. This probably means that the value for the 'insertInto' parameter is invalid.");
	}

	var lastStyleElementInsertedAtTop = stylesInsertedAtTop[stylesInsertedAtTop.length - 1];

	if (options.insertAt === "top") {
		if (!lastStyleElementInsertedAtTop) {
			target.insertBefore(style, target.firstChild);
		} else if (lastStyleElementInsertedAtTop.nextSibling) {
			target.insertBefore(style, lastStyleElementInsertedAtTop.nextSibling);
		} else {
			target.appendChild(style);
		}
		stylesInsertedAtTop.push(style);
	} else if (options.insertAt === "bottom") {
		target.appendChild(style);
	} else if (typeof options.insertAt === "object" && options.insertAt.before) {
		var nextSibling = getElement(options.insertAt.before, target);
		target.insertBefore(style, nextSibling);
	} else {
		throw new Error("[Style Loader]\n\n Invalid value for parameter 'insertAt' ('options.insertAt') found.\n Must be 'top', 'bottom', or Object.\n (https://github.com/webpack-contrib/style-loader#insertat)\n");
	}
}

function removeStyleElement (style) {
	if (style.parentNode === null) return false;
	style.parentNode.removeChild(style);

	var idx = stylesInsertedAtTop.indexOf(style);
	if(idx >= 0) {
		stylesInsertedAtTop.splice(idx, 1);
	}
}

function createStyleElement (options) {
	var style = document.createElement("style");

	if(options.attrs.type === undefined) {
		options.attrs.type = "text/css";
	}

	if(options.attrs.nonce === undefined) {
		var nonce = getNonce();
		if (nonce) {
			options.attrs.nonce = nonce;
		}
	}

	addAttrs(style, options.attrs);
	insertStyleElement(options, style);

	return style;
}

function createLinkElement (options) {
	var link = document.createElement("link");

	if(options.attrs.type === undefined) {
		options.attrs.type = "text/css";
	}
	options.attrs.rel = "stylesheet";

	addAttrs(link, options.attrs);
	insertStyleElement(options, link);

	return link;
}

function addAttrs (el, attrs) {
	Object.keys(attrs).forEach(function (key) {
		el.setAttribute(key, attrs[key]);
	});
}

function getNonce() {
	if (false) {}

	return __webpack_require__.nc;
}

function addStyle (obj, options) {
	var style, update, remove, result;

	// If a transform function was defined, run it on the css
	if (options.transform && obj.css) {
	    result = typeof options.transform === 'function'
		 ? options.transform(obj.css) 
		 : options.transform.default(obj.css);

	    if (result) {
	    	// If transform returns a value, use that instead of the original css.
	    	// This allows running runtime transformations on the css.
	    	obj.css = result;
	    } else {
	    	// If the transform function returns a falsy value, don't add this css.
	    	// This allows conditional loading of css
	    	return function() {
	    		// noop
	    	};
	    }
	}

	if (options.singleton) {
		var styleIndex = singletonCounter++;

		style = singleton || (singleton = createStyleElement(options));

		update = applyToSingletonTag.bind(null, style, styleIndex, false);
		remove = applyToSingletonTag.bind(null, style, styleIndex, true);

	} else if (
		obj.sourceMap &&
		typeof URL === "function" &&
		typeof URL.createObjectURL === "function" &&
		typeof URL.revokeObjectURL === "function" &&
		typeof Blob === "function" &&
		typeof btoa === "function"
	) {
		style = createLinkElement(options);
		update = updateLink.bind(null, style, options);
		remove = function () {
			removeStyleElement(style);

			if(style.href) URL.revokeObjectURL(style.href);
		};
	} else {
		style = createStyleElement(options);
		update = applyToTag.bind(null, style);
		remove = function () {
			removeStyleElement(style);
		};
	}

	update(obj);

	return function updateStyle (newObj) {
		if (newObj) {
			if (
				newObj.css === obj.css &&
				newObj.media === obj.media &&
				newObj.sourceMap === obj.sourceMap
			) {
				return;
			}

			update(obj = newObj);
		} else {
			remove();
		}
	};
}

var replaceText = (function () {
	var textStore = [];

	return function (index, replacement) {
		textStore[index] = replacement;

		return textStore.filter(Boolean).join('\n');
	};
})();

function applyToSingletonTag (style, index, remove, obj) {
	var css = remove ? "" : obj.css;

	if (style.styleSheet) {
		style.styleSheet.cssText = replaceText(index, css);
	} else {
		var cssNode = document.createTextNode(css);
		var childNodes = style.childNodes;

		if (childNodes[index]) style.removeChild(childNodes[index]);

		if (childNodes.length) {
			style.insertBefore(cssNode, childNodes[index]);
		} else {
			style.appendChild(cssNode);
		}
	}
}

function applyToTag (style, obj) {
	var css = obj.css;
	var media = obj.media;

	if(media) {
		style.setAttribute("media", media)
	}

	if(style.styleSheet) {
		style.styleSheet.cssText = css;
	} else {
		while(style.firstChild) {
			style.removeChild(style.firstChild);
		}

		style.appendChild(document.createTextNode(css));
	}
}

function updateLink (link, options, obj) {
	var css = obj.css;
	var sourceMap = obj.sourceMap;

	/*
		If convertToAbsoluteUrls isn't defined, but sourcemaps are enabled
		and there is no publicPath defined then lets turn convertToAbsoluteUrls
		on by default.  Otherwise default to the convertToAbsoluteUrls option
		directly
	*/
	var autoFixUrls = options.convertToAbsoluteUrls === undefined && sourceMap;

	if (options.convertToAbsoluteUrls || autoFixUrls) {
		css = fixUrls(css);
	}

	if (sourceMap) {
		// http://stackoverflow.com/a/26603875
		css += "\n/*# sourceMappingURL=data:application/json;base64," + btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))) + " */";
	}

	var blob = new Blob([css], { type: "text/css" });

	var oldSrc = link.href;

	link.href = URL.createObjectURL(blob);

	if(oldSrc) URL.revokeObjectURL(oldSrc);
}


/***/ }),
/* 8 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _EventEmitter__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3);
/* harmony import */ var _Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(10);
/* harmony import */ var _OOP__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2);





/***
 * @augments Node
 * @augments ChildNode
 * @augments ParentNode
 * @augments Element
 * @augments HTMLElement
 * @augments EventEmitter
 * @augments ElementCSSInlineStyle
 * @constructor
 */
function AElement() {
    _EventEmitter__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].call(this);
    this._azar_extendAttributes = this._azar_extendAttributes || {};
    this._azar_extendTags = {};
    this.eventHandler = {};
}

_OOP__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].mixClass(AElement, _EventEmitter__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"]);

AElement.prototype.init = function (props) {
    Object.assign(this, props || {});
};


AElement.prototype.eventHandler = {};

/***
 * run super-class method
 */
AElement.prototype.super = function () {/* nope */
};

/**
 * @typedef {Object} AttributeDefiner
 * @property {Function} set
 * @property {Function} get
 * @property {Function} remove
 *
 * @param {String} key
 * @param {AttributeDefiner} def
 */
AElement.prototype.defineAttribute = function (key, def) {
    this._azar_extendAttributes[key] = def;
};


AElement.prototype.defineAttributes = function (defs) {
    for (var key in defs) {
        this.defineAttribute(key, defs[key]);
    }
};

AElement.prototype.attr = function () {
    if (arguments.length === 1) {
        if (typeof (arguments[0]) == 'string') {
            if (this._azar_extendAttributes[arguments[0]]) {
                return this._azar_extendAttributes[arguments[0]].get.call(this);
            }
            else
                return this.getAttribute(arguments[0]);
        }
        else {
            for (var key in arguments[0]) {

                this.attr(key, arguments[0][key]);
            }
        }
    }
    else {
        if (arguments.length == 2) {
            if (arguments[1] === null || arguments[1] === undefined) {
                if (this._azar_extendAttributes[arguments[0]]) {
                    this._azar_extendAttributes[arguments[0]].remove.call(this, arguments[1]);
                }
                else
                    this.removeAttribute(arguments[0]);
            }
            else {
                if (this._azar_extendAttributes[arguments[0]]) {
                    this._azar_extendAttributes[arguments[0]].set.call(this, arguments[1]);
                }
                else {

                    this.setAttribute(arguments[0], arguments[1]);
                }
            }
        }
    }
    return this;
};

/***
 * add style
 * @param {CSSStyleDeclaration|string|{}} arg0
 * @param {string} arg1
 * @returns {AElement}
 */
/**
 * add style
 * @param {CSSStyleDeclaration|string|{}} arg0
 * @param {string|[]=} arg1
 * @returns {AElement}
 */
AElement.prototype.addStyle = function (arg0, arg1) {
    if (typeof arg0 == 'string')
        if (arg0.indexOf('-') >= 0) {
            if (arg1 && arg1.forEach) {
                this.style.setProperty.apply(this.style, [arg0].concat(arg1));
            }
            else {
                this.style.setProperty(arg0, arg1);
            }
        }
        else {
            this.style[arg0] = arg1;
        }
    else {
        for (var key in arg0)
            this.addStyle(key, arg0[key]);
    }
    return this;
};

/***
 *
 * @param {string|string[]|CSSStyleDeclaration} arg0
 * @returns {AElement}
 */
AElement.prototype.removeStyle = function (arg0) {
    var key;
    if (arg0.charAt) {
        if (arg0.indexOf('-') >= 0) {
            this.style.removeProperty(arg0);
        }
        else {
            this.style[arg0] = null;
            delete this.style[arg0];
        }
    }
    else {
        if (arg0.map && arg0.forEach) {
            for (var i = 0; i < arg0.length; ++i)
                this.removeStyle(arg0[i]);
        }
        else {
            for (key in arg0)
                this.removeStyle(key);
        }
    }
    return this;
};

AElement.prototype.addChild = function (child) {
    if (child.indexOf && child.map && child.forEach) {
        for (var i = 0; i < child.length; ++i)
            this.appendChild(child[i]);
    }
    else
        this.appendChild(child);
    return this;
};


AElement.prototype.addTo = function (parent) {
    if (parent && parent.appendChild) {
        if (parent.addChild)
            parent.addChild(this);
        else
            parent.appendChild(this);
    }
    else throw Error("Can not append to " + parent + "!");
    return this;
};


AElement.prototype.selfRemove = function () {
    if (this.parentElement)
        this.parentElement.removeChild(this);
    return this;
};


AElement.prototype.selfReplace = function (newNode) {
    if (this.parentElement)
        this.parentElement.replaceChild(newNode, this);
    return this;
};

AElement.prototype.clearChild = function () {
    while (this.firstChild) {
        this.removeChild(this.firstChild);
    }
    return this;
};




/**
 *
 * @param {string|Array} className
 * @returns {Boolean}
 */
AElement.prototype.hasClass = function (className) {
    return this.classList.contains(className);
};


/**
 *
 * @param {string|Array} className
 * @returns {AElement}
 */
AElement.prototype.addClass = function (className) {
    if (className && className.forEach && className.map) {
        for (var i = 0; i < className.length; ++i)
            this.classList.add(className[i]);
    }
    else
        this.classList.add(className);
    return this;
};

/**
 *
 * @param {string|Array} className
 * @returns {AElement}
 */
AElement.prototype.removeClass = function (className) {
    if (className && className.forEach && className.map) {
        for (var i = 0; i < className.length; ++i)
            this.classList.remove(className[i]);
    }
    else
        this.classList.remove(className);
    return this;
};


AElement.prototype.getComputedStyleValue = function (key) {
    return window.getComputedStyle(this).getPropertyValue(key);

};

AElement.prototype.getFontSize = function () {
    return parseFloat(this.getComputedStyleValue('font-size').replace('px', ''));
};


AElement.prototype.findChildAfter = function (obj) {
    var r = 0;
    for (var i = 0; i < this.childNodes.length; ++i) {
        if (obj == this.childNodes[i]) {
            r = i + 1;
            break;
        }
    }
    if (this.childNodes[r]) return this.childNodes[r];
    return undefined;
};

AElement.prototype.findChildBefore = function (obj) {
    var r = 0;
    for (var i = 0; i < this.childNodes.length; ++i) {
        if (obj == this.childNodes[i]) {
            r = i - 1;
            break;
        }
    }
    if (this.childNodes[r]) return this.childNodes[r];
    return undefined;
};

AElement.prototype.addChildBefore = function (newItem, bf) {
    this.insertBefore(newItem, bf);
    return this;
};

AElement.prototype.addChildAfter = function (newItem, at) {
    var atIdx;
    if (at) {
        atIdx = Array.prototype.indexOf.call(this.childNodes, at);
        if (atIdx >= 0) {
            this.insertBefore(newItem, this.childNodes[atIdx + 1]);
        }
        else {
            throw new Error("Failed to execute 'addChildAfter' on 'Node': The node before which the new node is to be inserted is not a child of this node.");
        }
    }
    else {
        this.insertBefore(newItem, this.firstChild);
    }
    return this;
};

/**
 * @returns {DOMRect}
 */
AElement.prototype.getBoundingRecursiveRect = function (depth) {
    if (depth === undefined) depth = 10000;

    var current, next;
    var oo = 1000000;
    var ac = { left: oo, right: -oo, top: oo, bottom: -oo, width: 0, height: 0 };
    var stacks = [{ e: this, d: 0 }];
    while (stacks.length > 0) {
        current = stacks.pop();

        if (current.e.getBoundingClientRect) {
            var cRect = current.e.getBoundingClientRect();
            if (!cRect || !(cRect.width || cRect.height || cRect.left || cRect.right)) continue;
            ac.left = Math.min(ac.left, cRect.left);
            ac.top = Math.min(ac.top, cRect.top);
            ac.bottom = Math.max(ac.bottom, cRect.bottom);
            ac.right = Math.max(ac.right, cRect.right);
            ac.height = ac.bottom - ac.top;
            ac.width = ac.right - ac.left;
            var childNodes = current.e.childNodes;
            if (childNodes && childNodes.length > 0 && current.d < depth) {
                for (var i = 0; i < childNodes.length; ++i) {
                    next = { e: childNodes[i], d: current.d + 1 };
                    stacks.push(next);
                }
            }
        }
    }

    return ac;
};

/***
 *
 * @param parent
 * @returns {boolean}
 */
AElement.prototype.isDescendantOf = function (parent) {
    var child = this;
    while (child) {
        if (child === parent) return true;
        child = child.parentNode;
    }
    return false;
};


/*************************** **********************/
AElement.prototype.getCSSRules = function () {
    var sheets = document.styleSheets;
    var ret = [];
    this.matches = this.matches || this.webkitMatchesSelector || this.mozMatchesSelector
        || this.msMatchesSelector || this.oMatchesSelector;
    for (var i in sheets) {
        if (sheets[i].href) continue;//because can not access, you must clone link node instead
        var rules = sheets[i].rules || sheets[i].cssRules;
        for (var r in rules) {
            if (this.matches(rules[r].selectorText)) {
                ret.push(rules[r]);
            }
        }
    }
    return ret;
};


/***
 * @returns {Promise}
 */


/***
 * WARNING: this function may be unsafe
 */
AElement.prototype.afterDisplayed = function (requestTimesOut) {
    if (!requestTimesOut) requestTimesOut = 24 * 3600 * 33;
    // var tracer = new Error();
    var current = this;
    return new Promise(function (resolve, reject) {
        function trace() {
            if (requestTimesOut < 0) {
                // reject(tracer);
                // if (absol.BUILD && absol.BUILD.version == "DEBUG")
                //     console.warn("Element not displayed", trace);
            }
            else {
                requestTimesOut--;
                var bound = current.getBoundingClientRect();
                if (bound.width > 0 || bound.height > 0) {
                    resolve();
                }
                else {
                    setTimeout(trace, 33);
                    return;
                }
            }
        }

        trace();
    });
};


!(function () {
    var origin = AElement.prototype.on;
    if (_Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"].isSafari && !_Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"].isMobile) {
        AElement.prototype.on = function () {
            if (!this.isSupportedEvent('mouseleave') && arguments[0] == 'mouseleave') {
                this.defineEvent('mouseleave');
                var mouseLeaveEventHandler = function (event) {
                    var bound = this.getBoundingClientRect();
                    var ok = false;
                    ok |= event.clientX < bound.left + 1;
                    ok |= event.clientX >= bound.right - 1;
                    ok |= event.clientY < bound.top + 1;
                    ok |= event.clientY >= bound.bottom - 1;
                    if (ok) this.emit('mouseleave', event);
                };
                this.addEventListener('mouseleave', mouseLeaveEventHandler, true);
            }
            origin.apply(this, arguments);
            return this;
        };
    }

    if (_Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"].isFirefox) {
        AElement.prototype.on = function () {
            if (!this.isSupportedEvent('wheel') && arguments[0] == 'wheel') {

                this.defineEvent('wheel');
                var wheelEventHandler = function (oldEvent) {
                    //clone event to avoid some lib fix it
                    var event = oldEvent.absolEvent;
                    if (!event) {
                        event = Object.assign({}, oldEvent);
                        for (var i = 0; i < AElement.eventProperties.length; ++i) {
                            var key = AElement.eventProperties[i];
                            if (typeof (event[key]) == 'function') {
                                event[key] = event[key].bind(oldEvent);
                            }
                        }

                        event.preventDefault = function () {
                            oldEvent.preventDefault();
                        };
                        if (!event.mozFixWheelScale) {
                            event.mozDeltaY = oldEvent.deltaY;
                            event.mozFixWheelScale = true;
                            Object.defineProperty(event, 'deltaY', {
                                get: function () {
                                    return this.mozDeltaY * 100 / 3;
                                }
                            });
                        }
                        oldEvent.absolEvent = event;
                    }
                    this.emit('wheel', event);
                };
                this.addEventListener('wheel', wheelEventHandler);
            }
            origin.apply(this, arguments);
            return this;
        };
    }

}());

AElement.eventProperties = ["altKey", "bubbles", "button", "buttons", "cancelBubble", "cancelable", "clientX", "clientY", "composed",
    "ctrlKey", "currentTarget", "defaultPrevented", "deltaMode", "deltaX", "deltaY", "deltaZ", "detail", "eventPhase",
    "explicitOriginalTarget", "isTrusted", "layerX", "layerY", "metaKey", "movementX", "movementY", "mozInputSource",
    "mozPressure", "offsetX", "offsetY", "originalTarget", "pageX", "pageY", "rangeOffset", "rangeParent", "region",
    "relatedTarget", "returnValue", "screenX", "screenY", "shiftKey", "srcElement", "target", "timeStamp", "type",
    "deltaMode", "deltaX", "deltaY", "deltaZ"];


/* harmony default export */ __webpack_exports__["a"] = (AElement);

/***/ }),
/* 9 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/***
 *
 * @param  {Number} x
 * @param {Number} y
 * @constructor
 */
function Vec2(x, y) {
    this.x = x;
    this.y = y;
}

/***
 *
 * @returns {Vec2}
 */
Vec2.prototype.copy = function () {
    return new Vec2(this.x, this.y);
};

/***
 *
 * @returns {string}
 */
Vec2.prototype.toString = function () {
    return "(" + this.x + ", " + this.y + ")";
};

/***
 *
 * @returns {number}
 */
Vec2.prototype.abs = function () {
    return Math.sqrt(this.x * this.x + this.y * this.y);
};

/***
 *
 * @returns {Vec2}
 */
Vec2.prototype.normalized = function () {
    var l = this.abs();
    if (l == 0) l = 1;
    return this.div(l);
};

/***
 *
 * @param {number} h
 * @returns {Vec2}
 */
Vec2.prototype.mult = function (h) {
    return new Vec2(this.x * h, this.y * h);
};

/***
 *
 * @param {number} h
 * @returns {Vec2}
 */
Vec2.prototype.div = function (h) {
    return new Vec2(this.x / h, this.y / h);
};

/***
 *
 * @param v
 * @returns {number}
 */
Vec2.prototype.dist = function (v) {
    var dx = v.x - this.x;
    var dy = v.y - this.y;
    return Math.sqrt(dx * dx + dy * dy);
};

/***
 *
 * @param {Vec2} v
 * @returns {Vec2}
 */
Vec2.prototype.sub = function (v) {
    return new Vec2(this.x - v.x, this.y - v.y);
};

/***
 *
 * @param {Vec2} v
 * @returns {Vec2}
 */
Vec2.prototype.add = function (v) {
    return new Vec2(this.x + v.x, this.y + v.y);
};

/***
 *
 * @returns {Vec2}
 */
Vec2.prototype.inv = function () {
    return new Vec2(-this.x, -this.y);
};

/***
 *
 * @param {Vec2} v
 * @param {number} h
 * @returns {Vec2}
 */
Vec2.prototype.linear = function (v, h) {
    return new Vec2(this.x * (1 - h) + v.x * h, this.y * (1 - h) + v.y * h);
};

/***
 *
 * @param {Vec2} v1
 * @returns {number}
 */
Vec2.prototype.dot = function (v1) {
    return this.x * v1.x + this.y * v1.y;
};

/***
 *
 * @returns {number}
 */
Vec2.prototype.direction = function () {
    return Math.atan2(this.y, this.x);
};

/***
 *
 * @param {Number} dx
 * @param {Number} dy
 */
Vec2.prototype.translate = function (dx, dy) {
    return this.add(new Vec2(dx, dy));
};


/****
 *
 * @param {Number} angle - radian
 * @returns {Vec2}
 */
Vec2.prototype.rotate = function (angle) {
    var sinA = Math.sin(angle);
    var cosA = Math.cos(angle);
    var x = this.x * cosA - this.y * sinA;
    var y = this.x * sinA + this.y * cosA;
    return new Vec2(x, y);
};

/***
 *
 * @returns {Vec2}
 */
Vec2.prototype.rotate90 = function () {
    return new Vec2(-this.y, this.x);
};


/***
 *
 * @param {number} angle
 * @returns {Vec2}
 */
Vec2.fromDirection = function (angle) {
    return new Vec2(Math.cos(angle), Math.sin(angle));
};

/***
 *
 * @param x
 * @param y
 * @returns {Vec2}
 */
Vec2.make = function (x, y) {
    if (x instanceof Array) {
        return new Vec2(x[0], x[1]);
    }
    else if (x instanceof Vec2) {
        return x.copy();
    }
    else
        return new Vec2(x, y);
};

/* harmony default export */ __webpack_exports__["a"] = (Vec2);

/***/ }),
/* 10 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global) {/* harmony import */ var _BrowserRules__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(102);
/* harmony import */ var _BrowserRules__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_BrowserRules__WEBPACK_IMPORTED_MODULE_0__);



/**
 *
 * @param {BrowserRules} rulesheet
 */
function BrowserDetector(rulesheet) {
    this.au = global.navigator ? (navigator.userAgent || '') : '';
    this.rulesheet = rulesheet;
    this.os = this.detectByRules(this.rulesheet.os);
    this.device = this.detectByRules(this.rulesheet.device);
    this.engine = this.detectByRules(this.rulesheet.engine);
    this.browser = this.detectByRules(this.rulesheet.browser);
    this.isFirefox = navigator.userAgent.toLowerCase().indexOf('firefox') > -1;
    this.isCococ = navigator.userAgent.toLowerCase().indexOf('coc_coc_browser') >= 1;
    this.isSafari = !this.isCococ && navigator.userAgent.toLowerCase().indexOf('safari') > -1
        && navigator.userAgent.toLowerCase().indexOf('win') < 0
        && navigator.userAgent.toLowerCase().indexOf('android') < 0;
    // this.isSafari = /constructor/i.test(window.HTMLElement) || window.safari;
    this.isMobile = navigator.userAgent.indexOf('KFFOWI') > -1 || navigator.userAgent.toLowerCase().indexOf('mobile') > -1;
    this.isMacOSWebView = /Macintosh/.test(this.au) && /AppWebkit/.test(this.au) && !/Safari/.test(this.au);
    this.isChromeIOS = /CriOS\/[\d]+/.test(this.au);
    this.hasTouch = 'ontouchstart' in window ||
        window.DocumentTouch && document instanceof window.DocumentTouch ||
        navigator.maxTouchPoints > 0 ||
        window.navigator.msMaxTouchPoints > 0;
    this.isTouchDevice = this.isMobile && this.hasTouch;
    this.supportPassiveEvent = (function () {
        var supportsPassiveOption = false;
        try {
            var opts = Object.defineProperty({}, 'passive', {
                get: function () {
                    supportsPassiveOption = true;
                }
            });
            window.addEventListener('test', null, opts);
            window.removeEventListener('test', null, opts);
        } catch (e) {
        }
        return supportsPassiveOption;
    })();
}


BrowserDetector.prototype.detectByRules = function (rules) {
    var result = {};
    for (var i = 0; i < rules.length; ++i) {
        var rule = rules[i];
        var type = rule[0];
        var rgx = rule[1];
        if (typeof (rgx) == 'function') {
            rgx = rgx(this.au.toLowerCase());
        }
        if (Object.prototype.toString.call(rgx).indexOf('RegExp') >= 0) {
            var matched = this.au.toLowerCase().match(rgx);
            if (matched) {
                result.type = type;
                if (matched[1]) {
                    result.version = matched[1];
                }
                break;
            }
        }
        else if (typeof (rgx) == 'string') {
            if (this.au.toLowerCase().indexOf(rgx) >= 0) {
                result.type = type;
            }
        }
    }
    return result;

};


/* harmony default export */ __webpack_exports__["a"] = (new BrowserDetector(_BrowserRules__WEBPACK_IMPORTED_MODULE_0___default.a));

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(44)))

/***/ }),
/* 11 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _AElement__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(8);
/* harmony import */ var _AElementNS__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(56);



/**
 *
 * @constructor
 */
function ResizeSystem() {
    this.elts = [];
    this.cache = [];
    this.cacheOf = null;
    this.lastResizeTime = 0;
    window.addEventListener('resize', this.update.bind(this));
    this['goDown'+'AndCache'] = this.goDownAndCache.bind(this);
    this['notify'+'ToElt'] = this.notifyToElt.bind(this);
}

/***
 *
 * @param {AElement | AElementNS} elt
 */
ResizeSystem.prototype.goDownAndCache = function (elt){
    if (this.notifyToElt(elt))
        this.cache.push(elt);
    if (elt.childNodes) {
        Array.prototype.forEach.call(elt.childNodes, this.goDownAndCache);
    }
};

ResizeSystem.prototype.notifyToElt = function (elt){
    if (typeof elt.requestUpdateSize == 'function') {
        elt.requestUpdateSize();
        return true;
    }
    else if (typeof elt.updateSize == 'function') {
        elt.updateSize();
        return true;
    }
    else if (typeof elt.onresize == 'function') {
        elt.onresize();
        return true;
    }
};


ResizeSystem.prototype.update = function () {
    var now = new Date().getTime();
    if (now - 100 > this.lastResizeTime) {
        this.removeTrash();
        this.cache = undefined;
    }
    this.lastResizeTime = now;
    if (this.cacheOf !== null){
        this.cache = undefined;
        this.cacheOf = null;
    }


    if (this.cache === undefined) {
        this.cache = [];
        this.elts.forEach(this.goDownAndCache);
    }
    else {
        this.cache.forEach(this.notifyToElt);
    }
}

ResizeSystem.prototype.removeTrash = function () {
    this.elts = this.elts.filter(function (element) {
        return _AElement__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].prototype.isDescendantOf.call(element, document.body);
    });
};

/***
 *
 * @param  {AElement| AElementNS | Node} fromElt
 * @returns {boolean}
 */
ResizeSystem.prototype.updateUp = function (fromElt) {
    while (fromElt) {
        if (typeof fromElt.requestUpdateSize == 'function') {
            fromElt.requestUpdateSize();
            return true;
        }
        else if (typeof fromElt.updateSize == 'function') {
            fromElt.updateSize();
            return true;
        }
        else if (typeof fromElt.onresize == 'function') {
            fromElt.onresize();
            return true;
        }
        fromElt = fromElt.parentElement;
    }
};

/***
 *
 * @param  {AElement| AElementNS | Node} fromElt
 * @returns {boolean}
 */
ResizeSystem.prototype.updateDown = function (fromElt) {
    var now = new Date().getTime();
    if (now - 100 > this.lastResizeTime) {
        this.cache = undefined;
    }
    this.lastResizeTime = now;
    if (this.cacheOf !== fromElt){
        this.cache = undefined;
        this.cacheOf = fromElt;
    }
    if (this.cache === undefined) {
        this.cache = [];
        this.goDownAndCache(fromElt);
    }
    else {
        this.cache.forEach(this.notifyToElt);
    }
};

/***
 *
 * @param {AElement| AElementNS | Node} elt
 * @return {boolean}
 */
ResizeSystem.prototype.add = function (elt) {
    for (var i = 0; i < this.elts.length; ++i)
        if (_AElement__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].prototype.isDescendantOf.call(elt, this.elts[i])) {
            return false;
        }
    this.elts = this.elts.filter(function (e) {
        return !_AElement__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].prototype.isDescendantOf.call(e, elt);
    });
    this.elts.push(elt);
    return true;
};

/* harmony default export */ __webpack_exports__["a"] = (new ResizeSystem());

/***/ }),
/* 12 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
// ESM COMPAT FLAG
__webpack_require__.r(__webpack_exports__);

// EXPORTS
__webpack_require__.d(__webpack_exports__, "identCharacters", function() { return /* binding */ identCharacters; });
__webpack_require__.d(__webpack_exports__, "randomIdent", function() { return /* binding */ randomIdent; });
__webpack_require__.d(__webpack_exports__, "parallelMatch", function() { return /* binding */ parallelMatch; });
__webpack_require__.d(__webpack_exports__, "ipsumLoremWord", function() { return /* binding */ ipsumLoremWord; });
__webpack_require__.d(__webpack_exports__, "randomWord", function() { return /* binding */ randomWord; });
__webpack_require__.d(__webpack_exports__, "randomPhrase", function() { return /* binding */ randomPhrase; });
__webpack_require__.d(__webpack_exports__, "randomSentence", function() { return /* binding */ randomSentence; });
__webpack_require__.d(__webpack_exports__, "randomParagraph", function() { return /* binding */ randomParagraph; });

// CONCATENATED MODULE: ./node_modules/absol/src/Math/random.js

/**
 * Returns a random number between min (inclusive) and max (exclusive)
 */
function randomArbitrary(min, max) {
    return Math.random() * (max - min) + min;
}

/**
 * Returns a random integer between min (inclusive) and max (inclusive)
 * Using Math.round() will give you a non-uniform distribution!
 */
function randomInt(min, max) {
    return Math.floor(Math.random() * (max - min + 1)) + min;
}

function randomPick(arr) {
    var id = randomInt(0, arr.length - 1);
    return arr[id];
}
// CONCATENATED MODULE: ./node_modules/absol/src/String/stringGenerate.js


var identCharacters = function () {
    var chars = 'qwertyuiopasdfghjklzxcvbnm';
    chars = chars + chars.toUpperCase();
    var num = '0123456789';
    var spect = '_';
    return (chars + spect + num).split('');

}();


function randomIdent(length) {
    if (!(length > 0)) length = 4;
    var factor = identCharacters;
    return [factor[(Math.random() * (factor.length - 10)) >> 0]].concat(Array(length - 1).fill('').map(function () {
        return factor[(Math.random() * factor.length) >> 0];
    })).join('');
}

function parallelMatch(a, b) {
    var l = Math.min(a.length, b.length);
    var res = 0;
    for (var i = 0; i < l; ++i) {
        if (a[i] == b[i])++res;
    }
    return res;
}

var ipsumLoremWord = ['lorem', 'ipsum', 'dolor', 'sit', 'amet', 'consectetur', 'adipiscing', 'elit', 'sed', 'do',
    'eiusmod', 'tempor', 'incididunt', 'ut', 'labore', 'et', 'dolore', 'magna', 'aliqua', 'enim', 'ad', 'minim',
    'veniam', 'quis', 'nostrud', 'exercitation', 'ullamco', 'laboris', 'nisi', 'aliquip', 'ex', 'ea', 'commodo',
    'consequat', 'duis', 'aute', 'irure', 'in', 'reprehenderit', 'voluptate', 'velit', 'esse', 'cillum',
    'eu', 'fugiat', 'nulla', 'pariatur', 'excepteur', 'sint', 'occaecat', 'cupidatat', 'non', 'proident',
    'sunt', 'culpa', 'qui', 'officia', 'deserunt', 'mollit', 'anim', 'id', 'est', 'laborum', 'perspiciatis',
    'unde', 'omnis', 'iste', 'natus', 'error', 'voluptatem', 'accusantium', 'doloremque', 'laudantium',
    'totam', 'rem', 'aperiam', 'eaque', 'ipsa', 'quae', 'ab', 'illo', 'inventore', 'veritatis', 'quasi', 'architecto',
    'beatae', 'vitae', 'dicta', 'explicabo', 'nemo', 'ipsam', 'quia', 'voluptas', 'aspernatur', 'aut', 'odit',
    'fugit', 'consequuntur', 'magni', 'dolores', 'eos', 'ratione', 'sequi', 'nesciunt', 'neque', 'porro',
    'quisquam', 'dolorem', 'adipisci', 'numquam', 'eius', 'modi', 'tempora', 'incidunt', 'magnam', 'aliquam',
    'quaerat', 'minima', 'nostrum', 'exercitationem', 'ullam', 'corporis', 'suscipit', 'laboriosam', 'aliquid',
    'commodi', 'consequatur', 'autem', 'vel', 'eum', 'iure', 'quam', 'nihil', 'molestiae', 'illum', 'quo',
    'at', 'vero', 'accusamus', 'iusto', 'odio', 'dignissimos', 'ducimus', 'blanditiis', 'praesentium', 'voluptatum',
    'deleniti', 'atque', 'corrupti', 'quos', 'quas', 'molestias', 'excepturi', 'occaecati', 'cupiditate',
    'provident', 'similique', 'mollitia', 'animi', 'dolorum', 'fuga', 'harum', 'quidem', 'rerum', 'facilis',
    'expedita', 'distinctio', 'nam', 'libero', 'tempore', 'sum', 'soluta', 'nobis', 'eligendi', 'optio',
    'cumque', 'impedit', 'minus', 'quod', 'maxime', 'placeat', 'facere', 'possimus', 'assumenda', 'repellendus',
    'temporibus', 'quibusdam', 'officiis', 'debitis', 'necessitatibus', 'saepe', 'eveniet', 'voluptates',
    'repudiandae', 'recusandae', 'itaque', 'earum', 'hic', 'tenetur', 'a', 'sapiente', 'delectus', 'reiciendis',
    'voluptatibus', 'maiores', 'alias', 'perferendis', 'doloribus', 'asperiores', 'repellat', 'integer',
    'nec', 'praesent', 'cursus', 'ante', 'dapibus', 'diam', 'sem', 'nibh', 'elementum', 'imperdiet', 'sagittis',
    'mauris', 'fusce', 'tellus', 'augue', 'semper', 'porta', 'massa', 'vestibulum', 'lacinia', 'arcu', 'eget',
    'class', 'aptent', 'taciti', 'sociosqu', 'litora', 'torquent', 'per', 'conubia', 'nostra', 'inceptos',
    'himenaeos', 'curabitur', 'sodales', 'ligula', 'dignissim', 'nunc', 'tortor', 'pellentesque', 'aenean',
    'scelerisque', 'maecenas', 'mattis', 'convallis', 'tristique', 'proin', 'egestas', 'porttitor', 'morbi',
    'lectus', 'risus', 'iaculis', 'luctus', 'ac', 'turpis', 'aliquet', 'metus', 'ullamcorper', 'tincidunt',
    'euismod', 'quisque', 'volutpat', 'condimentum', 'urna', 'facilisi', 'fringilla', 'suspendisse', 'potenti',
    'feugiat', 'mi', 'sapien', 'etiam', 'ultrices', 'justo', 'lacus', 'pharetra', 'auctor', 'interdum', 'primis',
    'faucibus', 'orci', 'posuere', 'cubilia', 'curae', 'molestie', 'dui', 'blandit', 'congue', 'pede', 'facilisis',
    'laoreet', 'donec', 'viverra', 'malesuada', 'pulvinar', 'sollicitudin', 'cras', 'nisl', 'felis', 'venenatis',
    'ultricies', 'accumsan', 'pretium', 'fermentum', 'nullam', 'purus', 'mollis', 'vivamus', 'consectetuer'
];


function randomWord() {
    var arr = ipsumLoremWord;
    var idx = randomInt(0, arr.length - 1);
    return arr[idx];
}

function randomPhrase(limitLenght) {
    if (!limitLenght) limitLenght = 50;
    var length = Math.ceil(Math.random() * limitLenght / 7);
    return new Array(length)
        .fill(null)
        .map(randomWord)
        .reduce(function (ac, cr) {
            if (ac.length + cr.length < limitLenght) {
                ac.parts.push(cr);
            }
            return ac;
        }, { parts: [], length: 0 }).parts
        .join(' ');

}

function randomSentence(limitLenght) {
    if (!limitLenght) limitLenght = 300;
    var length = Math.ceil(Math.random() * limitLenght / 70);
    var res = new Array(length)
        .fill(null)
        .map(randomPhrase)
        .reduce(function (ac, cr) {
            if (ac.length + cr.length < limitLenght) {
                ac.parts.push(cr);
            }
            return ac;
        }, { parts: [], length: 0 }).parts
        .join(', ');
    if (Math.random() < 0.03) {
        res = res.replace(/\,/i, ':');
    }
    res = res.replace(/^./, function (x) {
        return x.toUpperCase();
    });
    res += '.';
    return res;
}

function randomParagraph(limitLenght) {
    if (!limitLenght) limitLenght = 1000;
    var length = Math.ceil(Math.random() * limitLenght / 200);
    return new Array(length).fill(null)
        .map(randomSentence)
        .reduce(function (ac, cr) {
            if (ac.length + cr.length < limitLenght) {
                ac.parts.push(cr);
            }
            return ac;
        }, { parts: [], length: 0 }).parts
        .join(' ');
}

/***/ }),
/* 13 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return noop; });
function noop(){};

/***/ }),
/* 14 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "map", function() { return map; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sumArr", function() { return sumArr; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "radianInRange", function() { return radianInRange; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "distance", function() { return distance; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "numberToString", function() { return numberToString; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "numberAutoFixed", function() { return numberAutoFixed; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "integerZeroPadding", function() { return integerZeroPadding; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "harmonicMean", function() { return harmonicMean; });
/**
 *
 * @param {number} x
 * @param {number} l
 * @param {number} h
 * @param {number} L
 * @param {number} H
 * @returns {number}
 */
function map(x, l, h, L, H) {
    return (x - l) / (h - l) * (H - L) + L;
}


function sumArr(arr) {
    var res = 0;
    for (var i = 0; i < arr.length; ++i)
        res += arr[i];
    return res;
}

function radianInRange(x, start, end) {
    if (start > end) return radianInRange(x, end, start);
    if (x < start) x += (Math.PI * 2) * Math.ceil((start - x) / 2 / Math.PI);
    if (x > end) x -= (Math.PI * 2) * Math.ceil((x - end) / 2 / Math.PI);
    return x >= start && x <= end;
}


function distance(x0, y0, x1, y1) {
    var dx = x0 - x1;
    var dy = y0 - y1;
    return Math.sqrt(dx * dx + dy * dy);
}

/**
 *
 * @param {Number} numb
 * @param {Number} floatFixed
 * @param {"."|","} decimalSeparator
 * @param {","|"."} thousandsSeparator
 * @param {Number} decimalPadding
 */
function numberToString(numb, floatFixed, decimalSeparator, thousandsSeparator, decimalPadding) {
    if (floatFixed === undefined || floatFixed === null || typeof floatFixed != "number" || isNaN(floatFixed) || floatFixed < -1) floatFixed = -1;
    if (decimalSeparator === undefined || decimalSeparator === null || (decimalSeparator != '.' && decimalSeparator != ',')) decimalSeparator = '.';
    if (thousandsSeparator === undefined || thousandsSeparator === null || (floatFixed >= 0 && thousandsSeparator == decimalSeparator)) thousandsSeparator = undefined;
    if (thousandsSeparator != ',' && thousandsSeparator != '.') thousandsSeparator = undefined;
    if (decimalPadding === undefined || decimalPadding === null || typeof decimalPadding != "number" || isNaN(decimalPadding) || decimalPadding < 0) decimalPadding = 0;

    var text = numb.toString();
    var matched = text.match(/[+-]?([0-9]*)(\.([0-9]*))?(e([+-]?[0-9]+))?/);
    var dec = matched[1] || '';
    var real = matched[3] || '';
    var floatPoint = parseInt(matched[5] || '0');
    var decDigits = dec.split('').map(function (d) {
        return parseInt(d)
    });
    var realDigits = real.split('').map(function (d) {
        return parseInt(d)
    });

    while (floatPoint < 0) {
        if (decDigits.length > 0) {
            realDigits.unshift(decDigits.pop());
        }
        else {
            realDigits.unshift(0);
        }
        floatPoint++;
    }
    while (floatPoint > 0) {
        if (realDigits.length > 0) {
            decDigits.push(realDigits.unshift());
        }
        else {
            decDigits.push(0);
        }
        floatPoint++;
    }

    var mem = 0, i, cValue;
    if (floatFixed > realDigits.length) {
        while (realDigits.length < floatFixed) {
            realDigits.push(0);
        }
    }
    else if (floatFixed < realDigits.length && floatFixed >= 0) {
        i = floatFixed;
        mem = realDigits[i] >= 5 ? 1 : 0;
        realDigits.splice(floatFixed);
        --i;
        while (mem > 0) {
            if (i >= 0) {
                cValue = realDigits[i] + mem;
                realDigits[i] = cValue % 10;
                mem = Math.floor(cValue / 10);
            }
            else {
                if (decDigits.length + i < 0) decDigits.unshift(0);
                cValue = decDigits[decDigits.length + i] + mem;
                decDigits[decDigits.length + i] = cValue % 10;
                mem = Math.floor(cValue / 10);
            }
            --i;
        }
    }


    while (decDigits.length < decimalPadding) {
        decDigits.unshift(0);
    }

    var decText = numb < 0 ? '-' : '';
    var breadMod = (decDigits.length + 2) % 3;
    if (thousandsSeparator) {
        for (i = 0; i < decDigits.length; ++i) {
            decText += decDigits[i];
            if (i % 3 == breadMod && i + 1 < decDigits.length) {
                decText += thousandsSeparator;
            }
        }
    }
    else {
        decText += decDigits.join('');
    }

    var realText = realDigits.length == 0 ? '' : decimalSeparator + realDigits.join('');

    return decText + realText;
}


function numberAutoFixed(x, eDelta) {
    eDelta = eDelta || 10;
    eDelta = Math.round(eDelta);
    var e = parseFloat('1e+' + eDelta);
    return Math.round(x * e) / e;
}

/***
 *
 * @param {number} number
 * @param {number} length
 * @returns {string}
 */
function integerZeroPadding(number, length) {
    var res = number + '';
    while (res.length < length) res = '0' + res;
    return res;
}

function harmonicMean(a, b) {
    return 2 / (1 / a + 1 / b);
}

/***/ }),
/* 15 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "wrapToLines", function() { return wrapToLines; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "nonAccentVietnamese", function() { return nonAccentVietnamese; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "pascalCaseToCamelCase", function() { return pascalCaseToCamelCase; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "kebabCaseToCamelCase", function() { return kebabCaseToCamelCase; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "underScoreToCamelCase", function() { return underScoreToCamelCase; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "camelCaseToPascalCase", function() { return camelCaseToPascalCase; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "underScoreToPascalCase", function() { return underScoreToPascalCase; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "kebabCaseToPascalCase", function() { return kebabCaseToPascalCase; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "pascalCaseToKebabCase", function() { return pascalCaseToKebabCase; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "camelCaseToKebabCase", function() { return camelCaseToKebabCase; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "underScoreToKebabCase", function() { return underScoreToKebabCase; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "pascalCaseToUnderScore", function() { return pascalCaseToUnderScore; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "pascalCaseToUpperUnderScore", function() { return pascalCaseToUpperUnderScore; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "camelCaseToUnderScore", function() { return camelCaseToUnderScore; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "camelCaseToUpperUnderScore", function() { return camelCaseToUpperUnderScore; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "kebabCaseToUnderScore", function() { return kebabCaseToUnderScore; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "kebabCaseToUpperUnderScore", function() { return kebabCaseToUpperUnderScore; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "normalizeIdent", function() { return normalizeIdent; });
/**
 *
 * @param {String} s
 * @param {Number} maxLength
 */
function wrapToLines(s, maxLength) {
    var res = [];
    var currentWord = '';
    var currentLine = '';
    for (var i = 0; i < s.length; ++i) {
        if (s[i].match(/\s/)) {
            if (currentWord.length + currentLine.length >= maxLength) {
                if (currentLine.length > 0) {
                    res.push(currentLine.trim());
                    currentLine = '';
                    currentWord = currentWord.trimLeft() + s[i];
                }
                else {
                    currentLine = currentLine + currentWord;
                    res.push(currentLine.trim());
                    currentLine = '';
                    currentWord = '';

                }
            }
            else {
                currentLine = currentLine + currentWord;
                currentWord = s[i];
            }
        }
        else {
            currentWord = currentWord + s[i];
        }
    }
    currentLine = (currentLine + currentWord).trim();
    if (currentLine.length > 0) res.push(currentLine);
    return res;
}

/**
 *
 * @param {String} s
 * @returns {String}
 */
function nonAccentVietnamese(s) {
    return s.replace(/à|á|ạ|ả|ã|â|ầ|ấ|ậ|ẩ|ẫ|ă|ằ|ắ|ặ|ẳ|ẵ/g, "a")
        .replace(/À|Á|Ạ|Ả|Ã|Â|Ầ|Ấ|Ậ|Ẩ|Ẫ|Ă|Ằ|Ắ|Ặ|Ẳ|Ẵ/g, "A")
        .replace(/è|é|ẹ|ẻ|ẽ|ê|ề|ế|ệ|ể|ễ/g, "e")
        .replace(/È|É|Ẹ|Ẻ|Ẽ|Ê|Ề|Ế|Ệ|Ể|Ễ/g, "E")
        .replace(/ì|í|ị|ỉ|ĩ/g, "i")
        .replace(/Ì|Í|Ị|Ỉ|Ĩ/g, "I")
        .replace(/ò|ó|ọ|ỏ|õ|ô|ồ|ố|ộ|ổ|ỗ|ơ|ờ|ớ|ợ|ở|ỡ/g, "o")
        .replace(/Ò|Ó|Ọ|Ỏ|Õ|Ô|Ồ|Ố|Ộ|Ổ|Ỗ|Ơ|Ờ|Ớ|Ợ|Ở|Ỡ/g, "O")
        .replace(/ù|ú|ụ|ủ|ũ|ư|ừ|ứ|ự|ử|ữ/g, "u")
        .replace(/Ù|Ú|Ụ|Ủ|Ũ|Ư|Ừ|Ứ|Ự|Ử|Ữ/g, "U")
        .replace(/ỳ|ý|ỵ|ỷ|ỹ/g, "y")
        .replace(/Ỳ|Ý|Ỵ|Ỷ|Ỹ/g, "Y")
        .replace(/đ/g, "d")
        .replace(/Đ/g, "D")
        .replace(/\u0300|\u0301|\u0303|\u0309|\u0323/g, "")
        .replace(/\u02C6|\u0306|\u031B/g, "");
}




/**
 *
 * @param {String} s
 * @returns {String}
 */
function pascalCaseToCamelCase(s) {
    return s.substr(0, 1).toLowerCase() + s.substr(1);
}

/**
 *
 * @param {String} s
 * @returns {String}
 */
function kebabCaseToCamelCase(s) {
    return s.replace(/-+([^-])/g, function (full, c) {
        return c.toUpperCase();
    });
}

/**
 *
 * @param {String} s
 * @returns {String}
 */
function underScoreToCamelCase(s) {
    return s.replace(/(_+)?([^_]+)/g, function (full, underscore, word) {
        if (underscore) {
            if (word) {
                return word.substr(0, 1).toUpperCase() + word.substr(1).toLowerCase();
            }
            else return '';
        }
        else {
            return word.toLowerCase();
        }
    });
}


/**
 *
 * @param {String} s
 * @returns {String}
 */
function camelCaseToPascalCase(s) {
    return s.substr(0, 1).toUpperCase() + s.substr(1);
}

/**
 *
 * @param {String} s
 * @returns {String}
 */
function underScoreToPascalCase(s) {
    return s.replace(/(_+|^)?([^_]+)/g, function (full, underscore, word) {
        return word.substr(0, 1).toUpperCase() + word.substr(1).toLowerCase();
    });
}


/**
 *
 * @param {String} s
 * @returns {String}
 */
function kebabCaseToPascalCase(s) {
    return s.replace(/(-+|^)([^-])/g, function (full, u, c) {
        return c.toUpperCase();
    });
}


/**
 *
 * @param {String} s
 * @returns {String}
 */
function pascalCaseToKebabCase(s) {
    return s.replace(/[A-Z][^A-Z]*/g, function (full, index) {
        if (index == 0)
            return full.toLowerCase();
        return '-' + full.toLowerCase()
    });
}

/**
 *
 * @param {String} s
 * @returns {String}
 */
function camelCaseToKebabCase(s) {
    return s.replace(/(^|[A-Z])[^A-Z]*/g, function (full, index) {
        if (index == 0)
            return full.toLowerCase();
        return '-' + full.toLowerCase()
    });
}

/**
 *
 * @param {String} s
 * @returns {String}
 */
function underScoreToKebabCase(s) {
    return s.replace(/(^|_+)([^_]+)/g, function (full, score, word, index) {
        if (index == 0)
            return word.toLowerCase();
        return '-' + word.toLowerCase()
    });
}


/**
 *
 * @param {String} s
 * @returns {String}
 */
function pascalCaseToUnderScore(s) {
    return s.replace(/[A-Z][^A-Z]*/g, function (full, index) {
        if (index == 0)
            return full.toLowerCase();
        return '_' + full.toLowerCase()
    });
}

/**
 *
 * @param {String} s
 * @returns {String}
 */
function pascalCaseToUpperUnderScore(s) {
    return s.replace(/[A-Z][^A-Z]*/g, function (full, index) {
        if (index == 0)
            return full.toUpperCase();
        return '_' + full.toUpperCase()
    });
}


/**
 *
 * @param {String} s
 * @returns {String}
 */
function camelCaseToUnderScore(s) {
    return s.replace(/(^|[A-Z])[^A-Z]*/g, function (full, index) {
        if (index == 0)
            return full.toLowerCase();
        return '_' + full.toLowerCase()
    });
}

/**
 *
 * @param {String} s
 * @returns {String}
 */
function camelCaseToUpperUnderScore(s) {
    return s.replace(/(^|[A-Z])[^A-Z]*/g, function (full, index) {
        if (index == 0)
            return full.toUpperCase();
        return '_' + full.toUpperCase()
    });
}

/**
 *
 * @param {String} s
 * @returns {String}
 */
function kebabCaseToUnderScore(s) {
    return s.replace(/(-+|^)([^-]+)/g, function (full, u, word, index) {
        if (index == 0) return word.toLowerCase();
        return '_' + word.toLowerCase()
    });
}



/**
 *
 * @param {String} s
 * @returns {String}
 */
function kebabCaseToUpperUnderScore(s) {
    return s.replace(/(-+|^)([^-]+)/g, function (full, u, word, index) {
        if (index == 0) return word.toUpperCase();
        return '_' + word.toUpperCase()
    });
}


/***
 *
 * @param {String} text
 */
function normalizeIdent(text, opt) {
    var spaces = '_';
    if (opt && ('spaces' in opt)) {
        spaces = opt.spaces || '';
    }

    var symbols = '_';
    if (opt && ('symbols' in opt)) {
        symbols = opt.symbols || '';
    }

    var startsWithDigit = false;
    if (opt && ('startsWithDigit' in opt)) {
        startsWithDigit = opt.startsWithDigit || false;
    }


    var res = nonAccentVietnamese(text);
    if (typeof spaces === "string") {
        res = res.replace(/\s+/g, spaces);
    }
    if (typeof symbols === 'string') {
        if (spaces === '_')
            res = res.replace(/[^a-zA-Z0-9_$]+/g, symbols);
        else if (spaces === '-') {
            res = res.replace(/[^a-zA-Z0-9_$\-]+/g, symbols);
        }
    }

    if (!startsWithDigit && res.match(/^[0-9]/)) {
        res = '$' + res;
    }
    return res;
}

String.nonAccentVietnamese = nonAccentVietnamese;

String.prototype.nonAccentVietnamese = function () {
    return String.nonAccentVietnamese(this);
};

/***/ }),
/* 16 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* unused harmony export svgToRasterImageUrl */
/* unused harmony export svgToExportedString */
/* harmony import */ var _Dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1);
/* harmony import */ var _ElementNS__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(65);
/* harmony import */ var _AElement__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(8);
/* harmony import */ var _Color_Color__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(57);





var sattachhookCreator = function () {
    var res = Svg.ShareInstance._('<image  class="absol-attachhook" style="display:none"  href=""/>');
    res.defineEvent('attached');
    res.on('error', function (event) {
        if (!this._attached && this.isDescendantOf(document.body)) {
            this._attached = true;
            this.emit('attached', event, this);
        }
    });
    res._attached = false;
    Object.defineProperty(res, 'attached', {
        get: function () {
            return this._attached;
        }
    });
    res.resetState = function () {
        this._attached = false;
        this.src = '';
    };

    return res;
};

/***
 * @extends Dom
 * @param option
 * @constructor
 */
function Svg(option) {
    _Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].call(this, option);
    this.defaultTag = 'g';
    this.svgNS = "http://www.w3.org/2000/svg";
    Object.defineProperties(this.creator,
        {
            sattachhook: {
                set: function () {
                    //do nothing
                },
                get: function () {
                    return sattachhookCreator;
                }
            }
        });
    delete this.buidDom;
    this.buildSvg = this.create.bind(this);
}


Object.defineProperties(Svg.prototype, Object.getOwnPropertyDescriptors(_Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].prototype));

Svg.prototype.fromCode = function (code) {
    code = code.trim();
    var receptacle = document.createElement('div');
    var element;
    var prototypes;
    if (code.startsWith('<svg')) {
        receptacle.innerHTML = code;
        element = receptacle.childNodes[0];
        prototypes = Object.getOwnPropertyDescriptors(_AElement__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].prototype);
        Object.defineProperties(element, prototypes);
        _AElement__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].call(element);
    } else {
        var svgfragment = '<svg  version="1.1" xmlns="http://www.w3.org/2000/svg">' + code + '</svg>';
        receptacle.innerHTML = '' + svgfragment;
        element = receptacle.childNodes[0].childNodes[0];
        prototypes = Object.getOwnPropertyDescriptors(_ElementNS__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"].prototype);
        Object.defineProperties(element, prototypes);
        _ElementNS__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"].call(element);
    }
    return element;
};


Svg.prototype.makeNewElement = function (tagName) {
    return document.createElementNS(this.svgNS, tagName);
};


Svg.ShareInstance = new Svg();

Svg.svgToCanvas = function (element) {
    if (typeof element == 'string') {
        element = _Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].ShareInstance.$(element);
    }
    if (element && element.tagName == 'svg') {
        var cssTexts = {};
        var depthClone = function (originElt) {
            var newElt = originElt.cloneNode();//no deep
            if (!originElt.getAttributeNS) return newElt;//is text node
            var cssRules = _AElement__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].prototype.getCSSRules.call(originElt);
            var cssKey = cssRules.reduce(function (ac, rule) {
                for (var i = 0; i < rule.style.length; ++i) {
                    ac[rule.style[i]] = true;
                }
                return ac;
            }, {});
            for (var key in cssKey) {
                newElt.style[key] = _AElement__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].prototype.getComputedStyleValue.call(originElt, key);
            }
            var children = Array.prototype.map.call(originElt.childNodes, depthClone);
            for (var i = 0; i < children.length; ++i) {
                newElt.appendChild(children[i]);
            }
            return newElt;
        };

        var cloneElement = depthClone(element);

        var renderSpace = _Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].ShareInstance._({
            style: {
                // opacity:0,
                zIndex: -1000,
                position: 'fixed',
                top: 0,
                bottom: 0
            }
        }).addTo(document.body);
        renderSpace.addChild(cloneElement);

        var svgCode = renderSpace.innerHTML;
        renderSpace.clearChild();

        var mBlob = new Blob([svgCode], {type: "image/svg+xml;charset=utf-8"});
        var src = (URL || webkitURL).createObjectURL(mBlob);

        var image = _Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].ShareInstance._('img');
        image.attr('src', src)
            .addTo(renderSpace);
        var canvas = document.createElement("canvas");
        renderSpace.addChild(canvas);
        return _Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].waitImageLoaded(image).then(function () {
            canvas.width = image.width;
            canvas.height = image.height;
            var context = canvas.getContext("2d");
            context.drawImage(image, 0, 0);
            renderSpace.selfRemove();
            return canvas;
        });
    } else {
        throw new Error('Element must be svg');
    }
};

function svgToRasterImageUrl(element) {
    return Svg.svgToCanvas(element).then(function (canvas) {
        return canvas.toDataURL();
    });
}

Svg.svgToRasterImageUrl = svgToRasterImageUrl;


function svgToExportedString(element) {
    if (typeof element == 'string') {
        element = _Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].ShareInstance.$(element);
    }
    if (element && element.tagName == 'svg') {
        var depthClone = function (originElt) {
            var newElt = originElt.cloneNode();//no deep
            if (!originElt.getAttributeNS) return newElt;//is text node
            var cssRules = _AElement__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].prototype.getCSSRules.call(originElt);
            var cssKey = cssRules.reduce(function (ac, rule) {
                for (var i = 0; i < rule.style.length; ++i) {
                    ac[rule.style[i]] = true;
                }
                return ac;
            }, {});
            for (var key in cssKey) {
                newElt.style[key] = _AElement__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].prototype.getComputedStyleValue.call(originElt, key);
            }
            var children = Array.prototype.map.call(originElt.childNodes, depthClone);
            for (var i = 0; i < children.length; ++i) {
                newElt.appendChild(children[i]);
            }
            return newElt;
        };

        var cloneElement = depthClone(element);
        var renderSpace = _Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].ShareInstance._({
            style: {
                // opacity:0,
                zIndex: -1000,
                position: 'fixed',
                top: 0,
                bottom: 0
            }
        }).addTo(document.body);
        renderSpace.addChild(cloneElement);
        var svgCode = renderSpace.innerHTML;
        renderSpace.selfRemove();
        return svgCode;
    } else {
        throw new Error('Element must be svg');
    }
};

Svg.svgToExportedString = svgToExportedString;


function svgToSvgUrl(element) {
    var svg = svgToExportedString(element);
    svg = '<?xml version="1.0" encoding="UTF-8" standalone="no"?>\n' + svg;
    var blob = new Blob([svg], {type: 'image/svg+xml'});
    var url = URL.createObjectURL(blob);
    return url;
}

Svg.svgToSvgUrl = svgToSvgUrl;


/***
 *
 * @param {AElement|String | {computeStyle?: boolean, elt: AElement, keepBackgroundColor?:boolean,convertSVG?:boolean}} option
 * @return {Promise<unknown>}
 */
_Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].printElement = function (option) {
    var _ = _Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].ShareInstance._;
    var $ = _Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].ShareInstance.$;
    option = option || {};
    if (typeof option == 'string') {
        option = {elt: _Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].ShareInstance.$(option)};
    } else if (typeof option.elt == 'string') {
        option.elt = $(option.elt);
    } else if (_Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].isDomNode(option)) {
        option = {elt: option};
    }
    option = Object.assign({keepBackgroundColor: true, convertSVG: false, computeStyle: false}, option);
    if (_Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].isDomNode(option.elt)) {
        function afterCloneCb(originElt, newElt) {
            if (!newElt.tagName) return;
            var tagName = newElt.tagName.toLowerCase();
            if (newElt.getBBox && tagName !== 'svg') return;
            var url, img;
            var needCopyStyle = option.computeStyle;
            var needKeepBackgroundColor = option.keepBackgroundColor;
            if (tagName === 'canvas' || (tagName === 'svg' && option.convertSVG)) {
                if (tagName === "canvas") {
                    url = originElt.toDataURL();
                } else {
                    url = svgToSvgUrl(originElt);
                }
                img = _({
                    tag: 'img',
                    props: {
                        src: url
                    }
                });
                $(newElt).selfReplace(img);
                newElt = img;
                needCopyStyle = true;
            } else if (tagName === 'script') {
                newElt.remove();
            } else if (tagName === 'img') {
                newElt.setAttribute('src', originElt.src);
            }

            if (needCopyStyle) {
                Object(_Dom__WEBPACK_IMPORTED_MODULE_0__[/* copyStyleRule */ "a"])(originElt, newElt);
            }
            if (needKeepBackgroundColor) {
                try {
                    var bgColor = _AElement__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].prototype.getComputedStyleValue.call(originElt, 'background-color');
                    if (bgColor) {
                        bgColor = _Color_Color__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].parse(bgColor);
                        if (bgColor.rgba[3] > 0) {
                            newElt.style.setProperty('background-color', bgColor.toString('hex8'), 'important');
                        }
                    }
                } catch (e) {

                }
            }

            return newElt;
        }


        var newElt = Object(_Dom__WEBPACK_IMPORTED_MODULE_0__[/* depthClone */ "c"])(option.elt, afterCloneCb);


        var renderSpace = _({
            style: {
                position: 'fixed',
                top: '0',
                left: '0',
                right: '0',
                bottom: '0',
                overflow: 'auto',
                zIndex: '10',
                opacity: '0',
                visibility: 'hidden'
            }
        });

        $('link', document.head, function (elt) {
            var temp = elt.cloneNode(false);
            //copy absolute url
            temp.setAttribute('href', elt.href);
            renderSpace.addChild(temp);
        });

        if (!option.computeStyle) {
            $('style', document.head, function (elt) {
                if (elt == _Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].$printStyle) return;
                renderSpace.addChild(elt.cloneNode(true));
            });
        }

        renderSpace.addChild(newElt);
        var eltCode = renderSpace.innerHTML;
        renderSpace.clearChild();
        option.title = option.title || ($('title', document.head) || {innerHTML: 'absol.js'}).innerHTML;
        var htmlCode = ['<ht' + 'ml>',
            ' <h' + 'ead><title>' + option.title + '</title><meta charset="UTF-8">',
            '<style>',
            option.overideStyle ? 'html, body{width:initial !important; height:initial !important; overflow: initial !important; overflow-x: initial !important;overflow-y: initial !important;  }' : '',
            '@media print {',//still not work
            '    body{',
            '      -webkit-print-color-adjust: exact;',
            '       color-adjust: exact;',
            '    } ',
            '    div, tr, td, table{',
            '    }',
            '  }',
            'div, table, tr, td{',
            '    page-break-inside: initial;',
            '    page-break-before: avoid;',
            '    page-break-after: avoid;',
            '}',
            option.extendCss || '',
            '</style>',
            '</he' + 'ad>',

            '<bod' + 'y>',
            eltCode,
            '<scr' + 'ipt>' + (option.extendScript || '') + '</scri' + 'pt>',//browser parse  script tag fail
            '<scr' + 'ipt>setTimeout(function(){ window.print();},1000);</scri' + 'pt>',//browser parse  script tag fail
            '</bod' + 'y>',
            '</ht' + 'ml>'].join('\n');
        var blob = new Blob([htmlCode], {type: 'text/html; charset=UTF-8'});
        renderSpace.addTo(document.body);
        var iframe = _('iframe').attr('src', URL.createObjectURL(blob)).addStyle({
            width: '100%',
            height: '100%'
        }).addTo(renderSpace);
        return new Promise(function (rs, rj) {
            function waitLoad() {
                if (iframe.contentWindow && iframe.contentWindow.document && iframe.contentWindow.document.body) {
                    if (typeof option.onLoad == 'function') option.onLoad();
                    iframe.contentWindow.focus();
                    setTimeout(function () {
                        function waitFocusBack() {
                            if (!document.hasFocus || document.hasFocus()) {
                                renderSpace.remove();
                                if (typeof option.onFinish == 'function') option.onFinish();
                                rs();
                            } else {
                                setTimeout(waitFocusBack, 300)
                            }
                        }

                        waitFocusBack();
                    }, 4000);
                } else setTimeout(waitLoad, 1000)
            }

            waitLoad();
        });
    } else {
        throw new Error('Invalid param!');
    }
};


/* harmony default export */ __webpack_exports__["a"] = (Svg);

/***/ }),
/* 17 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return prepareSearchForItem; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return prepareSearchForList; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return calcItemMatchScore; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return searchListByText; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return searchTreeListByText; });
/* harmony import */ var absol_src_String_stringFormat__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(15);
/* harmony import */ var absol_src_String_stringMatching__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(39);



var EXTRA_MATCH_SCORE = 7;
var UNCASE_MATCH_SCORE = 4;
var UVN_MATCH_SCORE = 3;
var EQUAL_MATCH_SCORE = 4;
var WORD_MATCH_SCORE = 3;

/***
 *
 * @param {SelectionItem} item
 * @returns {*}
 */
function prepareSearchForItem(item) {
    if (!item.text || !item.text.charAt) item.text = item.text + '';
    var spliter = /\s+/;
    var __text__ = item.text.replace(/([\s\b\-()\[\]]|&#8239;|&nbsp;|&#xA0;|\s)+/g, ' ').trim();
    var __textNoneCase__ = __text__.toLowerCase();
    var __nvnText__ = Object(absol_src_String_stringFormat__WEBPACK_IMPORTED_MODULE_0__["nonAccentVietnamese"])(__text__);
    var __nvnTextNoneCase__ = __nvnText__.toLowerCase();

    Object.defineProperties(item, {
        __text__: {
            configurable: true,
            enumerable: false,
            writable: true,
            value: __text__
        },
        __words__:{
            configurable: true,
            enumerable: false,
            writable: true,
            value: __text__.split(spliter)
        },
        __textNoneCase__:{
            configurable: true,
            enumerable: false,
            writable: true,
            value: __textNoneCase__
        },
        __wordsNoneCase__:{
            configurable: true,
            enumerable: false,
            writable: true,
            value: __textNoneCase__.split(spliter)
        },
        __nvnText__:{
            configurable: true,
            enumerable: false,
            writable: true,
            value: __nvnText__
        },
        __nvnWords__:{
            configurable: true,
            enumerable: false,
            writable: true,
            value: __nvnText__.split(spliter)
        },
        __nvnTextNoneCase__:{
            configurable: true,
            enumerable: false,
            writable: true,
            value: __nvnTextNoneCase__
        },
        __nvnWordsNoneCase__:{
            configurable: true,
            enumerable: false,
            writable: true,
            value: __nvnTextNoneCase__.split(spliter)
        }
    });


    return item;
}

function prepareSearchForList(items) {
    var item;
    for (var i = 0; i < items.length; ++i) {
        if (typeof items[i] == 'string') {
            items[i] = { text: items[i], value: items[i] };
        }
        item = items[i];
        prepareSearchForItem(item);
        if (item.items) prepareSearchForList(item.items);
    }
    return items;
}

function calcItemMatchScore(queryItem, item) {
    var score = 0;
    if (item.__text__ == queryItem.__text__)
        score += EQUAL_MATCH_SCORE * queryItem.__text__.length;

    var extraIndex = item.__text__.indexOf(queryItem.__text__);

    if (extraIndex >= 0) {
        score += EXTRA_MATCH_SCORE * queryItem.__text__.length - extraIndex / item.__text__.length;
    }

    extraIndex = item.__textNoneCase__.indexOf(queryItem.__textNoneCase__);
    if (extraIndex >= 0) {
        score += UNCASE_MATCH_SCORE * queryItem.__text__.length - extraIndex / item.__text__.length;
    }

    extraIndex = item.__nvnTextNoneCase__.indexOf(queryItem.__nvnTextNoneCase__);
    if (extraIndex >= 0) {
        score += UNCASE_MATCH_SCORE * queryItem.__text__.length - extraIndex / item.__text__.length;
    }

    score += Object(absol_src_String_stringMatching__WEBPACK_IMPORTED_MODULE_1__["wordsMatch"])(queryItem.__nvnWordsNoneCase__, item.__nvnWordsNoneCase__) / (queryItem.__nvnWordsNoneCase__.length + 1 + item.__nvnWordsNoneCase__.length) * 2 * WORD_MATCH_SCORE;
    score += Object(absol_src_String_stringMatching__WEBPACK_IMPORTED_MODULE_1__["wordsMatch"])(queryItem.__wordsNoneCase__, item.__wordsNoneCase__) / (queryItem.__wordsNoneCase__.length + 1 + item.__wordsNoneCase__.length) * 2 * WORD_MATCH_SCORE;
    return score;
}

/***
 *
 * @param  {String} query
 * @param {Array<SelectionItem>} items
 */
function searchListByText(query, items) {
    query = (query || '').trim();
    if (query.length == 0 || items.length == 0)
        return items;
    var queryItem = prepareSearchForItem({ text: query });
    var its = items.map(function (item) {
        return {
            item: item,
            score: calcItemMatchScore(queryItem, item)
        }
    });
    its.sort(function (a, b) {
        if (b.score - a.score == 0) {
            if (b.item.__nvnText__ > a.item.__nvnText__) return -1
            return 1;
        }
        return b.score - a.score;
    });
    var midValue = (its[0].score + its[its.length - 1].score) / 2;
    if (midValue === 0) midValue += 0.1;
    if (midValue < 1) midValue = 1;
    return its.filter(function (it) {
        return it.score >= midValue;
    }).map(function (it) {
        return it.item;
    });
}

/***
 *
 * @param  {String} query
 * @param {Array<SelectionItem>} items
 */
function searchTreeListByText(query, items) {
    query = (query || '').trim();
    if (query.length == 0 || items.length == 0)
        return items;
    var queryItem = prepareSearchForItem({ text: query });
    var gmaxScore = 0;
    var gminScore = 1000;

    function makeScoreRecursive(item) {
        var score = calcItemMatchScore(queryItem, item);
        gmaxScore = Math.max(score, gmaxScore);
        gminScore = Math.min(score, gminScore);

        var children = (item.items || []).map(function (item) {
            return makeScoreRecursive(item);
        });

        var maxScore = children.reduce(function (ac, cr) {
            return Math.max(ac, cr.maxScore);
        }, score);

        return {
            score: score,
            maxScore: maxScore,
            item: item,
            children: children
        }
    }

    function sortcmp(a, b) {
        return b.maxScore - a.maxScore;
    }

    function filterItems(nodes, medScore) {
        nodes.sort(sortcmp);
        return nodes.filter(function (node) {
            return node.maxScore >= medScore;
        }).map(function (node) {
            var res;
            if (typeof node.item == 'string') {
                res = node.item;
            }
            else {
                res = Object.assign({}, node.item);
                res.ref = node.item;
                if (node.children && node.children.length > 0) {
                    res.items = filterItems(node.children, medScore);
                    if (res.items.length == 0) delete res.items;
                }
            }
            return res;
        });
    }

    var scoredItems = items.map(makeScoreRecursive);
    var medianScore = (gminScore + gmaxScore) / 2;
    var items = filterItems(scoredItems, medianScore);
    return items;
}



/***/ }),
/* 18 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _Vec2__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(9);


/**
 *
 * @param {Number} x
 * @param {Number} y
 * @param {Number} width
 * @param {Number} height
 */
function Rectangle(x, y, width, height) {
    this.width = width;
    this.height = height;
    this.x = x;
    this.y = y;
}

/**
 *
 * @return {Vec2}
 * @constructor
 */
Rectangle.prototype.A = function () {
    return new _Vec2__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"](this.x, this.y);
};

/***
 *
 * @return {Vec2}
 * @constructor
 */
Rectangle.prototype.B = function () {
    return new _Vec2__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"](this.x + this.width, this.y);
};

/***
 *
 * @return {Vec2}
 * @constructor
 */
Rectangle.prototype.C = function () {
    return new _Vec2__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"](this.x + this.width, this.y + this.height);
};

/***
 *
 * @return {Vec2}
 * @constructor
 */
Rectangle.prototype.D = function () {
    return new _Vec2__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"](this.x, this.y + this.height);
};

/***
 *
 * @return {number}
 */
Rectangle.prototype.square = function () {
    return this.width * this.height;
};


Rectangle.prototype.nearestPoint = function (arg0, arg1) {
    if (arg1) arg0 = _Vec2__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].make(arg0, arg1);
    var res = this.A();
    var mind = res.dist(arg0);
    var d = this.B().dist(arg0);
    if (d < mind) {
        mind = d;
        res = this.B();
    }
    d = this.C().dist(arg0);
    if (d < mind) {
        mind = d;
        res = this.C();
    }
    d = this.D().dist(arg0);
    if (d < mind) {
        mind = d;
        res = this.D();
    }
    return res;
};

Rectangle.prototype.centerPoint = function () {
    return new _Vec2__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"](this.x + this.width / 2, this.y + this.height / 2);
};

/***
 *
 * @param {Rectangle} r
 * @param {boolean} margin
 * @return {boolean}
 */
Rectangle.prototype.isCollapse = function (r, margin) {
    if (!margin) margin = 0;
    if (this.x >= r.x + r.width + margin) return false;
    if (this.y >= r.y + r.height + margin) return false;

    if (r.x >= this.x + this.width + margin) return false;
    if (r.y >= this.y + this.height + margin) return false;
    return true;
};

/***
 *
 * @param {Rectangle} r
 * @return {number}
 */
Rectangle.prototype.collapsedSquare = function (r) {
    var collapseRect = this.collapsedRect(r);
    if (collapseRect) {
        return collapseRect.square();
    }
    else {
        return 0;
    }
};

/***
 *
 * @param {Rectangle} r
 * @return {Rectangle}
 */
Rectangle.prototype.collapsedRect = function (r) {
    var maxX, minX, maxY, minY, width, height;
    minX = Math.max(this.x, r.x);
    minY = Math.max(this.y, r.y);
    maxX = Math.min(this.x + this.width, r.x + r.width);
    maxY = Math.min(this.y + this.height, r.y + r.height);
    width = maxX - minX;
    height = maxY - minY;
    if (width >= 0 && height >= 0) {
        return new Rectangle(minX, minY, width, height);
    }
    return null;
};

/**
 * @param {Rectangle} r
 * @returns {Boolean}
 */
Rectangle.prototype.contains = function (r) {
    return (this.x <= r.x) && (this.y <= r.y) && (this.x + this.width >= r.x + r.width) && (this.y + this.height >= r.y + r.height);
};

/**
 * @param {Vec2} p
 * @returns {Boolean}
 */
Rectangle.prototype.containsPoint = function (p) {
    return (this.x <= p.x) && (this.y <= p.y) && (this.x + this.width >= p.x) && (this.y + this.height >= p.y);
};

/**
 * @param {Rectangle} other
 * @returns {Rectangle}
 */
Rectangle.prototype.merge = function (other) {
    var left = Math.min(this.x, other.x);
    var top = Math.min(this.y, other.y);
    var right = Math.max(this.x + this.width, other.x + other.width);
    var bottom = Math.max(this.y + this.height, other.y + other.height);
    return new Rectangle(left, top, right - left, bottom - top);
};


/**
 * @returns {Rectangle}
 */
Rectangle.prototype.clone = function () {
    return new Rectangle(this.x, this.y, this.width, this.height);
};

/***
 *
 * @param {Rectangle} r
 */
Rectangle.prototype.equals = function (r) {
    return this.x == r.x && this.y == r.y && this.height == r.height && this.width == r.width;
};

/**
 * @param {Number} x
 * @param {Number} y
 * @param {Number} width
 * @param {Number} height
 * @returns {Rectangle}
 */
Rectangle.make = function (x, y, width, height) {
    return new Rectangle(x, y, width, height);
};


/**
 * @param {Number} x
 * @param {Number} y
 * @param {Number} width
 * @param {Number} height
 * @returns {Rectangle}
 */
Rectangle.makeCenter = function (x, y, width, height) {
    return new Rectangle(x - width / 2, y - height / 2, width, height);
};

/**
 * @param {ClientRect|DOMRect} clientRect
 * @returns {Rectangle}
 */
Rectangle.fromClientRect = function (clientRect) {
    return new Rectangle(clientRect.left, clientRect.top, clientRect.width, clientRect.height);
};

/* harmony default export */ __webpack_exports__["a"] = (Rectangle);

/***/ }),
/* 19 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";

// EXPORTS
__webpack_require__.d(__webpack_exports__, "a", function() { return /* binding */ VALUE_HIDDEN; });

// UNUSED EXPORTS: VALUE_NORMAL

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/selectlistbox.css
var selectlistbox = __webpack_require__(207);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/list/search.js
var search = __webpack_require__(17);

// EXTERNAL MODULE: ./node_modules/absol-acomp/ACore.js
var ACore = __webpack_require__(0);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Follower.js
var Follower = __webpack_require__(25);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/SelectList.js
var SelectList = __webpack_require__(45);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/DomSignal.js
var DomSignal = __webpack_require__(20);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/Dom.js + 1 modules
var Dom = __webpack_require__(1);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/list/listIndexing.js
function depthIndexingByValue(items, context) {
    context = context || {idx: 0, dict: {}};
    return items.reduce(function (ac, cr, idx) {
        var value = typeof cr === "string" ? cr : cr.value + '';
        ac[value] = ac[value] || [];
        ac[value].push({
            idx: context.idx++,
            item: cr
        });
        if (cr && cr.items && cr.items.length > 0) {
            depthIndexingByValue(cr.items, context);
        }
        return ac;
    }, context.dict);
}

function indexingByValue(items, dict) {
    return items.reduce(function (ac, cr, idx) {
        var value = typeof cr === "string" ? cr : cr.value + '';
        ac[value] = ac[value] || [];
        ac[value].push({
            idx: idx,
            item: cr
        });
        return ac;
    }, dict || {});
}
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/SelectListBox.js









var _ = ACore["d" /* default */]._;
var $ = ACore["d" /* default */].$;
var $$ = ACore["d" /* default */].$$;

var VALUE_HIDDEN = -1;
var VALUE_NORMAL = 1;

/***
 * @extends Follower
 * @constructor
 */
function SelectListBox() {
    this._initDomHook();
    this._initControl();
    this._initScroller();
    this._initProperty();
    /***
     * @name strictValue
     * @type {boolean}
     * @memberOf SelectListBox#
     */
}

SelectListBox.tag = 'SelectListBox'.toLowerCase();

SelectListBox.render = function () {
    return _({
        tag: 'follower',
        attr: {
            tabindex: 0
        },
        class: 'as-select-list-box',
        extendEvent: ['pressitem'],
        child: [
            {
                class: 'as-select-list-box-search-ctn',
                child: 'searchtextinput'
            },
            {
                class: ['as-bscroller', 'as-select-list-box-scroller'],
                child: [
                    {
                        class: ['as-select-list-box-content'],
                        child: Array(SelectListBox.prototype.preLoadN).fill('.as-select-list-box-page')
                    }
                ]
            },
            'attachhook.as-dom-signal'
        ]
    });
};

SelectListBox.prototype.toLoadNextY = 200;

SelectListBox.prototype.preLoadN = 3;

SelectListBox.prototype.itemHeight = 20;


SelectListBox.prototype._initDomHook = function () {
    this.$domSignal = $('attachhook.as-dom-signal', this);
    this.domSignal = new DomSignal["a" /* default */](this.$domSignal);
    this.domSignal.on('viewListAt', this.viewListAt.bind(this));
    this.domSignal.on('viewListAtFirstSelected', this.viewListAtFirstSelected.bind(this));
    this.domSignal.on('viewListAtCurrentScrollTop', this.viewListAtCurrentScrollTop.bind(this));
};

SelectListBox.prototype._initControl = function () {
    this._currentOffset = 0;
    this._startItemIdx = 0;
    this.$searchInput = $('searchtextinput', this)
        .on('stoptyping', this.eventHandler.searchModify);
};


SelectListBox.prototype._initScroller = function () {
    this.$content = $('.as-select-list-box-content', this);
    this._estimateHeight = 0;
    this._pageOffsets = Array(this.preLoadN + 1).fill(0);
    this.$listPages = $$('.as-select-list-box-page', this);
    this.$listScroller = $('.as-select-list-box-scroller', this)
        .on('scroll', this.eventHandler.scroll);
};


SelectListBox.prototype._initProperty = function () {

    /***
     *   items  =(search, filler)=> filteredItems =(list to list, tree to list)=>  preDisplayItems =(remove hidden item)=> displayItem
     *
     */

    this._items = [];
    this._itemNodeList = [];// use for tree
    this._values = [];
    this._valueDict = {};
    this._itemNodeHolderByValue = {};
    // this._filteredItems = [];// not need , only use when search
    this._preDisplayItems = [];
    this._displayItems = [];
    this._searchCache = {};
    this._displayValue = VALUE_NORMAL;
    this.displayValue = VALUE_NORMAL;
    this.items = [];
};


SelectListBox.prototype._requireItem = function (pageElt, n) {
    var itemElt;
    while (pageElt.childNodes.length > n) {
        itemElt = pageElt.lastChild;
        itemElt.selfRemove();
        Object(SelectList["d" /* releaseItem */])(itemElt);
    }
    while (pageElt.childNodes.length < n) {
        itemElt = Object(SelectList["e" /* requireItem */])(this);
        pageElt.addChild(itemElt);
    }
};


SelectListBox.prototype._assignItems = function (pageElt, offset) {
    var n = Math.min(this._displayItems.length - offset, pageElt.childNodes.length);
    var itemElt, value;
    for (var i = 0; i < n; ++i) {
        itemElt = pageElt.childNodes[i];
        itemElt.data = this._displayItems[offset + i];
        value = itemElt.value + '';
    }
};


SelectListBox.prototype._itemsToNodeList = function (items) {
    return items;
};


/***
 *
 * @param {Array<{value:String|Number}>} items
 * @return {Array<{value:String|Number}>}
 */
SelectListBox.prototype._filterDisplayItems = function (items) {
    if (this._displayValue === VALUE_NORMAL) return items;
    var dict = this._valueDict;
    return items.filter(function (item) {
        return !dict[item.value + ''];
    });
};


SelectListBox.prototype._updateSelectedItem = function () {
    var valueDict = this._valueDict;
    this.$listPages.forEach(function (pageElt) {
        Array.prototype.forEach.call(pageElt.childNodes, function (itemElt) {
            var value = itemElt.value + '';
            if (valueDict[value]) {
                itemElt.selected = true;
            }
            else {
                itemElt.selected = false;
            }
        });
    });
};

/***
 *
 * @param {number} offset
 */
SelectListBox.prototype.viewListAt = function (offset) {
    if (!this.isDescendantOf(document.body)) {
        this.domSignal.emit('viewListAt', offset);
        return;
    }
    var fontSize = this.$listScroller.getFontSize() || 14;
    offset = Math.max(0, Math.min(offset, this._displayItems.length - 1));
    var screenSize = Object(Dom["d" /* getScreenSize */])();
    var maxItem = Math.ceil(Math.max(window.screen.height, screenSize.height) / this.itemHeight);
    var contentBound = this.$content.getBoundingClientRect();

    this._pageOffsets[0] = Math.max(offset - maxItem, 0);
    for (var i = 1; i <= this.preLoadN; ++i) {
        this._pageOffsets[i] = Math.min(this._pageOffsets[i - 1] + maxItem, this._displayItems.length);
    }

    var sIdx, nItem, pageBound;
    var pageElt;
    for (var pageIndex = 0; pageIndex < this.preLoadN; ++pageIndex) {
        sIdx = this._pageOffsets[pageIndex];
        nItem = this._pageOffsets[pageIndex + 1] - sIdx;
        pageElt = this.$listPages[pageIndex];


        pageElt.addStyle('top', this._pageOffsets[pageIndex] * this.itemHeight + 'px');
        this._requireItem(pageElt, nItem);
        this._assignItems(pageElt, sIdx);
        pageBound = pageElt.getBoundingClientRect();
    }
    this._updateSelectedItem();
};


SelectListBox.prototype.viewListAtFirstSelected = function () {
    if (!this.isDescendantOf(document.body)) {
        this.domSignal.emit('viewListAtFirstSelected');
        return;
    }
    if (this._displayValue == VALUE_HIDDEN) {
        return false;
    }
    else if (this._values.length > 0) {
        var value = this._values[0];
        var itemHolders = this._displayItemHolderByValue[value + ''];
        if (itemHolders) {
            this.domSignal.once('scrollIntoSelected', function () {
                var holder = itemHolders[0];
                this.viewListAt(holder.idx);
                var itemElt = $('.as-selected', this.$listScroller);
                if (itemElt) {
                    var scrollBound = this.$listScroller.getBoundingClientRect();
                    var itemBound = itemElt.getBoundingClientRect();
                    this.$listScroller.scrollTop += itemBound.top - scrollBound.top;
                }
            }.bind(this));
            this.domSignal.emit('scrollIntoSelected');
            return true;
        }
        else return false;
    }
    else
        return false;
};

SelectListBox.prototype.viewListAtCurrentScrollTop = function () {
    if (!this.isDescendantOf(document.body)) {
        this.emit('viewListAtCurrentScrollTop');
        return;
    }
    this.viewListAt(Math.floor(this.$listScroller.scrollTop / this.itemHeight));
};


SelectListBox.prototype.searchItemByText = function (text) {
    text = text.trim();
    if (text.length == 0) return this._items;
    if (this._searchCache[text]) return this._searchCache[text];
    this._searchCache[text] = Object(search["d" /* searchListByText */])(text, this._items);
    return this._searchCache[text];
};

SelectListBox.prototype.resetSearchState = function () {
    this.$searchInput.value = '';
    this._preDisplayItems = this._itemsToNodeList(this._items);
    this._updateDisplayItem();
    this.domSignal.emit('viewListAt', 0);
    this.$listScroller.scrollTop = 0;
};

SelectListBox.prototype.notifyPressOut = function () {
    this.emit('pressout', { target: this, type: 'pressout' }, this);
};

SelectListBox.prototype.notifyPressClose = function () {
    this.emit('pressclose', { target: this, type: 'pressclose' }, this);
};

SelectListBox.prototype._findFirstPageIdx = function () {
    for (var i = 0; i < this.preLoadN; ++i) {
        if (this._pageOffsets[i + 1] - this._pageOffsets[i] > 0) {
            return i;
        }
    }
    return -1;
};

SelectListBox.prototype._findLastPageIdx = function () {
    for (var i = this.preLoadN - 1; i >= 0; --i) {
        if (this._pageOffsets[i + 1] - this._pageOffsets[i] > 0) {
            return i;
        }
    }
    return -1;
};

SelectListBox.prototype._updateDisplayItemIndex = function () {
    this._displayItemHolderByValue = indexingByValue(this._displayItems, {});
};

SelectListBox.prototype._updateItemNodeIndex = function () {
    this._itemNodeHolderByValue = depthIndexingByValue(this._items);
};

SelectListBox.prototype._updateDisplayItem = function () {
    this._displayItems = this._filterDisplayItems(this._preDisplayItems);
    this._updateDisplayItemIndex();
    this.$content.addStyle({
        'height': this._displayItems.length * this.itemHeight + 'px'
    });

};

SelectListBox.prototype.footerMinWidth = 0;
SelectListBox.prototype._updateItems = function () {
    this._preDisplayItems = this._itemsToNodeList(this._items);
    this._searchCache = {};
    var estimateSize = Object(SelectList["b" /* measureListSize */])(this._itemNodeList);
    this._estimateSize = estimateSize;
    this._estimateWidth = estimateSize.width;
    this._estimateDescWidth = estimateSize.descWidth;
    this.addStyle('--select-list-estimate-width', Math.max(this.footerMinWidth, estimateSize.width) + 'px');
    this.addStyle('--select-list-desc-width', estimateSize.descWidth + 'px')
    this._updateDisplayItem();
};

/***
 *
 * @param value
 * @returns {{idx: number, item:{text:string, value:number|string}}[]}
 */
SelectListBox.prototype.findDisplayItemsByValue = function (value) {
    return (this._displayItemHolderByValue[value] || []).slice();
};


SelectListBox.prototype._implicit = function (values) {
    if (!(values instanceof Array)) {
        if (values === null || values === undefined) values = [];
        else values = [values];
    }
    return values.reduce(function (ac, cr){
        if (!ac.dict[cr]){
            ac.dict[cr] = true;
            ac.result.push(cr);
        }
        return ac;
    }, {result: [], dict: {}}).result;
};

SelectListBox.prototype._explicit = function (values) {
    if (this.strictValue) {
        return values.filter(function (value) {
            return !!this._itemNodeHolderByValue[value];
        }.bind(this));
    }
    else {
        return values.slice();
    }
};


/***
 *
 * @param value
 * @returns {{idx: number, item:{text:string, value:number|string}}[]}
 */
SelectListBox.prototype.findItemsByValue = function (value) {
    return (this._itemNodeHolderByValue[value] || []).slice();
};

SelectListBox.property = {};

/***
 *
 * @type {SelectListBox|{}}
 */
SelectListBox.property.items = {
    set: function (items) {
        items = items || [];
        if (!(items instanceof Array)) items = [];
        Object(search["c" /* prepareSearchForList */])(items);
        this._items = items;
        this._itemNodeList = this._itemsToNodeList(this._items);
        this._updateItemNodeIndex();
        this._updateItems();
        this.viewListAt(0);
    },
    get: function () {
        return this._items;
    }
}


SelectListBox.property.values = {
    set: function (values) {
        values = this._implicit(values);
        this._values = values;
        this._valueDict = values.reduce(function (ac, cr) {
            ac[cr + ''] = true;
            return ac;
        }, {});
        this._updateDisplayItem();
        this.viewListAtCurrentScrollTop();
        if (this._pageOffsets[this.preLoadN] > this._pageOffsets[0]) this._updateSelectedItem();
    },
    get: function () {
        return this._explicit(this._values);
    }
};


SelectListBox.property.strictValue = {
    set: function (value) {
        if (value) {
            this.addClass('as-strict-value');
        }
        else {
            this.removeClass('as-strict-value');
        }
    },
    get: function () {
        return this.containsClass('as-strict-value');
    }
};

SelectListBox.property.displayValue = {
    set: function (value) {
        this._displayValue = value;
        this._displayItems = this._filterDisplayItems(this._preDisplayItems);
        this._updateItemNodeIndex();
        if (value === VALUE_HIDDEN) {
            this.addClass('as-value-hidden');
        }
        else {
            this.removeClass('as-value-hidden');
        }
    },
    get: function () {
        return this._displayValue;
    }
}

SelectListBox.property.enableSearch = {
    set: function (value) {
        if (value) this.addClass('as-enable-search');
        else this.removeClass('as-enable-search');
    },
    get: function () {
        return this.containsClass('as-enable-search');
    }
};

/***
 *
 * @type {SelectListBox|{}}
 */
SelectListBox.eventHandler = {};


/*
*
* @param {MouseEvent} event
*/
SelectListBox.eventHandler.click = function (event) {
    if (event.target === this)
        this.notifyPressOut();
};

SelectListBox.eventHandler.searchModify = function () {
    var text = this.$searchInput.value;
    var searchedItems = this.searchItemByText(text);
    this._preDisplayItems = this._itemsToNodeList(searchedItems);
    this._displayItems = this._filterDisplayItems(this._preDisplayItems);
    this.$content.addStyle({
        'height': this._displayItems.length * this.itemHeight + 'px'
    });
    this._updateItemNodeIndex();
    this.viewListAt(0);
    this.$listScroller.scrollTop = 0;
    this.updatePosition();
};


SelectListBox.eventHandler.scroll = function () {
    var scrollerBound = this.$listScroller.getBoundingClientRect();
    var topIdx = this._findFirstPageIdx();
    if (!this.$listPages[topIdx]) return;
    var screenSize = Object(Dom["d" /* getScreenSize */])();
    var maxItem = Math.ceil(Math.max(window.screen.height, screenSize.height) / this.itemHeight);
    var topBound = this.$listPages[topIdx].getBoundingClientRect();
    var botIdx = this._findLastPageIdx();
    if (!this.$listPages[botIdx]) return;
    var botBound;
    botBound = this.$listPages[botIdx].getBoundingClientRect();
    if (topBound.top > scrollerBound.top || topBound.bottom < scrollerBound.bottom) {
        this.viewListAt(Math.floor(this.$listScroller.scrollTop / this.itemHeight))
        return;
    }

    if (this._pageOffsets[topIdx] > 0) {
        if (topBound.top + this.toLoadNextY > scrollerBound.top) {
            this._pageOffsets.unshift(this._pageOffsets.pop());
            this.$listPages.unshift(this.$listPages.pop());
            this._pageOffsets[topIdx] = Math.max(0, this._pageOffsets[topIdx + 1] - maxItem);

            this._requireItem(this.$listPages[topIdx], this._pageOffsets[topIdx + 1] - this._pageOffsets[topIdx]);
            this._assignItems(this.$listPages[topIdx], this._pageOffsets[topIdx]);
            this._updateSelectedItem();
            this.$listPages[topIdx].addStyle('top', this._pageOffsets[topIdx] * this.itemHeight + 'px');
        }
    }

    if (this._pageOffsets[botIdx + 1] < this._displayItems.length) {
        if (botBound.bottom - this.toLoadNextY < scrollerBound.bottom) {
            this._pageOffsets.push(this._pageOffsets.shift());
            this.$listPages.push(this.$listPages.shift());
            this._pageOffsets[botIdx + 1] = Math.min(this._displayItems.length, this._pageOffsets[botIdx] + maxItem);
            this.$listPages[botIdx].addStyle('top', this._pageOffsets[botIdx] * this.itemHeight + 'px');
            this._requireItem(this.$listPages[botIdx], this._pageOffsets[botIdx + 1] - this._pageOffsets[botIdx]);
            this._assignItems(this.$listPages[botIdx], this._pageOffsets[botIdx]);
            this._updateSelectedItem();
        }
    }
};

ACore["d" /* default */].install(SelectListBox);

/* harmony default export */ var js_SelectListBox = __webpack_exports__["b"] = (SelectListBox);


/***/ }),
/* 20 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _Dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1);
/* harmony import */ var _EventEmitter__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(3);
/* harmony import */ var _AElement__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(8);




/***
 *
 * @extends EventEmitter
 * @param {AElement} attachHookElt
 * @constructor
 */
function DomSignal(attachHookElt) {
    _EventEmitter__WEBPACK_IMPORTED_MODULE_1__[/* default */ "b"].call(this);
    this.signals = {};
    this.ev_attached = this.ev_attached.bind(this);
    this.$attachhook = attachHookElt || _Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].ShareInstance._('attachhook');
    this.$attachhookParent = (attachHookElt && attachHookElt.parentElement) || null;
    this.$attachhook.on('attached', this.ev_attached);
}

Object.defineProperties(DomSignal.prototype, Object.getOwnPropertyDescriptors(_EventEmitter__WEBPACK_IMPORTED_MODULE_1__[/* default */ "b"].prototype));
DomSignal.prototype.constructor = DomSignal;


DomSignal.prototype.execSignal = function () {
    var signals = this.signals;
    if (this.$attachhook) {
        this.$attachhook.remove();
        this.$attachhook.resetState();
    }
    this.signals = {};
    for (var name in signals) {
        this.fire.apply(this, [name].concat(signals[name]));
    }
};

DomSignal.prototype.emit = function (name) {
    this.signals[name] = Array.prototype.slice.call(arguments, 1);
    if (!this.$attachhookParent) {
        this.$attachhookParent = document.body;
    }
    if (!this.$attachhook.parentElement) {
        this.$attachhookParent.appendChild(this.$attachhook);
    }
};

DomSignal.prototype.ev_attached = function () {
    this.execSignal();
};

/* harmony default export */ __webpack_exports__["a"] = (DomSignal);

/***/ }),
/* 21 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_selectmenu_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(94);
/* harmony import */ var _css_selectmenu_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_selectmenu_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1);
/* harmony import */ var absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2);








_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].creator['dropdown-ico'] = function () {
    return Object(_ACore__WEBPACK_IMPORTED_MODULE_1__[/* _ */ "c"])([
        '<svg class="dropdown" width="100mm" height="100mm" version="1.1" viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg">',
        '<g transform="translate(0,-197)">',
        '<path d="m6.3152 218.09a4.5283 4.5283 0 0 0-3.5673 7.3141l43.361 55.641a4.5283 4.5283 0 0 0 7.1421 7e-3l43.496-55.641a4.5283 4.5283 0 0 0-3.5673-7.3216z" />',
        '</g>',
        '</svg>'
    ].join(''));
};


/***
 * @extends AElement
 * @constructor
 */
function SelectMenu() {
    this._value = null;
    this._lastValue = null;
    this.$holderItem = Object(_ACore__WEBPACK_IMPORTED_MODULE_1__[/* $ */ "a"])('.absol-selectmenu-holder-item', this);
    this.$viewItem = Object(_ACore__WEBPACK_IMPORTED_MODULE_1__[/* $ */ "a"])('.absol-selectmenu-holder-item selectlistitem', this);
    /***
     *
     * @type {SelectListBox}
     */
    this.$selectlistBox = Object(_ACore__WEBPACK_IMPORTED_MODULE_1__[/* _ */ "c"])({
        tag: 'selectlistbox',
        props: {
            anchor: [1, 6, 2, 5],
            strictValue: true
        },
        on: {
            preupdateposition: this.eventHandler.preUpdateListPosition
        }
    });
    this.$selectlistBox.on('pressitem', this.eventHandler.selectListBoxPressItem);
    this.$selectlistBox.followTarget = this;
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_4__[/* default */ "a"].drillProperty(this, this.$selectlistBox, 'enableSearch');
    this.strictValue = true;

    this._lastValue = "NOTHING_VALUE";
    this._isFocus = false;
    this.isFocus = false;

    this.on('mousedown', this.eventHandler.click, true);
    /***
     * @name items
     * @type {[]}
     * @memberOf SelectMenu#
     */

}

SelectMenu.tag = 'selectmenu';
SelectMenu.render = function () {
    return Object(_ACore__WEBPACK_IMPORTED_MODULE_1__[/* _ */ "c"])({
        class: ['absol-selectmenu', 'as-select-menu'],
        extendEvent: ['change'],
        attr: {
            tabindex: '1'
        },
        child: [
            {
                class: 'absol-selectmenu-holder-item',
                child: 'selectlistitem'
            },
            {
                tag: 'button',
                class: 'absol-selectmenu-btn',
                child: ['dropdown-ico']
            }
        ]
    });
};


SelectMenu.prototype.init = function (props) {
    props = props || {};
    Object.keys(props).forEach(function (key) {
        if (props[key] === undefined) delete props[key];
    });

    if (!('value' in props)) {
        if (props.items && props.items.length > 0) props.value = typeof props.items[0] == 'string' ? props.items[0] : props.items[0].value;
    }
    var value = props.value;
    delete props.value;
    this.super(props);
    this.value = value;
};


SelectMenu.prototype.updateItem = function () {
    var value = this._explicit(this._value);
    var selectedItems = this.$selectlistBox.findDisplayItemsByValue(value);
    if (selectedItems.length >= 1) {
        this.$viewItem.data = selectedItems[0].item;
    }
    else {
        this.$viewItem.data = { text: '', value: null }
    }
};


SelectMenu.prototype.findItemsByValue = function (value) {
    return this.$selectlistBox.findItemsByValue(value);
};


SelectMenu.prototype._explicit = function (value) {
    var items = this.$selectlistBox.findItemsByValue(value);
    if (items.length > 0 || !this.strictValue || this.items.length === 0) {
        return value;
    }
    else {
        return this.items[0].value;
    }
};


SelectMenu.property = {};
SelectMenu.property.items = {
    set: function (items) {
        items = items || [];
        this.$selectlistBox.items = items;
        this.addStyle('--select-list-estimate-width', this.$selectlistBox._estimateWidth + 'px');
        this.addStyle('--select-list-desc-width', this.$selectlistBox._estimateDescWidth + 'px');
        this.updateItem();
    },
    get: function () {
        return this.$selectlistBox.items;
    }
};

SelectMenu.property.value = {
    set: function (value) {
        this.$selectlistBox.values = [value];
        this._lastValue = value;
        this._value = value;
        this.updateItem();
    },
    get: function () {
        return this._explicit(this._value);
    }
};

/***
 *
 * @type {SelectMenu|{}}
 */
SelectMenu.property.isFocus = {
    set: function (value) {
        var thisSM = this;
        if (!this.items || this.items.length === 0) value = false;//prevent focus
        if (this._isFocus === value) return;
        this._isFocus = !!value;
        if (this._isFocus) {
            document.body.appendChild(this.$selectlistBox);
            this.$selectlistBox.domSignal.$attachhook.emit('attached');
            var bound = this.getBoundingClientRect();
            this.$selectlistBox.addStyle('min-width', bound.width + 'px');
            this.$selectlistBox.refollow();
            this.$selectlistBox.updatePosition();
            setTimeout(function () {
                if (thisSM.enableSearch) {
                    thisSM.$selectlistBox.$searchInput.focus();
                }
                else {
                    thisSM.$selectlistBox.focus();
                }
                document.addEventListener('click', thisSM.eventHandler.bodyClick);
            }, 100);
            this.$selectlistBox.viewListAtFirstSelected();
        }
        else {
            document.removeEventListener('click', thisSM.eventHandler.bodyClick);
            this.$selectlistBox.selfRemove();
            this.$selectlistBox.unfollow();
            this.$selectlistBox.resetSearchState();
        }
    },
    get: function () {
        return this._isFocus;
    }
};


SelectMenu.property.disabled = {
    set: function (value) {
        if (value) {
            this.addClass('as-disabled');
        }
        else {
            this.removeClass('as-disabled');
        }
    },
    get: function () {
        return this.containsClass('as-disabled');
    }
};


SelectMenu.property.hidden = {
    set: function (value) {
        if (value) {
            this.addClass('as-hidden');
        }
        else {
            this.removeClass('as-hidden');
        }
    },
    get: function () {
        return this.addClass('as-hidden');
    }
};

SelectMenu.property.selectedIndex = {
    get: function () {
        var selectedItems = this.$selectlistBox.findItemsByValue(this._value);
        if (selectedItems.length > 0) {
            return selectedItems[0].idx;
        }
        return -1;
    }
};


SelectMenu.property.strictValue = {
    set: function (value) {
        if (value) {
            this.attr('data-strict-value', null);
        }
        else {
            this.attr('data-strict-value', 'false');
        }
        this.updateItem();
    },
    get: function () {
        return !this.attr('data-strict-value') || (this.attr('data-strict-value') !== 'false' && this.attr('data-strict-value') !== '0');
    }
};


/**
 * @type {SelectMenu|{}}
 */
SelectMenu.eventHandler = {};


SelectMenu.eventHandler.click = function (event) {
    if (absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_2__[/* default */ "b"].isMouseRight(event)) return;
    if (absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_2__[/* default */ "b"].hitElement(this.$selectlistBox, event)) return;
    this.isFocus = !this.isFocus;
};


SelectMenu.eventHandler.bodyClick = function (event) {
    if (!absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_2__[/* default */ "b"].hitElement(this, event) && !absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_2__[/* default */ "b"].hitElement(this.$selectlistBox, event)) {
        setTimeout(function () {
            this.isFocus = false;
        }.bind(this), 5)
    }
};

SelectMenu.eventHandler.selectListBoxPressItem = function (event) {
    this._value = event.data.value;
    this.$selectlistBox.values = [this._value];
    this.updateItem();
    if (this._lastValue !== this.value) {
        event.lastValue = this._lastValue;
        event.value = this.value;
        setTimeout(function () {
            this.emit('change', event, this);
        }.bind(this), 1)
        this._lastValue = this.value;

    }
    setTimeout(function () {
        this.isFocus = false;
    }.bind(this), 50)
};

SelectMenu.eventHandler.preUpdateListPosition = function () {
    var bound = this.getBoundingClientRect();
    var screenSize = Object(absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_3__[/* getScreenSize */ "d"])();
    var availableTop = bound.top - 5;
    var availableBot = screenSize.height - 5 - bound.bottom;
    this.$selectlistBox.addStyle('--max-height', Math.max(availableBot, availableTop) + 'px');
    var outBound = Object(absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_3__[/* traceOutBoundingClientRect */ "f"])(this);
    if (bound.bottom < outBound.top || bound.top > outBound.bottom || bound.right < outBound.left || bound.left > outBound.right) {
        this.isFocus = false;
    }
};


_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(SelectMenu);

/* harmony default export */ __webpack_exports__["a"] = (SelectMenu);


/***/ }),
/* 22 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return ExpNode; });
/* unused harmony export ExpTree */
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return ExpGroup; });
/* harmony import */ var _css_exptree_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(150);
/* harmony import */ var _css_exptree_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_exptree_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4);
/* harmony import */ var absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2);
/* harmony import */ var absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(3);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(1);
/* harmony import */ var absol_src_HTML5_AElement__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(8);








var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;


_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install('toggler-ico', function () {
    var res = _(
        '<svg class="toggler-ico" width="14" height="14" version="1.1" viewBox="0 0 3.7042 3.7042" xmlns="http://www.w3.org/2000/svg" >' +
        '    <rect style="fill: transparent; stroke: none" x="0" y="0" width="3.7042" height="3.7042"></rect>' +
        '    <g transform="translate(0 -293.3)" class="toggle-close">' +
        '        <path d="m0.52917 293.82v2.6458l2.6458-1.3229z" />' +
        '    </g>' +
        '    <g transform="translate(0 -293.3)" class="toggle-open">' +
        '        <path d="m3.175 294.09-2.6458 2.1167h2.6458z"/>' +
        '    </g>' +
        '</svg>'
    );
    return res;
});

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install('remove-ico', function () {
    return _('<svg class="remove-ico" width="24" height="24" viewBox="0 0 24 24">\
                <rect style="fill: transparent; stroke: none" x="0" y="0" width="24" height="24"></rect>\
                <path class="close" d="M3,16.74L7.76,12L3,7.26L7.26,3L12,7.76L16.74,3L21,7.26L16.24,12L21,16.74L16.74,21L12,16.24L7.26,21L3,16.74" />\
                <circle class="modified" cx="12" cy="12" r="10" />\
            </svg>');
});

/***
 * @extends AElement
 * @constructor
 */
function ExpNode() {
    var thisEN = this;
    this.$level = $('.absol-exp-node-level', this);
    this.$removeIcon = $('remove-ico', this)
        .on('click', function (event) {
            thisEN.emit('pressremove', {target: thisEN, type: 'pressremove'}, this);
        });
    this.on('keydown', this.eventHandler.buttonKeydown);

    this.$toggleIcon = $('toggler-ico', this)
        .on('click', function (event) {
            thisEN.emit('presstoggle', Object(absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__[/* copyEvent */ "a"])(event, {target: thisEN, type: 'pressremove'}), this);
        });

    this.on('click', function (event) {
        if (!absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].hitElement(thisEN.$removeIcon, event) && !absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].hitElement(thisEN.$toggleIcon, event))
            thisEN.emit('press', Object(absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__[/* copyEvent */ "a"])(event, {target: thisEN, type: 'press'}), this);
    })

    this.$iconCtn = $('div.absol-exp-node-ext-icon', this);
    this.$extIcon = $('img.absol-exp-node-ext-icon', this);
    this.$name = $('span.absol-exp-node-name', this);
    this.$desc = $('span.absol-exp-node-desc', this);
    Object(_utils__WEBPACK_IMPORTED_MODULE_2__["contenteditableTextOnly"])(this.$name, function (text) {
        return text.replace(/[\\\/\|\?\:\<\>\*\r\n]/, '').trim();
    });
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].drillProperty(thisEN, thisEN.$extIcon, 'extSrc', 'src');
    this._level = 0;
    this.__isExpNode__ = true;
    return thisEN;
}


ExpNode.tag = 'expnode';

ExpNode.render = function () {
    return _({
        tag: 'button',
        extendEvent: ['pressremove', 'press', 'presstoggle'],
        class: 'absol-exp-node',
        child: [
            '.absol-exp-node-level',
            'remove-ico',
            'toggler-ico',
            'img.absol-exp-node-ext-icon',
            'div.absol-exp-node-ext-icon',
            'span.absol-exp-node-name',
            'span.absol-exp-node-desc'
        ]
    });
};

ExpNode.property = {};

ExpNode.property.icon = {
    set: function (value) {
        if (this.$iconP) {
            this.$iconP.remove();
            this.$iconP = undefined;
        }
        if (value && value != null) {
            var newE;
            if (!absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_5__[/* default */ "b"].isDomNode(value)) {
                newE = _(value);
            }
            this.$iconP = newE;
            this.$iconCtn.addChild(newE);
            this._icon = value;
        } else {
            this._icon = undefined;
        }
    },
    get: function () {
        return this._icon;
    }
};

ExpNode.property.level = {
    set: function (value) {
        value = value || 0;
        if (value !== this.level) {
            this._level = value || 0;

            this.$level.innerHTML = '&nbsp;'.repeat(this._level * 6);
        }
    },
    get: function () {
        return this._level || 0;
    }
};


ExpNode.property.name = {
    set: function (value) {
        value = value + '';
        this._name = value;
        this.$name.clearChild();
        if (value && value.length > 0)
            this.$name.addChild(_({text: value}));
    },
    get: function () {
        return this._name || '';
    }
};
ExpNode.property.desc = {
    set: function (value) {
        this._desc = (value || '') + '';
        this.$desc.clearChild();
        this.$desc.addChild(_({text: this._desc}));
    },
    get: function () {
        return this._desc || '';
    }
};


ExpNode.property.status = {
    set: function (value) {
        this.removeClass('status-open')
            .removeClass('status-close')
            .removeClass('status-modified')
            .removeClass('status-removable');
        if (!value || value == 'none') {
            //todo

        } else if (value == 'close') {
            this.addClass('status-close')
        } else if (value == 'open') {
            this.addClass('status-open');
        } else if (value == 'removable') {
            this.addClass('status-removable');
        } else if (value == 'modified') {
            this.addClass('status-modified');
        } else {
            throw new Error('Invalid status ' + value)
        }
        this._status = value;
    },
    get: function () {
        return this._status;
    }
}

ExpNode.property.active = {
    set: function (value) {
        if (value) {
            this.addClass('as-active');
            this.addClass('active');
        } else {
            this.removeClass('as-active');
            this.removeClass('active');
        }
    },
    get: function () {
        return this.containsClass('as-active');
    }
};

ExpNode.prototype.rename = function (resolveCallback, rejectCallback) {
    var self = this;
    var span = this.$name;
    var lastName = span.innerHTML;
    span.attr('contenteditable', 'true');
    span.focus();
    document.execCommand('selectAll', false, null);

    function keydowEventHandle(event) {
        var key = event.key;
        if (key == 'Enter') {
            event.preventDefault();
            span.blur();
            span.attr('contenteditable', undefined);
        } else if (key == "ESC") {
            event.preventDefault();
            span.innerHTML = lastName;
            span.blur();
            span.attr('contenteditable', undefined);
        }
    }

    function blurEventHandle(event) {
        finish();
        var curentName = span.innerHTML.replace(/[\\\/\|\?\:\<\>\*\r\n]/, '').trim();
        if (curentName == lastName) {
            rejectCallback && rejectCallback();
        } else {
            if (curentName.length == 0) {
                span.innerHTML = lastName;
                rejectCallback && rejectCallback();
            } else {
                var res = resolveCallback && resolveCallback(curentName);
                if (res === false) {
                    span.innerHTML = lastName;
                } else if (res && res.then) {
                    res.then(function (result) {
                        if (result === false) {
                            span.innerHTML = lastName;
                            //faile
                        } else {
                            //success
                        }
                    }, function () {
                        //reject value
                        span.innerHTML = lastName;

                    })
                } else {
                    //success
                }
            }
        }
    }

    function finish() {
        span.off('keydown', keydowEventHandle);
        span.off('blur', blurEventHandle);
        $(document.body).once('click', function () {
            setTimeout(function () {
                span.attr('contenteditable', undefined);
            }, 2);
        });

    }

    span.on('keydown', keydowEventHandle);
    span.on('blur', blurEventHandle);
};

ExpNode.prototype.findNodeBefore = function () {
    var tree = this.parentElement;
    var root;
    var prevTree;
    var res = null;
    if (tree.__isExpTree__) {
        root = tree.getRoot();
        root.visitRecursive(function (cTree) {
            if (cTree === tree) {
                res = prevTree;
            }
            prevTree = cTree;
        })
    }
    return res && res.getNode();
};

ExpNode.prototype.findNodeAfter = function () {
    var tree = this.parentElement;
    var root;
    var prevTree;
    var res = null;
    if (tree.__isExpTree__) {
        root = tree.getRoot();
        root.visitRecursive(function (cTree) {
            if (prevTree === tree) {
                res = cTree;
            }
            prevTree = cTree;
        })
    }
    return res && res.getNode();
};

ExpNode.eventHandler = {};

/****
 *
 * @param {KeyboardEvent} event
 */
ExpNode.eventHandler.buttonKeydown = function (event) {
    if (event.target === this) {
        if (!event.metaKey && !event.shiftKey && !event.ctrlKey && !event.altKey) {
            var destNode;
            var tree = this.parentElement;
            var parentTree = tree && tree.getParent();
            switch (event.key) {
                case 'ArrowLeft':
                    if (tree.status === 'open') {
                        tree.status = 'close';
                        tree.notifyStatusChange();
                    } else {
                        destNode = parentTree && parentTree.getNode();
                    }
                    break;
                case 'ArrowRight':
                    if (tree.status === 'close') {
                        tree.status = 'open';
                        tree.notifyStatusChange();
                    } else {
                        destNode = this.findNodeAfter();
                    }
                    break;
                case 'ArrowUp':
                    destNode = this.findNodeBefore();
                    break;
                case 'ArrowDown':
                    destNode = this.findNodeAfter();
                    break;
                case 'Space':
                    this.click();
                    break;
            }
            if (destNode) {
                destNode.focus();
                event.preventDefault();
            }
        }
    }
};

/***
 * @extends AElement
 * @constructor
 */
function ExpTree() {
    var thisET = this;
    this.$node = $('expnode', this)
        .on('press', function (event) {
            thisET.emit('press', Object.assign({}, {
                target: thisET,
                node: this,
                type: 'press'
            }, event), this);
        })
        .on('pressremove', function (event) {
            thisET.emit('pressremove', Object.assign({}, {
                target: thisET,
                node: this,
                type: 'pressremove'
            }, event), this);
        })
        .on('presstoggle', this.eventHandler.nodePressToggle);

    this.$itemsContainer = $('.absol-exp-items', thisET);
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].drillProperty(this, this.$node, ['desc', 'name', 'title', 'extSrc', 'active', 'icon']);
    this.__isExpTree__ = true;
    this._level = 0;
}


ExpTree.tag = 'ExpTree'.toLowerCase();

ExpTree.render = function () {
    return _({
        class: 'absol-exp-tree',
        extendEvent: ['press', 'pressremove', 'statuschange'],
        child: [
            'expnode',
            '.absol-exp-items'
        ]
    });
};

ExpTree.property = {};

ExpTree.property.level = {
    set: function (value) {
        value = value || 0;
        if (value != this.level) {
            this.$node.level = value;
            Array.prototype.forEach.call(this.$itemsContainer.childNodes, function (e) {
                e.level = value + 1;
            })
        }

    },
    get: function () {
        return this.$node.level;
    }
};


ExpTree.property.status = {
    set: function (value) {
        this.$node.status = value;
        if (value != 'open') {
            this.addClass('hide-children');
        } else {
            this.removeClass('hide-children');
        }
    },
    get: function () {
        return this.$node.status;
    }
};


['findChildBefore', 'findChildAfter', 'removeChild', 'clearChild']
    .forEach(function (key) {
        ExpTree.prototype[key] = function () {
            this.$itemsContainer[key].apply(this.$itemsContainer, arguments);
        }
    });

ExpTree.prototype.addChild = function (child) {
    if (!child.__isExpTree__) throw new Error('Child node must be a ExpTree');
    child.level = this.level + 1;
    this.$itemsContainer.addChild(child);
};

ExpTree.prototype.addChildBefore = function (child, at) {
    child.level = this.level + 1;
    this.$itemsContainer.addChildBefore(child, at);
};

ExpTree.prototype.addChildAfter = function (child, at) {
    child.level = this.level + 1;
    this.$itemsContainer.addChildAfter(child, at);
};

/****
 *
 * @return {ExpTree}
 */
ExpTree.prototype.getParent = function () {
    var current = this.parentNode;
    while (current) {
        if (current.__isExpTree__)
            break;
        current = current.parentNode;
    }
    return current;
};

/***
 *
 * @return {ExpTree}
 */
ExpTree.prototype.getRoot = function () {
    var parent = this.getParent();
    if (!parent) return this;
    return parent.getRoot();
}


ExpTree.prototype.getNode = function () {
    return this.$node;
};

ExpTree.prototype.getChildren = function () {
    return Array.apply(null, this.$itemsContainer.childNodes);
};

/***
 *
 * @param {function(tree: ExpTree): void} cb
 */
ExpTree.prototype.visitRecursive = function (cb) {
    cb(this);
    if (this.status === 'open')
        Array.prototype.forEach.call(this.$itemsContainer.childNodes, function (child) {
            child.visitRecursive(cb);
        });
};

ExpTree.prototype.getPath = function () {
    var path = [];
    var current = this;
    while (current) {
        path.push(current.name);
        current = current.getParent();
    }
    return path.reverse();
};

ExpTree.prototype.accessByPath = function (path) {
    if (path.length == 0) return this;
    var childs = this.getChildren();

    var res;
    for (var i = 0; i < childs.length; ++i) {
        if (childs[i].name == path[0]) {
            res = childs[i].accessByPath(path.slice(1));
            break;
        }
    }
    return res;
};

ExpTree.prototype.toggle = function () {
    switch (this.status) {
        case 'close':
            this.status = 'open';
            break;
        case 'open':
            this.status = 'close';
            break;
    }
};


ExpTree.prototype.notifyStatusChange = function (props) {
    this.emit('statuschange', Object.assign({type: 'statuschange', target: this}, props), this);
};

ExpTree.eventHandler = {};

ExpTree.eventHandler.nodePressToggle = function (event) {
    this.toggle();
    this.notifyStatusChange({originEvent: event});
};

/***
 * @extends ExpTree
 * @constructor
 */
function ExpGroup() {
    this.addClass('as-exp-group');
    this.__isExpTree__ = true;
}


ExpGroup.tag = 'ExpGroup'.toLowerCase();

ExpGroup.render = function () {
    return _('div');
};

/***
 *
 * @param {function(tree: ExpTree): void} cb
 */
ExpGroup.prototype.visitRecursive = function (cb) {
    Array.prototype.forEach.call(this.childNodes, function (child) {
        child.visitRecursive(cb);
    });
};

ExpGroup.prototype.getParent = function () {
    return null;
};

ExpGroup.prototype.getRoot = function () {
    return this;
};

ExpGroup.prototype.getNode = function () {
    return null;
};

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(ExpNode);
_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(ExpTree);
_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(ExpGroup);


/* harmony default export */ __webpack_exports__["c"] = (ExpTree);

/***/ }),
/* 23 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1);
/* harmony import */ var _css_cpuviewer_css__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(292);
/* harmony import */ var _css_cpuviewer_css__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_css_cpuviewer_css__WEBPACK_IMPORTED_MODULE_2__);





/***
 * @extends AElement
 * @constructor
 */
function CPUViewer() {
    /***
     *
     * @type {HTMLCanvasElement}
     */
    this.$canvas = Object(_ACore__WEBPACK_IMPORTED_MODULE_0__[/* $ */ "a"])('canvas', this);
    this.ctx = this.$canvas.getContext('2d');
    this.offsetTime = 0;
    this.inv = -1;
    this.usage = Array(120).fill(0);
    this.holdStart = 0;
    this.holdTime = 0;
    this.logOffset = 0;
    this.counter = 0;

    this['tick'] = this.tick.bind(this);
}

CPUViewer.tag = 'CPUViewer'.toLowerCase();

CPUViewer.render = function () {
    return Object(_ACore__WEBPACK_IMPORTED_MODULE_0__[/* _ */ "c"])({
        class: 'as-cpu-viewer',
        child: {
            tag: 'canvas',
            attr: {
                width: '120px',
                height: '50px'
            }
        }
    });
};

CPUViewer.prototype.start = function () {
    if (this.inv < 0) {
        this.offsetTime = new Date().getTime();
        setInterval(this.tick, 250)
    }
};

CPUViewer.prototype.stop = function () {
    if (this.inv > 0) {
        clearInterval(this.inv);
        this.inv = -1;
    }
};

CPUViewer.prototype.tick = function () {


    while (this.holdTime > 250) {
        this.holdTime -= 250;
        this.usage.push(100);
    }
    this.usage.push(this.holdTime * 100 / 250);
    while (this.usage.length > 120) {
        this.usage.shift();
    }
    this.ctx.fillStyle = 'black';
    this.ctx.fillRect(0, 0, 120, 50);
    var y;
    this.ctx.fillStyle = 'yellow';
    for (var x = 0; x < this.usage.length; ++x) {
        y = this.usage[x] / 2;
        this.ctx.fillRect(x, 50 - y, 1, y);
    }
    var now = new Date().getTime();
    this.logOffset = now;
    this.holdStart = now;
    this.holdTime = 0;

};

CPUViewer.prototype.hold = function () {
    if (this.counter === 0) {
        this.holdStart = new Date().getTime();
    }
    this.counter++;
};

CPUViewer.prototype.release = function () {
    if (this.counter <= 0) return;
    this.counter--;
    if (this.counter === 0) {
        this.holdTime += new Date().getTime() - this.holdStart;
    }
};


/***
 *
 * @type {CPUViewer}
 */
CPUViewer.instance = null;
CPUViewer.state = 'NOT_INIT';
CPUViewer.start = function () {
    if (!this.instance) {
        this.instance = Object(_ACore__WEBPACK_IMPORTED_MODULE_0__[/* _ */ "c"])('cpuviewer');
        this.state = "NOT_ATTACHED";
    }
    if (this.state === "NOT_ATTACHED") {
        this.state = "RUNNING";
        absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_1__[/* default */ "b"].documentReady.then(function () {
            document.body.appendChild(this.instance);
            console.log(this.instance)
        }.bind(this));
    }
    this.instance.start();

    CPUViewer.hold = function () {
        this.instance.hold();
    };

    CPUViewer.release = function () {
        this.instance.release();
    };
};

CPUViewer.stop = function () {
    if (!this.instance) return;
    if (this.state !== "RUNNING") return;
    this.instance.stop();
    this.instance.remove();
    this.state = 'NOT_ATTACHED';


};


CPUViewer.hold = function () {

};

CPUViewer.release = function () {

};

_ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].install(CPUViewer);

/* harmony default export */ __webpack_exports__["a"] = (CPUViewer);

/***/ }),
/* 24 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _AElement__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(8);

/* harmony default export */ __webpack_exports__["a"] = (_AElement__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"]);

/***/ }),
/* 25 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_follower_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(142);
/* harmony import */ var _css_follower_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_follower_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1);
/* harmony import */ var absol_src_Math_Rectangle__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(18);
/* harmony import */ var absol_src_HTML5_AElement__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(8);







var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;


/***
 * @extends AElement
 * @constructor
 */
function Follower() {
    this.$attachhook = _('attachhook', this)
        .addTo(this)
        .on('attached', function () {
            this.requestUpdateSize();
            absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__[/* default */ "b"].addToResizeSystem(this);
        });
    this.$attachhook.requestUpdateSize = this.updatePosition.bind(this);

    this.$followTarget = undefined;
    this.$scrollTrackElts = [];
    this._scrollTrackEventHandler = undefined;
    this._anchor = Follower.ANCHOR_PRIORITY;
    this.defineEvent(['updateposition', 'preupdateposition']);
    /***
     * @name followTarget
     * @type {AElement}
     * @memberOf Follower#
     */
}

Follower.tag = 'Follower'.toLowerCase();
Follower.render = function () {
    return _('.absol-follower');
};


Follower.prototype.clearChild = function () {
    var children = Array.prototype.slice.call(this.children);
    var attachhookElt = this.$attachhook;
    children.forEach(function (elt) {
        if (elt != attachhookElt)
            elt.remove();
    });
}

//Todo: remove child, find child....

/**
 * X = $target.x + F[anchor_index][0] * $target.width + F[anchor_index][1] * $content.width
 * Y = $target.y + F[anchor_index][2] * $target.height + F[anchor_index][3] * $content.height
 */
Follower.ANCHOR_FACTORS = [
    [1, 0, 0, 0],//0
    [0, 0, 1, 0],//1
    [1, -1, 1, 0],//2
    [0, -1, 0, 0],//3
    [0, -1, 1, -1],//4
    [1, -1, 0, -1],//5
    [0, 0, 0, -1],//6
    [1, 0, 1, -1],//7

    [1, 0, 0.5, -0.5],//8
    [0.5, -0.5, 1, 0],//9
    [0, -1, 0.5, -0.5],//10
    [0.5, -0.5, 0, -1],//11

    [1, 0, 1, 0],//12
    [0, -1, 1, 0],//13
    [0, -1, 0, -1],//14
    [1, 0, 0, -1],//15
];

Follower.ANCHOR_PRIORITY = [1, 6, 2, 5, 0, 7, 3, 4, 9, 11, 8, 10, 12, 15, 13, 14];


Follower.prototype.updatePosition = function () {
    if (!this.$followTarget) return;
    this.emit('preupdateposition', { target: this }, this);
    var targetBound = this.$followTarget.getBoundingClientRect();
    var screenSize = absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__[/* default */ "b"].getScreenSize();
    var outRect = new absol_src_Math_Rectangle__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"](0, 0, screenSize.width, screenSize.height);
    var bound = this.getBoundingClientRect();
    var x = 0;
    var y = 0;
    var score;
    var anchors = this._lastAnchor === undefined ? this.anchor : [this._lastAnchor].concat(this.anchor);
    var factor;
    var bestX, bestY, bestScore = -100000;
    var newContentRect;
    var bestAnchor;
    for (var i = 0; i < anchors.length; ++i) {
        factor = Follower.ANCHOR_FACTORS[anchors[i]];
        x = targetBound.left + factor[0] * targetBound.width + factor[1] * bound.width;
        y = targetBound.top + factor[2] * targetBound.height + factor[3] * bound.height;
        newContentRect = new absol_src_Math_Rectangle__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"](x, y, bound.width, bound.height);
        score = newContentRect.collapsedSquare(outRect);
        if (score - 10 > bestScore) {
            bestAnchor = anchors[i];
            bestScore = score;
            bestX = x;
            bestY = y;
        }
    }

    if (this._lastAnchor !==bestAnchor){
        this.removeClass('as-anchor-'+ this._lastAnchor);
        this._lastAnchor = bestAnchor;
        this.addClass('as-anchor-'+ this._lastAnchor);
    }



    this.addStyle({
        left: bestX + 'px',
        top: bestY + 'px'
    });
    this.emit('updateposition', { target: this }, this);
};


Follower.prototype.refollow = function () {
    if (!this.$followTarget) return;
    this.updatePosition();
    this.addClass('following');

    if (this._scrollTrackEventHandler) this.unfollow();
    this._scrollTrackEventHandler = this.updatePosition.bind(this);
    this.$scrollTrackElts = [];

    var trackElt = this.$followTarget;
    while (trackElt) {
        if (trackElt.addEventListener)
            trackElt.addEventListener('scroll', this._scrollTrackEventHandler, false);
        else
            trackElt.attachEvent('onscroll', this._scrollTrackEventHandler, false);

        this.$scrollTrackElts.push(trackElt);
        trackElt = trackElt.parentElement;
    }
    if (document.addEventListener) {
        document.addEventListener('scroll', this._scrollTrackEventHandler, false);
    }
    else {
        document.attachEvent('onscroll', this._scrollTrackEventHandler, false);
    }
    this.$scrollTrackElts.push(document);
};

Follower.prototype.unfollow = function () {
    if (!this._scrollTrackEventHandler) return;// nothing to do
    this.removeClass('following');
    var trackElt;

    for (var i = 0; i < this.$scrollTrackElts.length; ++i) {
        trackElt = this.$scrollTrackElts[i];
        if (trackElt.removeEventListener)
            trackElt.removeEventListener('scroll', this._scrollTrackEventHandler, false);
        else
            trackElt.dettachEvent('onscroll', this._scrollTrackEventHandler, false);
    }
    this.$scrollTrackElts = [];
    this._scrollTrackEventHandler = undefined;
};


Follower.property = {};

Follower.property.followTarget = {
    set: function (elt) {
        if (elt === null || elt === undefined || !elt) {
            this.unfollow();
            this.$followTarget = undefined;
            return;
        }
        else if (typeof elt == 'string') {
            elt = $(elt) || document.getElementById(elt);
        }

        if (absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__[/* default */ "b"].isDomNode(elt)) {
            this.$followTarget = elt;
            this._lastAncho = undefined;
            this.refollow();
        }
        else throw new Error("Invalid element");
    },
    get: function () {
        return this.$followTarget;
    }
}

Follower.property.anchor = {
    set: function (value) {
        value = value || Follower.ANCHOR_PRIORITY;
        if (value == 'auto') value = Follower.ANCHOR_PRIORITY;
        if (typeof value == null) value = [value];
        if (!(value instanceof Array)) throw new Error('Invalid anchor ' + value);
        value = value.map(function (x) {
            x = Math.floor(x);
            if (x >= 0 && x < Follower.ANCHOR_FACTORS.length) {
                return x;
            }
            else throw new Error("Invalid anchor: " + x);
        });
        this._anchor = value;
        this._lastAnchor = undefined;

        this.updatePosition();
    },
    get: function () {
        return this._anchor;
    }
}


_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(Follower);

/* harmony default export */ __webpack_exports__["a"] = (Follower);

/***/ }),
/* 26 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
function TemplateString(props) {
    this.parts = props.parts;
}




TemplateString.prototype.toJSCode = function () {
    return this.parts.map(function (e) {
        if (e.type == TemplateString.TYPE_EXPRESSION) {
            return '(' + e.data + ')';
        }
        else {
            return JSON.stringify(e.data);
        }
    }).join('+');
};


TemplateString.__partRegex = /(\{\{(([^\}]|(\}[^\}]))*)\}\})|(([^\{]|(\{[^\{]))+)/g;

/**
 *  @param  {String} text 
 */
TemplateString.__matchExpression = function (text) {
    if (text[0] == '{' && text[1] == '{' && text[text.length - 1] == '}' && text[text.length - 2] == '}') {
        return [text, text.substr(2, text.length - 4).trim()];
    }
    else {
        return false;
    }
};

TemplateString.TYPE_STRING = 0;
TemplateString.TYPE_EXPRESSION = 1;


TemplateString.parse = function (text) {
    text = text+'';
    var matchedParts = text.match(this.__partRegex);
    if (matchedParts) {
        var parts = matchedParts.map(function (e) {
            var matchedExp = this.__matchExpression(e);
            if (matchedExp) {
                return {
                    type: this.TYPE_EXPRESSION,
                    data: matchedExp[1]
                };
            }
            else {
                return {
                    type: this.TYPE_STRING,
                    data: e
                };
            }
        }.bind(this));
        return new TemplateString({ parts: parts });
    }
    else {
        return new TemplateString({ parts: [] });
    }
};

/* harmony default export */ __webpack_exports__["a"] = (TemplateString);

/***/ }),
/* 27 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1);
/* harmony import */ var absol_src_Math_Rectangle__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(18);
/* harmony import */ var absol_src_Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(10);
/* harmony import */ var _Menu__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(40);
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(4);
/* harmony import */ var _Follower__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(25);








var isMobile = absol_src_Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].isMobile;
var _ = _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].$;

function QuickMenu() {
    //like context menu without right-click
    this._contextMenuSync = Promise.resolve();
}

QuickMenu.tag = 'QuickMenu'.toLowerCase();

QuickMenu.render = function () {
    return _({
        tag: 'vmenu',
        extendEvent: 'requestcontextmenu',
        class: [
            'as-quick-menu', 'as-bscroller'
        ],
        style: {
            'overflow-y': 'auto',
            'box-sizing': 'border-box'
        }
    });
};


_ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].install(QuickMenu);
QuickMenu.PRIORITY_ANCHORS = [0, 3, 7, 4, 1, 2, 6, 5];

QuickMenu.$elt = _('quickmenu');
/***
 *
 * @type {Follower}
 */
QuickMenu.$follower = _({
    tag: _Follower__WEBPACK_IMPORTED_MODULE_6__[/* default */ "a"].tag,
    class: 'absol-context-menu-anchor',
    child: QuickMenu.$elt,
    on: {
        preupdateposition: function () {
            var bound = this.getBoundingClientRect();
            var outBound = Object(absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_1__[/* traceOutBoundingClientRect */ "f"])(this);
            if (bound.bottom < outBound.top || bound.top > outBound.bottom || bound.right < outBound.left || bound.left > outBound.right) {
                QuickMenu.close(QuickMenu._session);
            }

        }
    }
});


QuickMenu._session = Math.random() * 10000000000 >> 0;
QuickMenu._menuListener = undefined;

QuickMenu.$elt.on('press', function (event) {
    if (QuickMenu._menuListener) QuickMenu._menuListener(Object(_utils__WEBPACK_IMPORTED_MODULE_5__["cleanMenuItemProperty"])(event.menuItem));
});


QuickMenu.show = function (element, menuProps, anchor, menuListener, darkTheme) {
    var menuElt = QuickMenu.$elt;
    var followerElt = QuickMenu.$follower;
    var menuAnchors = [];

    if (typeof anchor == 'number') {
        menuAnchors = [anchor];
    }
    else if (anchor instanceof Array) {
        menuAnchors = anchor;
    }
    else if (anchor === 'modal') {
        menuAnchors = [];
    }
    else {
        menuAnchors = QuickMenu.PRIORITY_ANCHORS;
    }

    if (anchor === 'modal') {
        followerElt.addClass('as-anchor-modal');
    }
    else {
        followerElt.removeClass('as-anchor-modal');
    }


    QuickMenu._session = Math.random() * 10000000000 >> 0;
    followerElt.addTo(document.body);
    Object.assign(menuElt, menuProps);
    followerElt.anchor = menuAnchors;
    followerElt.followTarget = element;
    QuickMenu.$element = element;
    QuickMenu.$element.classList.add('as-quick-menu-attached');
    QuickMenu._menuListener = menuListener;


    if (darkTheme) followerElt.addClass('dark');
    else followerElt.removeClass('dark');
    menuElt.addStyle('visibility', 'hidden');//for prevent size change blink
    followerElt.addClass('absol-active');

    setTimeout(function () {
        followerElt.updatePosition();
        menuElt.addStyle('visibility', 'visible');
    }, isMobile ? 33 : 2);


    return QuickMenu._session;
};

QuickMenu.close = function (session) {
    if (session !== true && session !== QuickMenu._session) return;
    QuickMenu._session = Math.random() * 10000000000 >> 0;
    if (QuickMenu.$element)
        QuickMenu.$element.classList.remove('as-quick-menu-attached');
    QuickMenu.$element = undefined;
    QuickMenu._menuListener = undefined;

    QuickMenu.$follower.removeClass('absol-active');
    QuickMenu.$follower.remove();
};


QuickMenu.showWhenClick = function (element, menuProps, anchor, menuListener, darkTheme) {
    var res = {
        menuProps: menuProps,
        anchor: anchor,
        currentSession: undefined,
        element: element,
        menuListener: menuListener,
        darkTheme: darkTheme
    };

    var clickHandler = function () {
        if (QuickMenu._session === res.currentSession) return;
        res.currentSession = QuickMenu.show(res.element, res.menuProps, res.anchor, res.menuListener, res.darkTheme);
        var finish = function () {
            document.removeEventListener('click', finish, false);
            QuickMenu.close(res.currentSession);
            res.currentSession = undefined;
        };

        setTimeout(function () {
            document.addEventListener('click', finish, false);
        }, 10)
    };

    res.remove = function () {
        element.removeEventListener('click', clickHandler, false);
        element.classList.remove('as-quick-menu-trigger');

    };

    element.addEventListener('click', clickHandler, false);
    element.classList.add('as-quick-menu-trigger');
    return res;
};


/**
 * @typedef {Object} QuickMenuAdaptor
 * @property {Function} getFlowedElement default is trigger
 * @property {Function} getMenuProps define menuProps if un-change
 * @property {Function} getAnchor default is 'auto', define anchor if un-change
 * @property {Function} onClose callback
 * @property {Function} onOpen callback
 * @property {Function} onSelect calback
 * @property {Function} isDarkTheme default is false, define darkThem if un-change
 *
 *
 * @typedef {Object} QuickMenuDataHolder
 * @property {Function} remove
 *
 * @param {Element} trigger
 * @param {QuickMenuAdaptor} adaptor
 * @returns {QuickMenuDataHolder}
 */
QuickMenu.toggleWhenClick = function (trigger, adaptor) {
    var res = {
        trigger: trigger,
        adaptor: adaptor,
        currentSession: undefined,
    };

    var clickHandler = function () {
        if (QuickMenu._session === res.currentSession) return;

        res.currentSession = QuickMenu.show(res.adaptor.getFlowedElement ? res.adaptor.getFlowedElement() : trigger,
            res.adaptor.getMenuProps ? res.adaptor.getMenuProps() : (adaptor.menuProps || []),
            res.adaptor.getAnchor ? res.adaptor.getAnchor() : (adaptor.anchor || 'auto'),
            res.adaptor.onSelect,
            res.adaptor.isDarkTheme ? res.adaptor.isDarkTheme() : !!res.adaptor.darkTheme);
        if (res.adaptor.onOpen) res.adaptor.onOpen();

        var finish = function () {
            document.body.removeEventListener('click', finish, false);
            QuickMenu.close(res.currentSession);
            if (adaptor.onClose) adaptor.onClose();
            res.currentSession = undefined;
        };

        setTimeout(function () {
            document.body.addEventListener('click', finish, false);
        }, 10);
    };

    res.remove = function () {
        trigger.removeEventListener('click', clickHandler, false);
        trigger.classList.remove('as-quick-menu-trigger');
    };

    trigger.addEventListener('click', clickHandler, false);
    trigger.classList.add('as-quick-menu-trigger');

    return res;

};


/* harmony default export */ __webpack_exports__["a"] = (QuickMenu);

/***/ }),
/* 28 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return updateTooltipPosition; });
/* harmony import */ var _css_tooltip_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(228);
/* harmony import */ var _css_tooltip_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_tooltip_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1);
/* harmony import */ var absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(3);





var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;

/***
 * @extends AElement
 * @constructor
 */
function ToolTip() {
    this.$content = $('.absol-tooltip-content', this);
    this.$arrow = $('.absol-tooltip-arrow', this);
}

ToolTip.tag = 'ToolTip'.toLowerCase();

ToolTip.render = function () {
    return _({
        class: 'absol-tooltip',
        child: [
            { class: 'absol-tooltip-content' },
            '.absol-tooltip-arrow'
        ]
    });
};

['addChild', 'addChildBefore', 'addChildAfter', 'clearChild'].forEach(function (key) {
    ToolTip.prototype[key] = function () {
        return this.$content[key].apply(this.$content, arguments);
    }
});

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(ToolTip);

function updateTooltipPosition(toolTipClass) {
    var element = toolTipClass.$element;
    if (!element) return;
    var orientation = toolTipClass._orientation;

    var tBound = toolTipClass.$tooltip.$content.getBoundingClientRect();
    var ebound = element.getBoundingClientRect();
    var screenSize = Object(absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__[/* getScreenSize */ "d"])();
    var sMargin = Math.round(Math.min(5, screenSize.width/100, screenSize.height));
    screenSize.width = Math.min(screenSize.width, document.body.getBoundingClientRect().width);
    var fontSize = toolTipClass.$tooltip.getFontSize();

    var dx = 0;
    var dy = 0;
    var arrowPos = null;

    var aHCenter = (ebound.left + ebound.width / 2 > tBound.width / 2)
        && (screenSize.width - ebound.left - ebound.width / 2 > tBound.width / 2);
    var aVCenter = (ebound.top + ebound.height / 2 > tBound.height / 2)
        && (screenSize.height - ebound.top - ebound.height / 2 > tBound.height / 2);
    var aTop = (tBound.height < ebound.top - sMargin);
    var aBottom = tBound.height < screenSize.height - sMargin - ebound.bottom;
    var aRight = tBound.width < screenSize.width - sMargin - ebound.right;
    var aLeft = tBound.width < ebound.left - sMargin;

    var aHLeft = (ebound.left + ebound.width / 2 - tBound.width / 2 < sMargin) && (ebound.left + ebound.width / 2 >= sMargin + fontSize / 2);
    var aHRight = (ebound.left + ebound.width / 2 + tBound.width / 2 > screenSize.width - sMargin) && (ebound.left + ebound.width / 2 < screenSize.width - sMargin - fontSize / 2);
    var aVTop = (ebound.top + ebound.width / 2 - tBound.height / 2 < sMargin) && (ebound.top + ebound.height / 2 >= sMargin + fontSize / 2);
    var aVBottom = (ebound.top + ebound.width / 2 + tBound.height / 2 <= screenSize.height - sMargin) && (ebound.top + ebound.height / 2 > screenSize.height - sMargin - fontSize / 2);

    if (orientation === 'auto' && aHCenter) {
        if (aTop) {
            orientation = 'top';
        }
        else if (aBottom) {
            orientation = 'bottom';
        }
    }
    if (orientation === 'auto' && aVCenter) {
        if (aRight) {
            orientation = 'right';
        }
        else if (aLeft) {
            orientation = 'left';
        }
    }


    if ((orientation === 'auto' || orientation === 'top' || orientation === 'bottom') && aHLeft) {
        if (aTop || orientation === 'auto') orientation = "top";
        else if (aBottom || orientation === 'auto') orientation = 'bottom';
        if (aTop || aBottom) {
            dx += tBound.width / 2 - (ebound.left + ebound.width / 2) + sMargin;
            arrowPos = tBound.width / 2 - dx + 'px';
        }
    }
    if ((orientation === 'auto' || orientation === 'top' || orientation === 'bottom') && aHRight) {
        if (aTop || orientation === 'auto') orientation = "top";
        else if (aBottom || orientation === 'auto') orientation = 'bottom';
        if (aTop || aBottom) {
            dx -= tBound.width / 2 - (screenSize.width - (ebound.left + ebound.width / 2)) + sMargin;
            arrowPos = tBound.width / 2 - dx + 'px';
        }
    }


    if ((orientation === 'auto'|| orientation === 'left' || orientation === 'right') && aVTop) {
        if (aLeft || orientation === 'auto') orientation = "left";
        else if (aRight || orientation === 'auto') {
            orientation = 'right';
        }
        if (aLeft || aRight) {
            dy += tBound.height / 2 - (ebound.top + ebound.height / 2) + sMargin;
            arrowPos = tBound.height / 2 - dy + 'px';
        }
    }
    if ((orientation === 'auto'|| orientation === 'left' || orientation === 'right') && aVBottom) {
        if (aLeft || orientation === 'auto') orientation = "left";
        else if (aRight || orientation === 'auto') {
            orientation = 'right';
        }
        if (aLeft || aRight) {
            dy -= tBound.height / 2 - (screenSize.height - (ebound.top + ebound.height / 2)) + sMargin;
            arrowPos = tBound.height / 2 - dx + 'px'
        }
    }

    if (orientation === 'auto') {
        if (aRight) {
            if (aTop) {
                orientation = 'ne';
            }
            else if (aBottom) {
                orientation = 'se';
            }
        }
        else if (aLeft) {
            if (aTop) {
                orientation = 'nw';
            }
            else if (aBottom) {
                orientation = 'sw';
            }
        }
    }
    if (orientation === 'auto') orientation = "error";
    toolTipClass.$tooltip.removeClass('top')
        .removeClass('left')
        .removeClass('right')
        .removeClass('bottom')
        .removeClass('ne')
        .removeClass('nw')
        .removeClass('se')
        .removeClass('sw')
        .addClass(orientation);


    tBound = toolTipClass.$tooltip.getBoundingClientRect();

    if (orientation == 'top') {
        dy += ebound.top - tBound.height;
        dx += ebound.left + ebound.width / 2 - tBound.width / 2;
    }
    else if (orientation == 'left') {
        dy += ebound.top + ebound.height / 2 - tBound.height / 2;
        dx += ebound.left - tBound.width;
    }
    else if (orientation == 'right') {
        dy += ebound.top + ebound.height / 2 - tBound.height / 2;
        dx += ebound.right;
    }
    else if (orientation == 'bottom') {
        dy += ebound.bottom;
        dx += ebound.left + ebound.width / 2 - tBound.width / 2;

    }
    else if (orientation === 'ne') {
        dy += ebound.top - tBound.height;
        dx += ebound.right;
    }
    else if (orientation === 'nw') {
        dy += ebound.top - tBound.height;
        dx += ebound.left - tBound.width;
    }
    else if (orientation === 'se') {
        dy += ebound.bottom;
        dx += ebound.right;
    }
    else if (orientation === 'sw') {
        dy += ebound.bottom;
        dx += ebound.left - tBound.width;
    }
    else {
        throw new Error("Invalid orientation, orientation: ['left', 'right', 'top', 'bottom', 'auto', 'nw', 'ne', 'sw', 'se']");
    }

    if (arrowPos) {
        toolTipClass.$tooltip.addStyle('--tool-tip-arrow-pos', arrowPos);
    }
    else {
        toolTipClass.$tooltip.removeStyle('--tool-tip-arrow-pos')
    }

    toolTipClass.$holder.addStyle({
        top: dy + 'px',
        left: dx + 'px'
    });
}


ToolTip.$holder = _('.absol-tooltip-root-holder')
ToolTip.$tooltip = _('tooltip.top').addTo(ToolTip.$holder);
ToolTip.$element = undefined;
ToolTip.$content = undefined;
ToolTip._orientation = 'top';
ToolTip._session = Math.random() * 10000000000 >> 0;

ToolTip.updatePosition = function () {
    if (!ToolTip.$element) return;
    updateTooltipPosition(ToolTip);
};

ToolTip.$tooltip.$arrow.updateSize = ToolTip.updatePosition.bind(ToolTip);


ToolTip.show = function (element, content, orientation) {
    orientation = orientation || 'auto';
    if (typeof content == 'string') {
        content = _({
            tag: 'span',
            style: {
                'white-space': 'nowrap'
            },
            props: {
                innerHTML: content
            }
        });
    }


    $('', content, function (elt) {
        if (elt.tagName == "IMG" && elt.src) {
            absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__[/* default */ "b"].waitImageLoaded(elt).then(ToolTip.updatePosition.bind(ToolTip));
        }
        else if (elt.sync) {
            elt.sync.then(ToolTip.updatePosition.bind(ToolTip));
        }
    });
    var currentSession = Math.random() * 10000000000 >> 0;

    ToolTip.$holder.addTo(document.body);
    absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__[/* default */ "b"].addToResizeSystem(ToolTip.$tooltip.$arrow);

    ToolTip.$element = element;
    ToolTip._session = currentSession;
    ToolTip.$content = content;
    ToolTip._orientation = orientation;

    ToolTip.$tooltip.clearChild().addChild(content);
    ToolTip.$holder.removeStyle('visibility');
    ToolTip.$tooltip.removeClass('top')
        .removeClass('left')
        .removeClass('right')
        .removeClass('bottom')
        .removeClass('ne')
        .removeClass('nw')
        .removeClass('auto');
    ToolTip.$tooltip.addClass(orientation);
    ToolTip.updatePosition();
    return currentSession;
};


ToolTip.close = function (session) {
    if (session === true || session === this._session) {
        ToolTip.$holder.addStyle('visibility', 'hidden');
        ToolTip.$tooltip.clearChild();
        ToolTip.$holder.addStyle({
            top: false,
            left: false
        });
    }
};

ToolTip.closeTooltip = ToolTip.close;


ToolTip.showWhenClick = function (element, content, orientation) {
    var mSession = undefined;
    element.addEventListener('click', function () {
        if (mSession !== undefined) return;
        mSession = ToolTip.show(element, content, orientation);
        var finish = function (event) {
            if (!absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_3__[/* default */ "b"].hitElement(content, event)) {
                $(document.body).off('click', finish);
                ToolTip.closeTooltip(mSession);
                mSession = undefined;
            }
        };

        setTimeout(function () {
            $(document.body).on('click', finish);
        }, 100)
    });
};


/* harmony default export */ __webpack_exports__["a"] = (ToolTip);

/***/ }),
/* 29 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_hanger_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(120);
/* harmony import */ var _css_hanger_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_hanger_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(9);
/* harmony import */ var absol_src_Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(10);
/* harmony import */ var absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(3);
/* harmony import */ var absol_src_HTML5_AElement__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(8);







var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;

/****
 * @extends AElement
 * @constructor
 */
function Hanger() {
    this.addClass('as-hanger');
    this.defineEvent(['predrag', 'dragstart', 'drag', 'dragend']);
    this._hangOn = 0;
    this._hangerPointerData = null;
    this.on2({
        mousedown: this.eventHandler.hangerPointerDown,
        touchstart: this.eventHandler.hangerPointerDown,
    });

    this._touchEvents = {
        touchend: this.eventHandler.hangerPointerFinish,
        touchcancel: this.eventHandler.hangerPointerFinish,
        touchmove: this.eventHandler.hangerPointerMove
    }
    this._mouseEvents = {
        mouseup: this.eventHandler.hangerPointerFinish,
        mouseleave: this.eventHandler.hangerPointerFinish,
        mousemove: this.eventHandler.hangerPointerMove
    };
}

Hanger.tag = 'hanger';

Hanger.render = function () {
    return _('div');
};

Hanger.prototype.on2 = function () {
    if (arguments.length == 1) {
        for (var name in arguments[0]) {
            Hanger.prototype.on2.call(this, name, arguments[0][name]);
        }
    }
    else if (arguments.length == 2) {
        this.addEventListener(arguments[0], arguments[1], absol_src_Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].supportPassiveEvent ? { passive: false } : true);
    }
};


Hanger.prototype.off2 = function () {
    if (arguments.length == 1) {
        for (var name in arguments[0]) {
            Hanger.prototype.off2.call(this, name, arguments[0][name]);
        }
    }
    else if (arguments.length == 2) {
        this.removeEventListener(arguments[0], arguments[1], absol_src_Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].supportPassiveEvent ? { passive: false } : true);
    }
};


Hanger.property = {};

/**
 * @type {Hanger}
 */
Hanger.property.hangOn = {
    set: function (value) {
        if (!(value > 0)) value = 0;
        this._hangOn = value;
    },
    get: function () {
        return this._hangOn;
    }
};

/**
 * @type {Hanger}
 */
Hanger.eventHandler = {};

Hanger.eventHandler.hangerPointerDown = function (event) {
    if (this._hangerPointerData) return;
    var bound = this.getBoundingClientRect();
    var startingPoint;
    var isTouch = event.type === 'touchstart';
    var pointerIdent = -1;
    var target;
    if (isTouch) {
        var touch = event.changedTouches[0];
        target = touch.target;
        pointerIdent = touch.identifier;
        startingPoint = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"](touch.clientX, touch.clientY);
    }
    else {
        startingPoint = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"](event.clientX, event.clientY);
        target = event.target;
    }
    var offsetVec = startingPoint.sub(new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"](bound.left, bound.top));

    this._hangerPointerData = {
        state: 0,
        isTouch: isTouch,
        bound: bound,
        startingPoint: startingPoint,
        offsetVec: offsetVec,
        pointerIdent: pointerIdent,
        target: target
    };
    var preDragEvent = {
        type: 'predrag',
        originEvent: event,
        isTouch: isTouch,
        bound: bound,
        startingPoint: startingPoint,
        currentPoint: startingPoint,
        offsetVec: offsetVec,
        pointerIdent: pointerIdent,
        canceled: false,
        cancel: function () {
            this.canceled = true;
        },
        clientX: startingPoint.x,
        clientY: startingPoint.y,
        target: target,
        preventDefault: function () {
            event.preventDefault();
        }
    };
    this.emit('predrag', preDragEvent, this);
    if (preDragEvent.canceled) {
        this._hangerPointerData = null;
        return;
    }
    ;
    if (isTouch)
        this.on2.call(document.body, this._touchEvents)
    else
        this.on2.call(document.body, this._mouseEvents);

};

Hanger.eventHandler.hangerPointerMove = function (event) {
    var pointerData = this._hangerPointerData;
    var isTouch = pointerData.isTouch;
    var pointerIdent = -2;
    var currentPoint;
    if (isTouch) {
        var touch = Object(absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__[/* findChangedTouchByIdent */ "c"])(event, pointerData.pointerIdent);
        if (touch) {
            pointerIdent = touch.identifier;
            currentPoint = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"](touch.clientX, touch.clientY);
        }
    }
    else {
        currentPoint = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"](event.clientX, event.clientY);
        pointerIdent = -1;
    }
    if (pointerIdent != pointerData.pointerIdent) return;
    pointerData.currentPoint = currentPoint;
    if (pointerData.state == 0) {
        var distance = currentPoint.sub(pointerData.startingPoint).abs();
        if (distance >= this._hangOn) {
            var dragStartEvent = {
                type: 'dragstart',
                originEvent: event,
                isTouch: isTouch,
                bound: pointerData.bound,
                startingPoint: pointerData.startingPoint,
                offsetVec: pointerData.offsetVec,
                pointerIdent: pointerIdent,
                currentPoint: currentPoint,
                target: pointerData.target,
                clientX: currentPoint.x,
                clientY: currentPoint.y,
                preventDefault: function () {
                    event.preventDefault();
                }
            };
            pointerData.state = 1;
            this.emit('dragstart', dragStartEvent, this);
        }
    }

    if (pointerData.state === 1) {
        var dragEvent = {
            type: 'drag',
            originEvent: event,
            isTouch: isTouch,
            bound: pointerData.bound,
            startingPoint: pointerData.startingPoint,
            offsetVec: pointerData.offsetVec,
            pointerIdent: pointerIdent,
            currentPoint: currentPoint,
            target: pointerData.target,
            clientX: currentPoint.x,
            clientY: currentPoint.y,
            preventDefault: function () {
                event.preventDefault();
            }
        };
        this.emit('drag', dragEvent, this);
    }
};

Hanger.eventHandler.hangerPointerFinish = function (event) {
    var pointerData = this._hangerPointerData;
    var isTouch = event.type === 'touchend';
    if (pointerData.isTouch !== isTouch) return;
    var pointerIdent = -2;
    var currentPoint;
    if (isTouch) {
        var touch = Object(absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__[/* findChangedTouchByIdent */ "c"])(event, pointerData.pointerIdent);
        if (touch) {
            pointerIdent = touch.identifier;
            currentPoint = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"](touch.clientX, touch.clientY);
        }
    }
    else {
        currentPoint = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"](event.clientX, event.clientY);
        pointerIdent = -1;
    }
    if (pointerIdent !== pointerData.pointerIdent) return;
    if (pointerData.state === 1) {
        var dragEndEvent = {
            type: 'dragend',
            originEvent: event,
            isTouch: isTouch,
            bound: pointerData.bound,
            startingPoint: pointerData.startingPoint,
            offsetVec: pointerData.offsetVec,
            pointerIdent: pointerIdent,
            currentPoint: currentPoint,
            target: pointerData.target,
            clientX: currentPoint.x,
            clientY: currentPoint.y,
            preventDefault: function () {
                event.preventDefault();
            }
        };
        this.emit('dragend', dragEndEvent, this);
    }

    this._hangerPointerData = null;
    if (isTouch)
        this.off2.call(document.body, this._touchEvents)
    else
        this.off2.call(document.body, this._mouseEvents);
};

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(Hanger);

/* harmony default export */ __webpack_exports__["a"] = (Hanger);


/***/ }),
/* 30 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getTextNodesIn", function() { return getTextNodesIn; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "setSelectionRangeStart", function() { return setSelectionRangeStart; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "setSelectionRangeEnd", function() { return setSelectionRangeEnd; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "setSelectionRange", function() { return setSelectionRange; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getTextIn", function() { return getTextIn; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "textToNodes", function() { return textToNodes; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getCaretPosition", function() { return getCaretPosition; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "setCaretPosition", function() { return setCaretPosition; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "measureText", function() { return measureText; });
/* harmony import */ var _Dom__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1);


function getTextNodesIn(node) {
    var textNodes = [];
    if (node.nodeType == 3) {
        textNodes.push(node);
    } else {
        var children = node.childNodes;
        for (var i = 0, len = children.length; i < len; ++i) {
            textNodes.push.apply(textNodes, getTextNodesIn(children[i]));
        }
    }
    return textNodes;
}

/**
 * 
 * @param {Element} el 
 * @param {Range} range 
 * @param {Number} start 
 * @returns {Number} -1: ok,  ret >= 0(is length of text) : need move to next element
 * 
 */
function setSelectionRangeStart(el, range, start) {
    if (start > 0) {
        if (el.nodeType == Node.TEXT_NODE) {
            var text = el.data;
            if (start <= text.length) {
                range.setStart(el, start);
                return -1;
            }
            else
                return text.length;
        } if (el.tagName.toLowerCase() == 'br') {
            return 0;
        }
        else {
            var delta = 0;
            var i = 0;
            var textLength = 0;
            var newLine = false;
            while (delta >= 0 && i < el.childNodes.length) {
                var childElt = el.childNodes[i];

                if (newLine) {
                    newLine = false;
                    ++textLength;
                }
                delta = setSelectionRangeStart(childElt, range, start - textLength);

                if (delta >= 0) textLength += delta;
                if (childElt.nodeType != Node.TEXT_NODE
                    && (window.getComputedStyle(childElt).display == 'block'
                        || childElt.tagName.toLowerCase() == 'br')) {
                    newLine = true;
                }
                ++i;
            }
            if (delta >= 0) return textLength;
            return -1;
        }
    }
    else {
        range.setStart(el, 0);
        return -1;
    }
}

/**
 * 
 * @param {Element} el 
 * @param {Range} range 
 * @param {Number} end 
 * @returns {Number} -1: ok,  ret >= 0(is length of text) : need move to next element
 * 
 */
function setSelectionRangeEnd(el, range, end) {
    if (end > 0) {
        if (el.nodeType == Node.TEXT_NODE) {
            var text = el.data;
            if (end <= text.length) {
                range.setEnd(el, end);
                return -1;
            }
            else
                return text.length;
        } if (el.tagName.toLowerCase() == 'br') {
            return 0;
        }
        else {
            var delta = 0;
            var i = 0;
            var textLength = 0;
            var newLine = false;
            while (delta >= 0 && i < el.childNodes.length) {
                var childElt = el.childNodes[i];

                if (newLine) {
                    newLine = false;
                    ++textLength;
                }
                delta = setSelectionRangeEnd(childElt, range, end - textLength);

                if (delta >= 0) textLength += delta;
                if (childElt.nodeType != Node.TEXT_NODE
                    && (window.getComputedStyle(childElt).display == 'block'
                        || childElt.tagName.toLowerCase() == 'br')) {
                    newLine = true;
                }
                ++i;
            }
            if (delta >= 0) return textLength;
            return -1;
        }
    }
    else {
        range.setEnd(el, 0);
        return -1;
    }
}

function setSelectionRange(el, start, end) {
    if (document.createRange && window.getSelection) {
        var range = document.createRange();
        range.selectNodeContents(el);
        var delta;
        if (start >= 0) {
            delta = setSelectionRangeStart(el, range, start);
            if (delta >= 0) range.setStart(el, el.childNodes.length);
        }
        else {
            start = 0;
            range.setStart(el, 0);
        }
        if (end >= start) {
            delta = setSelectionRangeEnd(el, range, end);
            if (delta >= 0) range.setEnd(el, el.childNodes.length);
        }
        var sel = window.getSelection();
        sel.removeAllRanges();
        sel.addRange(range);
    } else if (document.selection && document.body.createTextRange) {
        var textRange = document.body.createTextRange();
        textRange.moveToElementText(el);
        textRange.collapse(true);
        textRange.moveEnd("character", end);
        textRange.moveStart("character", start);
        textRange.select();
    }
}

function getTextIn(e) {
    if (e.nodeType == Node.TEXT_NODE) {
        return e.data;
    }
    if (e.tagName && e.tagName.toLowerCase() == 'br') return '';

    var texts = [];
    var newLine = false;
    for (var i = 0; i < e.childNodes.length; ++i) {
        if (newLine) {
            newLine = false;
            texts.push('\n');
        }
        var childElt = e.childNodes[i];
        texts.push(getTextIn(childElt));


        if (childElt.nodeType != Node.TEXT_NODE
            && (window.getComputedStyle(childElt).display == 'block'
                || childElt.tagName.toLowerCase() == 'br')) {
            newLine = true;
        }
    }
    return texts.join('');
}


function textToNodes(text) {
    var lines = text.split(/\r?\n/);
    return lines.map(function (text) {
        if (text.length == 0) {
            return _Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].ShareInstance._({
                child: { tag: 'br' }
            });
        }
        else {
            return _Dom__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].ShareInstance._({
                child: { text: text }
            });
        }
    });
}


/*
** Returns the caret (cursor) position of the specified text field (oField).
** Return value range is 0-oField.value.length.
*/
function getCaretPosition(oField) {

    // Initialize
    var iCaretPos = 0;

    // IE Support
    if (document.selection) {

        // Set focus on the element
        oField.focus();

        // To get cursor position, get empty selection range
        var oSel = document.selection.createRange();

        // Move selection start to 0 position
        oSel.moveStart('character', -oField.value.length);

        // The caret position is selection length
        iCaretPos = oSel.text.length;
    }

    // Firefox support
    else if (oField.selectionStart || oField.selectionStart == '0')
        iCaretPos = oField.selectionDirection == 'backward' ? oField.selectionStart : oField.selectionEnd;

    // Return results
    return iCaretPos;
}


function setCaretPosition(oField, caretPos) {
    if (oField.createTextRange) {
        var range = oField.createTextRange();
        range.move('character', caretPos);
        range.select();
    }
    else {
        if (oField.selectionStart) {
            oField.focus();
            oField.setSelectionRange(caretPos, caretPos);
        }
        else
            oField.focus();
    }
}

function measureText(text, font) {
    // re-use canvas object for better performance
    var canvas = measureText.canvas || (measureText.canvas = document.createElement("canvas"));
    var context = canvas.getContext("2d");
    if (font)
        context.font = font;
    var metrics = context.measureText(text);
    return metrics;
}


/***/ }),
/* 31 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return safeThrow; });
function safeThrow(error) {
    setTimeout(function () {
        throw  error;
    }, 0);
}

/***/ }),
/* 32 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_chromecalendar_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(128);
/* harmony import */ var _css_chromecalendar_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_chromecalendar_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5);
/* harmony import */ var absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(3);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1);
/* harmony import */ var _Scroller__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(53);
/* harmony import */ var absol_src_HTML5_DomSignal__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(20);
/* harmony import */ var absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(2);
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(4);












var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;

/**
 * @extends AElement
 * @constructor
 */
function ChromeCalendar() {
    var thisCal = this;
    this._startDayOfWeek = 0;
    this._level = "day";
    this.$years = $('.absol-chrome-calendar-years', this);
    this._fillYearList(this.$years);
    this.$title = $('.absol-chrome-calendar-title', this)
        .on('click', this.eventHandler.clickTitle);
    this.$titleTime = $('.title-time', this.$title);

    this.$instance = $('.absol-chrome-calendar-instance', this);
    this.$era = $('.absol-chrome-calendar-era', this)
        .on('scroll', this.eventHandler.eraScroll)
        .on('click', this.eventHandler.clickEra);
    this._fillEra();
    this.$month = $('.absol-chrome-calendar-month', this);
    this.$dayOfWeek = $('.absol-chrome-calendar-dayofweek', this);
    this._min = new Date(1890, 0, 1);
    this._max = new Date(2090, 0, 1);

    this._selectedDates = [absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["beginOfDay"](new Date())];
    this._viewDate = new Date();

    this.$prevBtn = $('.absol-chrome-calendar-header-buttons > button.prev-btn', this)
        .on('click', this.eventHandler.clickPrev);
    this.$todayBtn = $('.absol-chrome-calendar-header-buttons > button.today-btn', this)
        .on('click', this.eventHandler.clickToday);
    this.$nextBtn = $('.absol-chrome-calendar-header-buttons > button.next-btn', this)
        .on('click', this.eventHandler.clickNext);

    /***
     *
     * @type {VScroller}
     */
    this.$yearScroller = $('vscroller.absol-chrome-calendar-years', this);
    this.$yearItems = [];

    $('.absol-chrome-calendar-year', this.$yearScroller, function (e) {
        thisCal.$yearItems.push(e);
    });

    this.$attachHook = _('attachhook').addTo(this);

    this.domSignal = new absol_src_HTML5_DomSignal__WEBPACK_IMPORTED_MODULE_6__[/* default */ "a"]((this.$attachHook))
        .on('level_change', this.eventHandler.levelChange)
        .on('request_update_buttons', this._updateButtons.bind(this))
        .on('request_update_month', this._updateMonth.bind(this, this.$month))
        .on('request_update_open_year', this._updateOpenYear.bind(this))
        .on('request_update_disabled_year_in_era', this._updateDisabledYearInEra.bind(this))
        .on('request_update_picked_years', this._updatePickedYears.bind(this));

    this.sync = new Promise(function (rs) {
        thisCal.$attachHook.on('attached', rs);
    });
    this.domSignal.emit('level_change');
    this.sync.then('attached', function () {
        thisCal.$yearScroller.requestUpdateSize();
        thisCal.expandYear(thisCal._viewDate.getFullYear());
        thisCal._updateYearInEra();
    });
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_7__[/* default */ "a"].drillProperty(this, this, 'minLimitDate', 'min');
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_7__[/* default */ "a"].drillProperty(this, this, 'minDateLimit', 'min');
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_7__[/* default */ "a"].drillProperty(this, this, 'maxLimitDate', 'max');
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_7__[/* default */ "a"].drillProperty(this, this, 'maxDateLimit', 'max');
}


ChromeCalendar.tag = 'ChromeCalendar'.toLowerCase();
ChromeCalendar.render = function () {
    return _({
        class: ['absol-chrome-calendar', 'as-level-day'],
        extendEvent: 'pick',
        child: [
            {
                class: 'absol-chrome-calendar-header',
                child: [
                    {
                        class: 'absol-chrome-calendar-title',
                        child: [
                            {
                                tag: 'span',
                                class: 'title-time',
                                child: {text: 'Septemper, 2019'}
                            },

                        ]
                    },
                    {
                        class: 'absol-chrome-calendar-header-buttons',
                        child: [
                            {
                                tag: 'button',
                                class: 'prev-btn',
                                child: 'span.mdi.mdi-menu-left',
                                attr: {
                                    title: 'Previous Month'
                                }
                            },
                            {
                                tag: 'button',
                                class: 'today-btn',
                                child: 'span.mdi.mdi-circle-medium',
                                attr: {
                                    title: 'Today'
                                }
                            },
                            {
                                tag: 'button',
                                class: 'next-btn',
                                child: 'span.mdi.mdi-menu-right',
                                attr: {
                                    title: 'Next Month'
                                }
                            }
                        ]

                    }
                ]
            },
            {
                class: 'absol-chrome-calendar-instance',
                child: [
                    {
                        class: 'absol-chrome-calendar-dayofweek',
                        child: ['Su', 'Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa'].map(function (text) {
                            return {
                                child: {text: text}
                            }
                        })
                    },
                    {

                        class: 'absol-chrome-calendar-month',
                        child: Array(6).fill(0).map(function (u, i) {
                            return {
                                class: 'absol-chrome-calendar-week-in-month',
                                child: Array(7).fill(0).map(function (v, j) {
                                    return {
                                        child: {text: i * 7 + j + ''}
                                    }
                                })
                            }
                        })

                    },
                    {
                        tag: 'vscroller',
                        class: 'absol-chrome-calendar-years',
                        child: {}
                    },
                    {
                        class: "absol-chrome-calendar-era"
                    }
                ]
            }
        ]
    });
};


/**
 * @param {Date} date
 * @returns {Boolean}
 */
ChromeCalendar.prototype._isSelectedDate = function (date) {
    for (var i = 0; i < this._selectedDates.length; ++i) {
        if (Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["compareDate"])(date, this._selectedDates[i]) === 0) return true;
    }
    return false;
};
/**
 * @param {Date} date
 * @returns {Boolean}
 */
ChromeCalendar.prototype._isSelectedMonth = function (date) {
    for (var i = 0; i < this._selectedDates.length; ++i) {
        if (Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["compareMonth"])(date, this._selectedDates[i]) === 0) return true;
    }
    return false;
};

/**
 * @param {Date} date
 * @returns {Boolean}
 */
ChromeCalendar.prototype._isSelectedYear = function (date) {
    for (var i = 0; i < this._selectedDates.length; ++i) {
        if (date.getFullYear() === this._selectedDates[i].getFullYear()) return true;
    }
    return false;
};

ChromeCalendar.prototype._dayCmpLimit = function (date) {
    if (Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["compareDate"])(date, this._min) < 0) return -1;
    if (Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["compareDate"])(date, this._max) > 0) return 1;
    return 0;
};

ChromeCalendar.prototype._monthCmpLimit = function (date) {
    var startOfMonth = Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["beginOfMonth"])(date);
    var endOfMonth = Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["nextMonth"])(date);
    var minMil = Math.max(startOfMonth.getTime(), this._min.getTime());
    var maxMil = Math.min(endOfMonth.getTime(), Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["nextDate"])(this._max).getTime());
    if (minMil < maxMil) return 0;
    return this._dayCmpLimit(date);
};

ChromeCalendar.prototype._yearCmpLimit = function (date) {
    var startOfYear = Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["beginOfYear"])(date);
    var endOfYear = new Date(date.getFullYear() + 1, 0, 1);
    var minMil = Math.max(startOfYear.getTime(), this._min.getTime());
    var maxMil = Math.min(endOfYear.getTime(), Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["nextDate"])(this._max).getTime());
    if (minMil < maxMil) return 0;
    return this._dayCmpLimit(date);
};


/***
 *
 * @param {Date} date
 * @param event
 */
ChromeCalendar.prototype.pickDate = function (date, event) {
    date = Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["beginOfDay"])(date);
    this._selectedDates = [date];
    this._updateMonth(this.$month);
    if (this.$lastOpenYearItem) this.$lastOpenYearItem.$months.updateActiveMonth();

    this.emit('pick', {
        type: 'pick', value: date,
        isTrusted: event && event.isTrusted,
        originEvent: event,
        selectedDates: this.selectedDates
    });
};

/***
 *
 * @param {Date} date
 * @param event
 */
ChromeCalendar.prototype.pickMonth = function (date, event) {
    date = Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["beginOfMonth"])(date);
    this._selectedDates = [date];
    if (this.$lastOpenYearItem) this.$lastOpenYearItem.$months.updateActiveMonth();
    this.emit('pick', {
        type: 'pick', value: date,
        isTrusted: event && event.isTrusted,
        originEvent: event,
        selectedDates: this.selectedDates
    });
};

ChromeCalendar.prototype._updatePickedYears = function () {
    var yearElt;
    var self = this;
    while (this.$lastPickYears && this.$lastPickYears.length > 0) {
        yearElt = this.$lastPickYears.pop();
        yearElt.removeClass('absol-chrome-calendar-selected');
    }
    this.$lastPickYears = this._selectedDates.map(function (date) {
        var yearElt = self._yearInAre(date.getFullYear());
        yearElt.addClass('absol-chrome-calendar-selected');
        return yearElt;
    })

};

ChromeCalendar.prototype.pickYear = function (year, event) {
    var date = new Date(year, 0, 1, 0, 0, 0, 0);
    this._selectedDates = [date];
    this.domSignal.emit('request_update_picked_years');
    this.scrollIntoDecade(Math.floor(year / 10) * 10, true);
    this.emit('pick', {
        type: 'pick', value: date,
        isTrusted: event && event.isTrusted,
        originEvent: event,
    });
};


/**
 * @param {Element} monthElt
 * @param {Date} date
 */
ChromeCalendar.prototype._fillMonth = function (monthElt, date) {
    var self = this;
    if (monthElt.$cells === undefined) {//for faster, attach event to element
        monthElt.$cells = [];
        Array.prototype.forEach.call(monthElt.childNodes, function (row) {
            row.on('click', function (event) {
                if (event.target !== this) return;
                var pickedElt = this.firstChild;
                var pickDate = this.firstChild.__date__;
                self.pickDate(pickDate, event);
                if (pickedElt.containsClass('absol-chrome-calendar-not-in-month')) {
                    if (pickDate.getDate() < 15) {
                        self.viewNexMonth();
                    } else {
                        self.viewPrevMonth();
                    }
                }
            });
        });
        $('.absol-chrome-calendar-week-in-month > div', this.$month, function (elt) {
            monthElt.$cells.push(elt);

            elt.on('click', function (event) {
                var pickedElt = elt;
                var pickDate = this.__date__;
                if (self._level === 'week') {
                    pickDate = Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["beginOfWeek"])(pickDate, false, self._startDayOfWeek);
                    pickedElt = elt.parentElement.firstChild;
                }
                self.pickDate(pickDate, event);
                if (pickedElt.containsClass('absol-chrome-calendar-not-in-month')) {
                    if (pickDate.getDate() < 15) {
                        self.viewNexMonth();
                    } else {
                        self.viewPrevMonth();
                    }
                }

            });
        });
    }

    var currentDate = absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["beginOfWeek"](absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["beginOfMonth"](date), false, this._startDayOfWeek);


    var d;
    var cell;
    for (var i = 0; i < monthElt.$cells.length; ++i) {
        cell = monthElt.$cells[i];
        d = currentDate.getDate();
        cell.innerHTML = '' + d;
        cell.__date__ = absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["beginOfDay"](currentDate);
        currentDate = absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["nextDate"](currentDate);
    }
    Array.prototype.forEach.call(monthElt.childNodes, function (row) {
        var weekIdx = Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["weekIndexOf"])(row.firstChild.__date__, false, self._startDayOfWeek);
        row.attr('data-week-idx-text', Object(_utils__WEBPACK_IMPORTED_MODULE_8__["zeroPadding"])(1 + weekIdx, 2) + '');
    });
};

ChromeCalendar.prototype._updateMonth = function (monthElt) {
    if (!monthElt.$cells) return; // days weren't filled
    var now = new Date();
    var viewM = this._viewDate.getMonth();
    var m;
    var cell;
    var currentDate;
    var selectedWeeks = {};
    for (var i = 0; i < monthElt.$cells.length; ++i) {
        cell = monthElt.$cells[i];
        currentDate = cell.__date__;
        m = currentDate.getMonth();
        if (m != viewM)
            cell.addClass('absol-chrome-calendar-not-in-month');
        else
            cell.removeClass('absol-chrome-calendar-not-in-month');
        if (absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["compareDate"](currentDate, now) === 0)
            cell.addClass('absol-chrome-calendar-today');
        else
            cell.removeClass('absol-chrome-calendar-today');

        if (this._isSelectedDate(currentDate)) {
            cell.addClass('absol-chrome-calendar-selected');
            selectedWeeks[Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["weekIndexOf"])(currentDate, false, this._startDayOfWeek)] = true;
        } else
            cell.removeClass('absol-chrome-calendar-selected');

        if (absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["compareDate"](this._min, currentDate) > 0 || absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["compareDate"](currentDate, this._max) > 0) {
            cell.addClass('absol-chrome-calendar-date-disabled');
        } else {
            cell.removeClass('absol-chrome-calendar-date-disabled');
        }
    }
    Array.prototype.forEach.call(monthElt.childNodes, function (row) {
        var weekIdx = Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["weekIndexOf"])(row.firstChild.__date__, false, this._startDayOfWeek);
        if (selectedWeeks[weekIdx]) {
            row.addClass('as-week-selected');

        } else {
            row.removeClass('as-week-selected');
        }
    }.bind(this))

};

ChromeCalendar.prototype._fillYearList = function (ctn) {
    var thisCal = this;
    _({
        child: Array(200).fill(0).map(function (u, i) {
            return {
                class: 'absol-chrome-calendar-year',
                child: [
                    {
                        class: 'absol-chrome-calendar-year-head',
                        child: {text: i + 1890 + ''},
                    }
                ],
                props: {
                    __year__: i + 1890
                },
                on: {
                    click: function () {
                        thisCal.expandYear(this.__year__);
                    }
                }
            };
        })
    }).addTo(ctn);
};


ChromeCalendar.prototype._fillEra = function () {
    var now = new Date();
    var cYear = now.getFullYear();
    var rows = Array(50).fill(0).map(function (u, i) {
        return _({
            class: 'absol-chrome-calendar-era-row',
            child: Array(4).fill(0).map(function (u1, j) {
                var classList = ['absol-chrome-calendar-era-year'];
                var year = 1890 + i * 4 + j;
                if (cYear === year) {
                    classList.push('absol-chrome-calendar-today');
                }
                return {
                    class: classList,
                    child: {text: year + ''},
                    props: {
                        __year__: year
                    }
                };
            })
        });
    });
    this.$era.addChild(rows);
}

ChromeCalendar.prototype.viewNexMonth = function () {
    var self = this;
    this.sync = this.sync.then(function () {
        return new Promise(function (rs) {
            var oldBound = self.$month.getBoundingClientRect();
            var oldMonth = self.$month.cloneNode(true);
            var instanceBound = self.$instance.getBoundingClientRect();
            if (self.$lastAnimationCtn) {
                self.$lastAnimationCtn.removeClass('new').addClass('old');
            }
            var oldMonthCnt = _({
                class: ['absol-chrome-calendar-month-animation-container', 'old'],
                style: {
                    top: oldBound.top - instanceBound.top + 'px',
                    height: oldBound.height + 'px',
                    width: oldBound.width + 'px'
                },
                child: oldMonth
            }).addTo(self.$instance);

            self._viewDate = absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["nextMonth"](self._viewDate);
            self.viewMonth();

            var newMonth = self.$month.cloneNode(true);
            var overlap = 0;
            var j = 41;
            while (j >= 0 && self.$month.$cells[j].containsClass('absol-chrome-calendar-not-in-month')) {
                overlap += oldBound.height / 6;
                j -= 7;
            }

            var newMonthCtn = _({
                class: ['absol-chrome-calendar-month-animation-container', 'new'],
                style: {
                    top: oldBound.top + oldBound.height - instanceBound.top - overlap + 'px',
                    height: oldBound.height + 'px',
                    width: oldBound.width + 'px'
                },
                child: newMonth
            }).addTo(self.$instance);

            self.$lastAnimationCtn = newMonthCtn;
            setTimeout(function () {
                oldMonthCnt.addStyle('top', oldBound.top - oldBound.height + overlap - instanceBound.top + 'px');
                newMonthCtn.addStyle('top', oldBound.top - instanceBound.top + 'px');
            }, 20);
            setTimeout(function () {
                self.$lastAnimationCtn = undefined;
                oldMonthCnt.remove();
                newMonthCtn.remove();
            }, 220);
            setTimeout(rs, 22);
        });
    });
    return this.sync;
};

ChromeCalendar.prototype.viewPrevMonth = function () {
    var self = this;
    this.sync = this.sync.then(function () {
        return new Promise(function (rs) {
            var oldBound = self.$month.getBoundingClientRect();
            var oldMonth = self.$month.cloneNode(true);
            var instanceBound = self.$instance.getBoundingClientRect();
            if (self.$lastAnimationCtn) {
                self.$lastAnimationCtn.removeClass('new').addClass('old');
            }
            var oldMonthCnt = _({
                class: ['absol-chrome-calendar-month-animation-container', 'old'],
                style: {
                    top: oldBound.top - instanceBound.top + 'px',
                    height: oldBound.height + 'px',
                    width: oldBound.width + 'px'
                },
                child: oldMonth
            }).addTo(self.$instance);
            self._viewDate = absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["prevMonth"](self._viewDate);
            self.viewMonth();
            var newMonth = self.$month.cloneNode(true);
            var overlap = 0;
            var j = 0;
            while (j < 42 && self.$month.$cells[j].containsClass('absol-chrome-calendar-not-in-month')) {
                overlap += oldBound.height / 6;
                j += 7;
            }

            var newMonthCtn = _({
                class: ['absol-chrome-calendar-month-animation-container', 'new'],
                style: {
                    top: oldBound.top - oldBound.height + overlap - instanceBound.top + 'px',
                    height: oldBound.height + 'px',
                    width: oldBound.width + 'px'
                },
                child: newMonth
            }).addTo(self.$instance);

            self.$lastAnimationCtn = newMonthCtn;
            setTimeout(function () {
                oldMonthCnt.addStyle('top', oldBound.top + oldBound.height - overlap - instanceBound.top + 'px');
                newMonthCtn.addStyle('top', oldBound.top - instanceBound.top + 'px');
            }, 20);
            setTimeout(function () {
                self.$lastAnimationCtn = undefined;
                oldMonthCnt.remove();
                newMonthCtn.remove();
            }, 220);
            setTimeout(rs, 22);
        })
    });
    return this.sync;
};


ChromeCalendar.prototype.viewToday = function () {
    this._viewDate = new Date();
    switch (this._level) {
        case "day":
        case 'week':
            this.viewMonth();
            break;
        case "month":
            break;
        case "year":
            this.viewEra(true);
            break;
    }
};

ChromeCalendar.prototype.viewMonth = function () {
    this._updateButtons();
    this.removeClass('view-year')
        .removeClass('view-era')
        .addClass('view-month');
    this._fillMonth(this.$month, this._viewDate);
    this._updateMonth(this.$month);
    this.$titleTime.innerHTML = absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["formatDateString"](this._viewDate, 'mmmm, yyyy');
};


ChromeCalendar.prototype.viewYear = function () {
    this.removeClass('view-month')
        .removeClass('view-era')
        .addClass('view-year');
    this.expandYear(this._viewDate.getFullYear());
    this.$yearScroller.requestUpdateSize();
};

ChromeCalendar.prototype.viewEra = function (animation) {
    this.removeClass('view-month')
        .removeClass('view-year')
        .addClass('view-era');
    this.scrollIntoDecade(Math.floor(this._viewDate.getFullYear() / 10) * 10, animation);
};

ChromeCalendar.prototype.viewNextDecade = function (animation) {
    this._viewDate = new Date(Math.min(2080, Math.floor(this._viewDate.getFullYear() / 10) * 10 + 10), 0, 1);
    this._viewDate = new Date(Math.min(this._viewDate.getTime(), Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["prevDate"])(this._max).getTime()));
    this.viewEra(animation);
};

ChromeCalendar.prototype.viewPrevDecade = function (animation) {
    this._viewDate = new Date((Math.max(1890, Math.floor(this._viewDate.getFullYear() / 10) * 10 - 10)), 0, 1);
    this._viewDate = new Date(Math.max(this._viewDate.getTime(), this._min.getTime()));
    this.viewEra(animation);
};


ChromeCalendar.prototype.expandYear = function (year) {
    if (this._level === 'month') {
        this._viewDate = new Date(year, 0, 1);
        this.$titleTime.innerHTML = Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["formatDateString"])(this._viewDate, 'mmmm, yyyy');
        this.domSignal.emit('request_update_buttons');
    }

    var fontSize = this.getFontSize();
    var self = this;
    var lastItemElt = this.$lastOpenYearItem;

    var itemElt = this.$yearItems[year - 1890];
    var lastYear = 100000000;
    if (lastItemElt && lastItemElt.__year__ !== year) {
        lastYear = lastItemElt.__year__;
        lastItemElt.addClass('start-closing');
        setTimeout(function () {
            lastItemElt.removeClass('start-closing').addClass('closing');
        }, 0);
        setTimeout(function () {
            lastItemElt.removeClass('closing');
            lastItemElt.$months.remove();
            lastItemElt.$months = undefined;
        }, 100);
    }

    if (lastItemElt !== itemElt) {
        if (!itemElt.$months) {
            itemElt.$months = this._createMonths(year).addTo(itemElt);
            itemElt.addClass('start-opening');

            setTimeout(function () {
                itemElt.removeClass('start-opening').addClass('opening');
            }, 1);
            setTimeout(function () {
                itemElt.removeClass('opening');
            }, 100);
        }
    }
    var dy = itemElt.getBoundingClientRect().top - self.$yearScroller.getBoundingClientRect().top - fontSize * 0.45;
    if (itemElt.__year__ > lastYear) {
        dy -= 6 * fontSize;
    }

    self.$yearScroller.scrollBy(dy, 100);
    this.$lastOpenYearItem = itemElt;
    itemElt.$months.updateActiveMonth();
};

ChromeCalendar.prototype.scrollIntoDecade = function (startYear, animation) {
    if (!this.isDescendantOf(document.body)) {
        return this.sync.then(this.scrollIntoDecade.bind(this));

    }
    var thisCal = this;
    return new Promise(function (resolve) {

        var eraBound = thisCal.$era.getBoundingClientRect();
        var rowIdx = Math.floor((startYear - 1890) / 4);
        if (thisCal._decadeScrollTimeout > 0) {
            clearTimeout(thisCal._decadeScrollTimeout);
            thisCal._decadeScrollTimeout = -1;
        }
        if (thisCal.scrollIntoDecadeResolve) {
            thisCal.scrollIntoDecadeResolve();
            thisCal.scrollIntoDecadeResolve = null;
        }
        thisCal.scrollIntoDecadeResolve = resolve;

        var t0 = new Date().getTime();
        var t1 = t0 + 250;
        var y0 = thisCal.$era.scrollTop;
        var y1 = rowIdx * eraBound.height / 4;
        if (animation) {
            thisCal._decadeScrollTimeout = setTimeout(function tick() {
                var tc = new Date().getTime();
                var yc = Math.min(1, Math.pow((tc - t0) / (t1 - t0), 2)) * (y1 - y0) + y0;
                thisCal.$era.scrollTop = yc;
                if (tc < t1) {
                    thisCal._decadeScrollTimeout = setTimeout(tick, 30);
                } else {
                    thisCal._decadeScrollTimeout = -1;
                    thisCal.scrollIntoDecadeResolve = null;
                    resolve();
                }
            }, 30);
        } else {
            thisCal.$era.scrollTop = y1;
        }
    });

};


ChromeCalendar.prototype._updateButtons_day = function () {
    if (this._monthCmpLimit(Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["prevMonth"])(this._viewDate)) < 0) {
        this.$prevBtn.addClass('absol-chrome-calendar-button-disabled');
    } else {
        this.$prevBtn.removeClass('absol-chrome-calendar-button-disabled');

    }
    if (this._monthCmpLimit(Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["nextMonth"])(this._viewDate)) > 0) {
        this.$nextBtn.addClass('absol-chrome-calendar-button-disabled');
    } else {
        this.$nextBtn.removeClass('absol-chrome-calendar-button-disabled');
    }

    var now = new Date();
    if (this._monthCmpLimit(now) === 0) {
        this.$todayBtn.removeClass('absol-chrome-calendar-button-disabled');
    } else {
        this.$todayBtn.addClass('absol-chrome-calendar-button-disabled');
    }
};

ChromeCalendar.prototype._updateButtons_week = ChromeCalendar.prototype._updateButtons_day;

ChromeCalendar.prototype._updateButtons_year = function () {
    if (!this._viewDate) return;
    var year = Math.floor(this._viewDate.getFullYear() / 10) * 10;
    if (this._yearCmpLimit(new Date(year - 1, 0, 1)) < 0) {
        this.$prevBtn.addClass('absol-chrome-calendar-button-disabled');
    } else {
        this.$prevBtn.removeClass('absol-chrome-calendar-button-disabled');
    }
    if (this._yearCmpLimit(new Date(year + 10, 0, 1)) > 0) {
        this.$nextBtn.addClass('absol-chrome-calendar-button-disabled');
    } else {
        this.$nextBtn.removeClass('absol-chrome-calendar-button-disabled');
    }
    var now = new Date();
    if (this._yearCmpLimit(now) === 0) {
        this.$todayBtn.removeClass('absol-chrome-calendar-button-disabled');
    } else {
        this.$todayBtn.addClass('absol-chrome-calendar-button-disabled');
    }
};

ChromeCalendar.prototype._updateButtons_month = function () {
    if (this._yearCmpLimit(new Date(this._viewDate.getFullYear() + 1, 0, 1)) > 0) {
        this.$nextBtn.addClass('absol-chrome-calendar-button-disabled');
    } else {
        this.$nextBtn.removeClass('absol-chrome-calendar-button-disabled');
    }
    if (this._yearCmpLimit(new Date(this._viewDate.getFullYear() - 1, 0, 1)) < 0) {
        this.$prevBtn.addClass('absol-chrome-calendar-button-disabled');
    } else {
        this.$prevBtn.removeClass('absol-chrome-calendar-button-disabled');
    }
};

ChromeCalendar.prototype._updateButtons = function () {
    var fName = '_updateButtons_' + this._level;
    this[fName] && this[fName]();
};

ChromeCalendar.prototype._createMonths = function (year) {
    var now = new Date();
    var self = this;
    var res = _({
        class: 'absol-chrome-calendar-year-mounths',
        child: Array(3).fill('').map(function (u, i) {
            return {
                class: 'absol-chrome-calendar-year-row-months',
                child: Array(4).fill(0).map(function (v, j) {
                    var date = new Date(year, i * 4 + j, 1, 0, 0, 0, 0, 0);
                    return {
                        class: ['absol-chrome-calendar-year-month']
                            .concat((year == now.getFullYear() && now.getMonth() == i * 4 + j) ? ['absol-chrome-calendar-today'] : [])
                            .concat(self._isSelectedMonth(date) ? ['absol-chrome-calendar-selected'] : [])
                        ,
                        child: {text: absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["monthNames"][i * 4 + j].substr(0, 3)},
                        on: {
                            click: function () {

                            }
                        },
                        props: {
                            __date__: date
                        }
                    }
                })
            }
        }),
        on: {
            click: this.eventHandler.clickMonthsInYear
        }
    });
    res.$monthList = [];
    $('.absol-chrome-calendar-year-month', res, function (e) {
        res.$monthList.push(e);
    });

    res.updateActiveMonth = function () {
        res.$monthList.forEach(function (e) {
            now = new Date();
            if (absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["compareMonth"](e.__date__, now) == 0) {
                e.addClass('absol-chrome-calendar-today');
            } else {
                e.removeClass('absol-chrome-calendar-today');
            }

            if (self._isSelectedMonth(e.__date__)) {
                e.addClass('absol-chrome-calendar-selected');
            } else {
                e.removeClass('absol-chrome-calendar-selected');

            }
            var beginOfMonth = absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["beginOfMonth"](e.__date__);
            var endOfMonth = absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["prevDate"](absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["nextMonth"](e.__date__));
            if (absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["compareDate"](self._min, endOfMonth) > 0 || absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["compareDate"](beginOfMonth, self._max) > 0) {
                e.addClass('absol-chrome-calendar-date-disabled');
            } else {
                e.removeClass('absol-chrome-calendar-date-disabled');
            }
        });
    }
    return res;
};

ChromeCalendar.prototype._yearInAre = function (year) {
    var d = year - 1890;
    var rowIdx = Math.floor(d / 4);
    var colIdx = d % 4;
    return this.$era.childNodes[rowIdx] && this.$era.childNodes[rowIdx].childNodes[colIdx];
};

ChromeCalendar.prototype._clearYearInAre = function (startYear) {
    var cellElt;
    for (var i = 0; i < 10; ++i) {
        cellElt = this._yearInAre(startYear + i);
        if (cellElt) cellElt.removeClass('absol-chrome-calendar-in-decade');
    }
};

ChromeCalendar.prototype._activeYearInAre = function (startYear) {
    var cellElt;
    for (var i = 0; i < 10; ++i) {
        cellElt = this._yearInAre(startYear + i);
        if (cellElt) cellElt.addClass('absol-chrome-calendar-in-decade');
    }
};

ChromeCalendar.prototype._updateYearInEra = function () {
    var eraBound = this.$era.getBoundingClientRect();
    var startYear = 1890 + 4 * Math.ceil((this.$era.scrollTop - eraBound.height / 16) * 4 / eraBound.height);
    var startDecade = Math.floor(startYear / 10) * 10;
    if ((startDecade + 10 - startYear) < 8) startDecade += 10;
    if (this._lastStartDecade !== startDecade) {
        if (this._lastStartDecade > 0) {
            this._clearYearInAre(this._lastStartDecade);
        }
        this._lastStartDecade = startDecade;
        this._activeYearInAre(startDecade);
        if (this._level === 'year') {
            this.$titleTime.innerHTML = startDecade + '-' + (startDecade + 10);
            if (!this._decadeScrollTimeout || this._decadeScrollTimeout < 0) {
                if (this._yearCmpLimit(new Date(startDecade, 0, 1)) === 0)
                    this._viewDate = new Date(startDecade, 0, 1);
            }
        }
        this.domSignal.emit('request_update_buttons');
    }
};

ChromeCalendar.prototype._updateDisabledYearInEra = function () {
    var self = this;
    Array.prototype.forEach.call(this.$era.childNodes, function (rowElt) {
        Array.prototype.forEach.call(rowElt.childNodes, function (cellElt) {
            if (cellElt.__year__) {
                if (self._yearCmpLimit(new Date(cellElt.__year__, 0, 1)) === 0) {
                    cellElt.removeClass('absol-chrome-calendar-date-disabled');
                } else {
                    cellElt.addClass('absol-chrome-calendar-date-disabled');
                }
            }
        });
    });
};

ChromeCalendar.prototype._updateOpenYear = function () {
    if (this.$lastOpenYearItem) {
        this.$lastOpenYearItem.$months.updateActiveMonth();
    }
};


ChromeCalendar.property = {};

ChromeCalendar.property.selectedDates = {
    set: function (value) {
        value = value || [];
        if (value instanceof Date) value = [value];
        this._selectedDates = value;
        this._viewDate = this._selectedDates[0] || new Date();
        this.domSignal.emit('level_change');
        if (this._level === 'year')
            this.domSignal.emit('request_update_picked_years');
    },
    get: function () {
        return this._selectedDates;
    }
};


ChromeCalendar.property.min = {
    set: function (value) {
        if (!value) value = new Date(1890, 0, 1);
        if (typeof value == 'number') value = new Date(value);
        value = Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["beginOfDay"])(value);
        value = new Date(Math.max(new Date(1890, 0, 1).getTime(), value.getTime()));
        this._min = value;
        this.domSignal.emit('request_update_buttons');
        this.domSignal.emit('request_update_month');
        this.domSignal.emit('request_update_open_year');
        this.domSignal.emit('request_update_disabled_year_in_era');

    },
    get: function () {
        return this._min;
    }
};

//include maxLimitDate
ChromeCalendar.property.max = {
    set: function (value) {
        if (!value) value = new Date(2090, 0, 1);
        if (typeof value == 'number') value = new Date(value);
        if (value.getTime() > Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["beginOfDay"])(value).getTime()) value = Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["nextDate"])(Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["beginOfDay"])(value));
        value = new Date(Math.min(new Date(2090, 0, 1).getTime(), value.getTime()));
        this._max = value;
        this.domSignal.emit('request_update_buttons');
        this.domSignal.emit('request_update_month');
        this.domSignal.emit('request_update_open_year');
        this.domSignal.emit('request_update_disabled_year_in_era');
    },
    get: function () {
        return this._max;
    }
};


ChromeCalendar.property.multiSelect = {
    set: function (value) {
        throw new Error('Not support yet!')
        var lastValue = this.multiSelect;
        value = !!value;
        if (lastValue != value) {
            if (value) {
                this.addClass('multi-select')
            } else {
                this.removeClass('multi-select');
            }
            this._updateMonth(this.$month);
        }
    },
    get: function () {
        return this.containsClass('multi-select');
    }
};


ChromeCalendar.property.level = {
    set: function (value) {
        value = (value || '') + '';
        value = value.toLowerCase();
        if (['day', 'week', 'month', 'year'].indexOf(value) < 0) value = 'day';
        if (this._level === value) return;
        this.removeClass('as-level-' + this._level);
        this._level = value;
        this.addClass('as-level-' + this._level);
        this.domSignal.emit('level_change');
        if (this._level === 'year')
            this.domSignal.emit('request_update_picked_years');
    },
    get: function () {
        return this._level;
    }
};

ChromeCalendar.prototype.dayInWeekTexts = ['Su', 'Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa'];

ChromeCalendar.property.startDayOfWeek = {
    set: function (value) {
        value = Math.max(0, Math.min(Math.floor(value || 0), 6));
        if (this._startDayOfWeek !== value) {
            this._startDayOfWeek = value;
            Array.prototype.forEach.call(this.$dayOfWeek.childNodes, function (e, i) {
                e.firstChild.data = this.dayInWeekTexts[(i + value) % 7];
            }.bind(this));
        }
        this._updateMonth(this.$month);
    },
    get: function () {
        return this._startDayOfWeek;
    }
};


ChromeCalendar.property.viewDate = {
    set: function (date) {
        this._viewDate = date;
        this.domSignal.emit('level_change');
    },
    get: function () {
        return this._viewDate;
    }
}

ChromeCalendar.eventHandler = {};

ChromeCalendar.eventHandler.eraScroll = function () {
    this._updateYearInEra();
};

ChromeCalendar.eventHandler.clickEra = function (event) {
    var yearElt = event.target;
    var year = yearElt.__year__;
    if (typeof year !== "number") return;
    this.pickYear(year, event);
};


ChromeCalendar.eventHandler.clickPrev = function () {
    switch (this._level) {
        case "day":
        case 'week':
            this.viewPrevMonth();
            break;
        case "month":
            this.expandYear(Math.min(this._max.getFullYear(), this._viewDate.getFullYear() - 1));
            break;
        case "year":
            if (!this._decadeScrollTimeout || this._decadeScrollTimeout < 0)
                this.viewPrevDecade(true);
            break;

    }
};

ChromeCalendar.eventHandler.clickNext = function () {
    switch (this._level) {
        case "day":
        case 'week':
            this.viewNexMonth();
            break;
        case "month":
            this.expandYear(Math.max(Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["prevDate"])(this._min).getFullYear(), this._viewDate.getFullYear() + 1));
            break;
        case "year":
            if (!this._decadeScrollTimeout || this._decadeScrollTimeout < 0)
                this.viewNextDecade(true);
            break;
    }
};


ChromeCalendar.eventHandler.clickToday = function (event) {
    this.viewToday();
    switch (this._level) {
        case "day":
            this.pickDate(new Date(), event);
            break;
        case 'week':
            this.pickDate(Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["beginOfWeek"])(new Date(), false, this.startDayOfWeek), event)
            break;
        case "month":
            this.expandYear(new Date().getFullYear());
            this.pickMonth(Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_2__["beginOfMonth"])(new Date()), event);
            break;
        case "year":
            this.pickYear(new Date().getFullYear());
            this._viewDate = new Date(new Date().getFullYear(), 0, 1);
            this.viewEra(true);
            break;
    }
};

ChromeCalendar.eventHandler.clickTitle = function (event) {
    switch (this._level) {
        case "day":
        case "week":
            this.viewYear();
            break;
        case "month":
            break;
        case "year":
            break;
    }
};


ChromeCalendar.eventHandler.clickMonthsInYear = function (event) {
    var monthElt = event.target;
    var date = monthElt.__date__;
    if (!date) return;
    switch (this._level) {
        case "day":
        case "week":
            this._viewDate = date;
            this.viewMonth();
            break;
        case "month":
            this.pickMonth(date, event);
            break;
        case "year":
            break;
    }
};


ChromeCalendar.eventHandler.levelChange = function () {
    switch (this._level) {
        case "day":
        case "week":
            this.viewMonth();
            break;
        case "month":
            this.viewYear();
            break;
        case "year":
            this.viewEra();
            break;
    }
};

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(ChromeCalendar);


ChromeCalendar._session = Math.random() * 10000000000 >> 0;
ChromeCalendar._listener = undefined;


ChromeCalendar.showWhenClick = function (element, calendarProps, anchor, calendarPickListener, darkTheme) {
    var res = {
        calendarProps: Object.assign({maxDateLimit: null, minDateLimit: null}, calendarProps),
        anchor: anchor,
        currentSession: undefined,
        element: element,
        calendarPickListener: calendarPickListener,
        darkTheme: darkTheme,
        setDateValue: function (value) {
            if (this.currentSession == ChromeCalendar._session) {
                ChromeCalendar.$calendar.selectedDates = [value];
            }
        },
        cancel: function () {
        }
    };

    var clickHandler = function () {

        if (ChromeCalendar._session == res.currentSession) return;

        res.currentSession = ChromeCalendar.show(res.element, res.calendarProps, res.anchor, res.calendarPickListener, res.darkTheme);

        var finish = function (event) {
            if (event && event.target && absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_3__[/* default */ "b"].hitElement(ChromeCalendar.$calendar, event)) return;
            document.body.removeEventListener('click', finish, false);
            ChromeCalendar.close(res.currentSession);
            ChromeCalendar.$calendar.off('pick', finish);

            res.currentSession = undefined;
            res.cancel = function () {
            };
        };

        setTimeout(function () {
            document.body.addEventListener('click', finish, false);
            ChromeCalendar.$calendar.on('pick', finish);
            res.cancel = finish;
        }, 10)
    };

    res.remove = function () {
        element.removeEventListener('click', clickHandler, false);
    };

    element.addEventListener('click', clickHandler, false);
    return res;
};


ChromeCalendar.show = function (element, calendarProps, anchor, calendarPickListener, darkTheme) {
    ChromeCalendar._session = Math.random() * 10000000000 >> 0;

    function exec() {
        if (!ChromeCalendar.$ctn) {
            ChromeCalendar.$ctn = _('.absol-context-hinge-fixed-container');
            ChromeCalendar.$follower = _('follower').addTo(ChromeCalendar.$ctn);

            ChromeCalendar.$calendar = _('chromecalendar')
                .on('pick', function (event) {
                    if (typeof ChromeCalendar._listener == 'function') {
                        ChromeCalendar._listener(event.value);
                    }
                }).addTo(ChromeCalendar.$follower);
        }

        ChromeCalendar.$ctn.addTo(document.body);
        // only one value need
        if (calendarProps instanceof Date) calendarProps = {selectedDates: [calendarProps]};
        if (calendarProps instanceof Array) calendarProps = {selectedDates: calendarProps};

        Object.assign(ChromeCalendar.$calendar, calendarProps);
        if (darkTheme) ChromeCalendar.$ctn.addClass('dark');
        else ChromeCalendar.$ctn.removeClass('dark');
        ChromeCalendar.$follower.followTarget = element;
        ChromeCalendar.$follower.anchor = anchor;
        ChromeCalendar.$calendar.addStyle('visibility', 'hidden');//for prevent size change blink
        ChromeCalendar._listener = calendarPickListener;
        setTimeout(function () {
            ChromeCalendar.$follower.updatePosition();
            ChromeCalendar.$calendar.removeStyle('visibility');
        }, 2);
    }

    if (document.body)
        exec();
    else
        absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].documentReady.then(exec);

    return ChromeCalendar._session;
};


ChromeCalendar.close = function (session) {
    if (session !== true && session != ChromeCalendar._session) return;

    function exec() {
        ChromeCalendar.followTarget = undefined;
        ChromeCalendar._listener = undefined;
        ChromeCalendar.$ctn.remove();
    }

    if (document.body) exec();
    else absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].documentReady.then(exec);

};


/* harmony default export */ __webpack_exports__["a"] = (ChromeCalendar);

/***/ }),
/* 33 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
var EmojiAnims = [
    [
        "(heart)",
        "heart.png",
        "Heart"
    ],
    [
        "(cool)",
        "cool.png",
        "Cool"
    ],
    [
        "(hearteyes)",
        "hearteyes.png",
        "Heart eyes"
    ],
    [
        "(stareyes)",
        "stareyes.png",
        "Star eyes"
    ],
    [
        "(like)",
        "like.png",
        "Like"
    ],
    [
        "(unamused)",
        "unamused.png",
        "Unamused"
    ],
    [
        "(cwl)",
        "cwl.png",
        "Crying with laughter"
    ],
    [
        "(xd)",
        "xd.png",
        "XD smiley"
    ],
    [
        ":)",
        "smile.png",
        "Smile"
    ],
    [
        ":(",
        "sad.png",
        "Sad"
    ],
    [
        ":D",
        "laugh.png",
        "Laugh"
    ],
    [
        ":O",
        "surprised.png",
        "Surprised"
    ],
    [
        ";)",
        "wink.png",
        "Wink"
    ],
    [
        ";(",
        "cry.png",
        "Crying"
    ],
    [
        "(shivering)",
        "shivering.png",
        "Cold shivering"
    ],
    [
        "(:|",
        "sweat.png",
        "Sweating"
    ],
    [
        ":|",
        "speechless.png",
        "Speechless"
    ],
    [
        ":P",
        "tongueout.png",
        "Cheeky"
    ],
    [
        ":$",
        "blush.png",
        "Blushing"
    ],
    [
        "(inlove)",
        "inlove.png",
        "In love"
    ],
    [
        "(kiss)",
        "kiss.png",
        "Kiss"
    ],
    [
        ":^)",
        "wonder.png",
        "Wondering"
    ],
    [
        "|-)",
        "sleepy.png",
        "Sleepy"
    ],
    [
        "|-(",
        "dull.png",
        "Dull"
    ],
    [
        "(yawn)",
        "yawn.png",
        "Yawn"
    ],
    [
        "(puke)",
        "puke.png",
        "Vomiting"
    ],
    [
        "(doh)",
        "doh.png",
        "Doh!"
    ],
    [
        "(angry)",
        "angry.png",
        "Angry"
    ],
    [
        "(wasntme)",
        "wasntme.png",
        "It wasn't me!"
    ],
    [
        "(worry)",
        "worry.png",
        "Worried"
    ],
    [
        "(mm)",
        "mmm.png",
        "Mmmmm…"
    ],
    [
        "(nerd)",
        "nerdy.png",
        "Nerdy"
    ],
    [
        "(rainbowsmile)",
        "rainbowsmile.png",
        "Rainbow smile"
    ],
    [
        ":x",
        "lipssealed.png",
        "My lips are sealed"
    ],
    [
        "(devil)",
        "devil.png",
        "Devil"
    ],
    [
        "(angel)",
        "angel.png",
        "Angel"
    ],
    [
        "(envy)",
        "envy.png",
        "Envy"
    ],
    [
        "(makeup)",
        "makeup.png",
        "Make-up"
    ],
    [
        "(think)",
        "think.png",
        "Thinking"
    ],
    [
        "(rofl)",
        "rofl.png",
        "Rolling on the floor laughing"
    ],
    [
        "(happy)",
        "happy.png",
        "Happy"
    ],
    [
        "(smirk)",
        "smirk.png",
        "Smirking"
    ],
    [
        "(nod)",
        "nod.png",
        "Nodding"
    ],
    [
        "(shake)",
        "shake.png",
        "Shake"
    ],
    [
        "(waiting)",
        "waiting.png",
        "Waiting"
    ],
    [
        "(emo)",
        "emo.png",
        "Emo"
    ],
    [
        "(donttalk)",
        "donttalktome.png",
        "Don't talk to me"
    ],
    [
        "(idea)",
        "idea.png",
        "Idea"
    ],
    [
        "(talk)",
        "talk.png",
        "Talking"
    ],
    [
        "(swear)",
        "swear.png",
        "Swearing"
    ],
    [
        "]:)",
        "evilgrin.png",
        "Evil grin"
    ],
    [
        "(headbang)",
        "headbang.png",
        "Banging head on wall"
    ],
    [
        "(learn)",
        "learn.png",
        "Global Learning"
    ],
    [
        "(headphones)",
        "headphones.png",
        "Listening to headphones"
    ],
    [
        "(morningafter)",
        "hungover.png",
        "Morning after party"
    ],
    [
        "(selfie)",
        "selfie.png",
        "Selfie"
    ],
    [
        "(shock)",
        "shock.png",
        "Spoiler alert"
    ],
    [
        "(llsshock)",
        "llsshock.png",
        "Spoiler alert"
    ],
    [
        "(ttm)",
        "ttm.png",
        "Talking too much"
    ],
    [
        "(dream)",
        "dream.png",
        "Dreaming"
    ],
    [
        "(ill)",
        "ill.png",
        "Ill"
    ],
    [
        "(tired)",
        "tired.png",
        "Tired"
    ],
    [
        "(party)",
        "party.png",
        "Party"
    ],
    [
        "(bandit)",
        "bandit.png",
        "Bandit"
    ],
    [
        "(tauri)",
        "tauri.png",
        "Bald man with glasses"
    ],
    [
        "(nazar)",
        "nazar.png",
        "Blessing"
    ],
    [
        "(movember)",
        "movember.png",
        "Movember"
    ],
    [
        "(mysteryskype)",
        "mysteryskype.png",
        "Mystery Skype"
    ],
    [
        "(dotdfemale)",
        "dotdfemale.png",
        "Day of the dead"
    ],
    [
        "(dotdmale)",
        "dotdmale.png",
        "Day of the dead"
    ],
    [
        "(selfiediwali)",
        "selfiediwali.png",
        "Selfie Diwali"
    ],
    [
        "(diwaliselfie)",
        "diwaliselfie.png",
        "Diwali selfie"
    ],
    [
        "(steveaoki)",
        "steveaoki.png",
        "Steve Aoki"
    ],
    [
        "(aokijump)",
        "aokijump.png",
        "Aoki jump"
    ],
    [
        "(cakethrow)",
        "cakethrow.png",
        "Cake throw"
    ],
    [
        "(kolony)",
        "kolony.png",
        "Kolony"
    ],
    [
        "(joy)",
        "joy.png",
        "Joy"
    ],
    [
        "(anger)",
        "anger.png",
        "Anger"
    ],
    [
        "(sadness)",
        "sadness.png",
        "Sadness"
    ],
    [
        "(disgust)",
        "disgust.png",
        "Disgust"
    ],
    [
        "(fear)",
        "fear.png",
        "Fear"
    ],
    [
        "(hestonfacepalm)",
        "hestonfacepalm.png",
        "Heston facepalm"
    ],
    [
        "(heston)",
        "heston.png",
        "Heston Blumenthal"
    ],
    [
        "(stormtrooper)",
        "stormtrooper.png",
        "Storm trooper"
    ],
    [
        "(kyloren)",
        "kyloren.png",
        "Kylo Ren"
    ],
    [
        "(captainphasma)",
        "captainphasma.png",
        "Captain Phasma"
    ],
    [
        "(malthe)",
        "malthe.png",
        "Smiling man with glasses"
    ],
    [
        "(ladyvamp)",
        "ladyvampire.png",
        "Lady vampire"
    ],
    [
        "(vampire)",
        "vampire.png",
        "Vampire"
    ],
    [
        "(ghost)",
        "ghost.png",
        "Ghost"
    ],
    [
        "(skull)",
        "skull.png",
        "Skull"
    ],
    [
        "(pumpkin)",
        "pumpkin.png",
        "Pumpkin"
    ],
    [
        "(santa)",
        "santa.png",
        "Santa"
    ],
    [
        "(xmascwl)",
        "xmascwl.png",
        "Xmas crying with laughter"
    ],
    [
        "(festiveparty)",
        "festiveparty.png",
        "Festive party"
    ],
    [
        "(holidayspirit)",
        "holidayspirit.png",
        "Holiday spirit"
    ],
    [
        "(rudolfsurprise)",
        "rudolfsurprise.png",
        "Surprised Rudolf"
    ],
    [
        "(rudolfidea)",
        "rudolfidea.png",
        "Rudolf idea"
    ],
    [
        "(wtf)",
        "wtf.png",
        "WTF…"
    ],
    [
        "(smoking)",
        "smoke.png",
        "Smoking"
    ],
    [
        "(drunk)",
        "drunk.png",
        "Drunk"
    ],
    [
        "(finger)",
        "finger.png",
        "Finger"
    ],
    [
        "(oliver)",
        "oliver.png",
        "Man saying come on"
    ],
    [
        "(xmassarcastic)",
        "xmassarcastic.png",
        "Xmas sarcastic"
    ],
    [
        "(xmascry)",
        "xmascry.png",
        "Xmas cry"
    ],
    [
        "(wave)",
        "hi.png",
        "Hi"
    ],
    [
        "(highfive)",
        "highfive.png",
        "High five"
    ],
    [
        "(clap)",
        "clap.png",
        "Clapping"
    ],
    [
        "(sarcastic)",
        "sarcastic.png",
        "Sarcastic"
    ],
    [
        "(chuckle)",
        "giggle.png",
        "Giggle"
    ],
    [
        "(facepalm)",
        "facepalm.png",
        "Facepalm"
    ],
    [
        "(rock)",
        "rock.png",
        "Rock"
    ],
    [
        "(yn)",
        "fingerscrossed.png",
        "Fingers crossed"
    ],
    [
        "(listening)",
        "listening.png",
        "Listening"
    ],
    [
        "(wait)",
        "wait.png",
        "Wait"
    ],
    [
        "(whew)",
        "whew.png",
        "Relieved"
    ],
    [
        "(tmi)",
        "tmi.png",
        "Too much information"
    ],
    [
        "(call)",
        "call.png",
        "Call"
    ],
    [
        "(punch)",
        "punch.png",
        "Punch"
    ],
    [
        "(talktothehand)",
        "talktothehand.png",
        "Talk to the hand"
    ],
    [
        "(whistle)",
        "whistle.png",
        "Whistle"
    ],
    [
        "(slap)",
        "slap.png",
        "Slap"
    ],
    [
        "(lalala)",
        "lalala.png",
        "Lalala"
    ],
    [
        "(y)",
        "yes.png",
        "Yes"
    ],
    [
        "(n)",
        "no.png",
        "No"
    ],
    [
        "(handshake)",
        "handshake.png",
        "Handshake"
    ],
    [
        "(fistbump)",
        "fistbump.png",
        "Fist bump"
    ],
    [
        "(poke)",
        "poke.png",
        "Poke"
    ],
    [
        "(celebrate)",
        "handsinair.png",
        "Hands celebrating"
    ],
    [
        "(hearthands)",
        "hearthands.png",
        "Heart hands"
    ],
    [
        "(victory)",
        "victory.png",
        "Victory sign"
    ],
    [
        "(noworries)",
        "noworries.png",
        "No worries"
    ],
    [
        "(ok)",
        "ok.png",
        "OK"
    ],
    [
        "(pray)",
        "praying.png",
        "Praying"
    ],
    [
        "(flex)",
        "muscle.png",
        "Muscle"
    ],
    [
        "(ek)",
        "naturescall.png",
        "Nature's call"
    ],
    [
        "(woty)",
        "woty.png",
        "Woman of the year"
    ],
    [
        "(glassceiling)",
        "glassceiling.png",
        "Glass ceiling"
    ],
    [
        "(deadyes)",
        "deadyes.png",
        "Dead yes"
    ],
    [
        "(xmasyes)",
        "xmasyes.png",
        "Xmas yes"
    ],
    [
        "(dropthemic)",
        "dropthemic.png",
        "Drop the mic"
    ]
];

/* harmony default export */ __webpack_exports__["a"] = (EmojiAnims);

/***/ }),
/* 34 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_multiselectmenu_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(257);
/* harmony import */ var _css_multiselectmenu_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_multiselectmenu_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var _SelectMenu2__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(21);
/* harmony import */ var absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(3);
/* harmony import */ var _PositionTracker__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(50);
/* harmony import */ var _SelectBoxItem__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(42);
/* harmony import */ var _SelectListBox__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(19);
/* harmony import */ var absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(2);
/* harmony import */ var absol_src_HTML5_ResizeSystem__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(11);
/* harmony import */ var _SelectBox__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(68);












var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;


/***
 * @augments SelectBox
 * @augments PositionTracker
 * @constructor
 */
function MultiSelectMenu() {
    this.on('click', this.eventHandler.click);
    /***
     *
     * @type {SelectListBox}
     */
    this.$selectlistBox = _({
        tag: 'selectlistbox',
        props: {
            anchor: [1, 6, 2, 5],
            displayValue: _SelectListBox__WEBPACK_IMPORTED_MODULE_6__[/* VALUE_HIDDEN */ "a"]
        },
        on: {
            preupdateposition: this.eventHandler.preUpdateListPosition,
            pressitem: this.eventHandler.selectListBoxPressItem
        }
    });

    this.$itemCtn = $('.as-multi-select-menu-item-ctn', this);
    this.$attachhook = $('attachhook', this)
        .on('attached', this.eventHandler.attached);

    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_7__[/* default */ "a"].drillProperty(this, this.$selectlistBox, 'enableSearch');
    this.$items = [];
    this._values = [];
    this.items = [];
    this.values = [];
    this.$selectlistBox.followTarget = this;
    this.disableClickToFocus = false;
    this.orderly = true;
    this.itemFocusable = false;
    this._activeValue = undefined;
    this.strictValue = true;
}

MultiSelectMenu.tag = 'MultiSelectMenu'.toLowerCase();
MultiSelectMenu.render = function () {
    return _({
        class: ['as-multi-select-menu'],
        extendEvent: ['change', 'add', 'remove', 'activevaluechange'],
        attr: {
            tabindex: '1'
        },
        child: [
            {
                class: ['as-multi-select-menu-item-ctn', 'as-bscroller']
            },
            {
                tag: 'button',
                class: 'as-multi-select-menu-toggle-btn',
                child: 'dropdown-ico'
            },
            'attachhook'
        ]
    });
};


MultiSelectMenu.prototype._requireItem = function (n) {
    var itemElt;
    while (this.$items.length < n) {
        itemElt = Object(_SelectBox__WEBPACK_IMPORTED_MODULE_9__[/* requireItem */ "c"])(this);
        this.$itemCtn.addChild(itemElt);
        this.$items.push(itemElt);
    }

    while (this.$items.length > n) {
        itemElt = this.$items.pop();
        this.$itemCtn.removeChild(itemElt);
        Object(_SelectBox__WEBPACK_IMPORTED_MODULE_9__[/* releaseItem */ "b"])(itemElt);
    }
};


MultiSelectMenu.prototype._assignItems = function (items) {
    for (var i = 0; i < this.$items.length && i < items.length; ++i) {
        this.$items[i].data = items[i];
    }
};

/***
 *
 * @param {string[] | number[]} values
 * @private
 */
MultiSelectMenu.prototype._getItemsByValues = function (values) {
    var selectListBoxElt = this.$selectlistBox;
    var itemHolders = values.reduce(function (ac, cr) {
        ac.push.apply(ac, selectListBoxElt.findItemsByValue(cr));
        return ac;
    }, []);
    if (this.orderly) {
        if (typeof this.orderly === 'function') {
            itemHolders.sort(this.orderly);
        }
        else {
            itemHolders.sort(function (a, b) {
                return a.idx - b.idx;
            });
        }
    }

    return itemHolders.map(function (holder) {
        return holder.item;
    })

};


MultiSelectMenu.prototype._updateItems = function () {
    this.viewItemsByValues(this._values);
};

MultiSelectMenu.prototype.viewItemsByValues = function (values) {
    var cBound = this.getBoundingClientRect();
    var items = this._getItemsByValues(values);
    this._requireItem(items.length);
    this._assignItems(items);
    if (this.itemFocusable) {
        this._updateFocusItem();
    }
    var nBound = this.getBoundingClientRect();
    if (nBound.width != cBound.width || nBound.height != cBound.height) {
        absol_src_HTML5_ResizeSystem__WEBPACK_IMPORTED_MODULE_8__[/* default */ "a"].updateUp(this);
    }
};


MultiSelectMenu.property = {};
MultiSelectMenu.property.disabled = _SelectMenu2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].property.disabled;
MultiSelectMenu.property.hidden = _SelectMenu2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].property.hidden;
MultiSelectMenu.property.isFocus = _SelectMenu2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].property.isFocus;


MultiSelectMenu.prototype.init = function (props) {
    props = props || [];
    Object.keys(props).forEach(function (key) {
        if (props[key] === undefined) delete props[key];
    });
    this.super(props);
};

MultiSelectMenu.prototype._updateFocusItem = function () {
    for (var i = 0; i < this.$items.length; ++i) {
        this.$items[i].active = this.$items[i].value == this._activeValue;
    }
};


MultiSelectMenu.prototype.init = _SelectMenu2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].prototype.init;

MultiSelectMenu.prototype._implicit = function (values) {
    if (values === null || values === undefined) values = [];
    if (!(values instanceof Array)) {
        values = [values];
    }
    values = values.filter(function (value) {
        var type = typeof value;
        return type === 'string' || type === 'number' || type === "boolean" || value === null || value === undefined;
    }).reduce(function (ac, cr) {
        if (!ac.dict[cr]) {
            ac.dict[cr] = true;
            ac.result.push(cr);
        }
        return ac;
    }, { result: [], dict: {} }).result;

    return values;
};

MultiSelectMenu.prototype._explicit = function (values) {
    var selectListBoxElt = this.$selectlistBox;
    var strictValue = this.strictValue;
    values = values.filter(function (value) {
        return !strictValue || selectListBoxElt.findItemsByValue(value).length > 0;
    })
    return values;
};


MultiSelectMenu.property.items = {
    set: function (items) {
        items = items || [];
        this.$selectlistBox.items = items;
        this.addStyle('--list-min-width', this.$selectlistBox._estimateWidth + 'px');
        this._updateItems();
    },
    get: function () {
        return this.$selectlistBox.items
    }
};

MultiSelectMenu.property.values = {
    set: function (values) {
        values = this._implicit(values);
        this._values = values;
        this.$selectlistBox.values = values;
        this._updateItems();
    },
    get: function () {
        return this._explicit(this._values);
    }
};

MultiSelectMenu.property.orderly = {
    set: function (value) {
        var needUpdate = this._orderly === this._orderly;
        if (typeof value === 'function') {
            this._orderly;
        }
        else
            this._orderly = !!value;
        if (needUpdate) {
            this.values = this.values;
        }
    },
    get: function () {
        return !!this._orderly;
    }
};

MultiSelectMenu.property.disableClickToFocus = {
    set: function (value) {
        if (value) {
            this.addClass('as-disable-click-to-focus');
        } else {
            this.removeClass('as-disable-click-to-focus');
        }
    },
    get: function () {
        return this.containsClass('as-disable-click-to-focus');
    }
};

MultiSelectMenu.property.itemFocusable = {
    set: function (value) {
        if (value) {
            this.addClass('as-item-focusable');
        } else {
            this.removeClass('as-item-focusable');
        }
        this._updateFocusItem();
    },
    get: function () {
        return this.containsClass('as-item-focusable');
    }
};

MultiSelectMenu.property.activeValue = {
    set: function (value) {
        this._activeValue = value;
        if (this.itemFocusable) {
            this._updateFocusItem();
            //todo
        }
    },
    get: function () {
        return this._activeValue;
    }
};

MultiSelectMenu.property.strictValue = {
    set: function (value) {
        if (value){
            this.attr('data-strict-value', null);
        }
        else {
            this.attr('data-strict-value', 'false');
        }
    },
    get: function () {
        var data = this.attr('data-strict-value');
        return !data || (data != 'false' && data !== '0');
    }
};


MultiSelectMenu.eventHandler = Object.assign({}, _SelectMenu2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].eventHandler);

MultiSelectMenu.eventHandler.attached = function () {
    var maxHeightStyle = this.getComputedStyleValue('max-height') || 'none';
    if (maxHeightStyle.match(/[0-9-]+px/)) {
        this.addStyle('--multi-select-menu-max-height', maxHeightStyle);
        this.addStyle('max-height', 'unset');
    }
    else if (maxHeightStyle !== 'none') {
        console.warn('Can not adapt max-height:', maxHeightStyle);
    }
};


MultiSelectMenu.eventHandler.click = function (event) {
    if ((event.target === this || event.target === this.$itemCtn) && !this.disableClickToFocus) {
        this.isFocus = !this.isFocus;
    }
};


MultiSelectMenu.eventHandler.bodyClick = function (event) {
    if (!absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_3__[/* default */ "b"].hitElement(this.$selectlistBox, event) && event.target !== this && event.target !== this.$itemCtn) {
        this.isFocus = false;
    }
};


MultiSelectMenu.eventHandler.selectListBoxPressItem = function (event) {
    var data = event.data;
    var currentValues = this.$selectlistBox.values;
    currentValues.push(data.value);
    this.$selectlistBox.values = currentValues;
    this.$selectlistBox.updatePosition();
    this._values = currentValues.slice();
    this._activeValue = data.value;
    this._updateItems();
    this.isFocus = false;
    this.emit('add', Object.assign({}, event, {
        type: 'add',
        target: this,
        value: data.value,
        data: data,
        itemData: data
    }), this);
    this.emit('change', Object.assign({}, event, {
        type: 'change',
        action: 'add',
        target: this,
        value: data.value,
        data: data,
        values: this.values
    }), this);
};


MultiSelectMenu.eventHandler.pressItem = function (item, event) {
    var value = item.value;
    if (this.itemFocusable) {
        var prevActiveValue = this.activeValue;
        if (value !== prevActiveValue) {

            this.activeValue = value;
            this.emit('activevaluechange', {
                target: this,
                originEvent: event,
                prevActiveValue: prevActiveValue,
                activeValue: value
            }, this);
        }
    }
};


MultiSelectMenu.eventHandler.pressCloseItem = function (item, event) {
    var value = item.value;
    var data = item.data;
    var index;
    index = this._values.indexOf(value);
    if (index >= 0) {
        this._values.splice(index, 1);
        this._updateItems();
        this.$selectlistBox.values = this._values;
        this.emit('remove', Object.assign({}, event, {
            type: 'change',
            target: this,
            data: data,
            value: value,
            itemData: data
        }), this);
        this.emit('change', Object.assign({}, event, {
            type: 'change',
            action: 'remove',
            target: this,
            data: data,
            value: value,
            itemData: data
        }), this);
    }
};

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(MultiSelectMenu);

/* harmony default export */ __webpack_exports__["a"] = (MultiSelectMenu);

/***/ }),
/* 35 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_toast_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(260);
/* harmony import */ var _css_toast_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_toast_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2);
/* harmony import */ var absol_src_HTML5_Element__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(24);
/* harmony import */ var _VariantColors__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(54);
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(4);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(1);
/* harmony import */ var absol_src_Color_Color__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(57);










var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;
var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;

var toastBg = {
    success: "#a4f3b6",
    info: "#67d5e7"
}

var toastTextColor = {
    success: '#454040',
    info: '#48433b'
}

Object(_utils__WEBPACK_IMPORTED_MODULE_5__["buildCss"])(_VariantColors__WEBPACK_IMPORTED_MODULE_4__[/* default */ "a"].keys.reduce(function (ac, cr) {
    var color = absol_src_Color_Color__WEBPACK_IMPORTED_MODULE_7__[/* default */ "a"].parse(toastBg[cr] || _VariantColors__WEBPACK_IMPORTED_MODULE_4__[/* default */ "a"].base[cr]);
    var textColor = color.getContrastYIQ();
    var headerColor = toastTextColor[cr] || _VariantColors__WEBPACK_IMPORTED_MODULE_4__[/* default */ "a"].mediumContract[cr] || color.getHightContrastColor();
    ac['.as-toast.as-variant-' + cr + ' .as-toast-variant-color'] = {
        'background-color': color.toString('hex6')
    }
    ac['.as-toast.as-variant-background.as-variant-' + cr] = {
        'background-color': color.toString('hex6'),
        color: textColor.toString('hex6')
    }

    ac['.as-toast.as-variant-background.as-variant-' + cr + ' .as-toast-header'] = {
        color: headerColor.toString('hex6')
    }

    return ac;
}, {}));


/***
 * @extends {AElement}
 * @constructor
 */
function Toast() {
    this._state = 0;
    this.$closeBtn = $('.as-toast-close-btn', this)
        .on('click', this.disappear.bind(this));
    this.$title = $('.as-toast-title', this);
    this.$timeText = $('.as-toast-time-text', this);
    this.$body = $('.toast-body', this);
    this.$attachhook = $('attachhook', this)
        .on('attached', this.appear.bind(this));
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].drillProperty(this, this.$title.firstChild, 'htitle', 'data');
    this._message = null;
    this.$message = null;
    this.disappearTimeout = 0;
    this.htitle = 'Toast.htitle';
    this.timeText = new Date();
    this.message = null;
    this.variant = null;
}

Toast.tag = 'toast';

['addChild', 'removeChild', 'clearChild', 'addChildBefore', 'addChildAfter'].forEach(function (key) {
    Toast.prototype[key] = function () {
        this.$body[key].apply(this.$body, arguments);
    };
});

Toast.render = function () {
    return _({
        extendEvent: ['appeared', 'disappeared'],
        class: ['as-toast', 'as-not-appeared'],
        child: [
            {
                class: 'as-toast-header',
                child: [
                    '.as-toast-variant-color',
                    {
                        tag: 'strong',
                        class: 'as-toast-title',
                        child: { text: "Absol Js" }
                    },
                    {
                        tag: 'smal',
                        class: 'as-toast-time-text',
                        child: { text: '20 mis ago' }
                    },
                    {
                        tag: 'button',
                        class: 'as-toast-close-btn',
                        child: { tag: 'span', child: { text: '×' } }
                    }
                ]
            },
            {
                class: 'toast-body'
            },
            'attachhook'
        ]
    });
};

Toast.prototype.disappear = function () {
    if (this._state !== 2) return;
    this._state = 3;
    this.addClass('as-disappearing');
    setTimeout(function () {
        this.removeClass('as-disappeared')
            .removeClass('as-disappearing')
            .addClass('as-not-appeared');
        this.remove();
        this.emit('disappeared', { target: this, type: 'disappeared' }, this);
    }.bind(this), 500);
};

Toast.prototype.appear = function () {
    if (this._state !== 0) return;
    this._state = 1;
    this.addClass('as-appearing');
    setTimeout(function () {
        this.removeClass('as-not-appeared')
            .addClass('as-appeared')
            .removeClass('as-appearing');
        this._state = 2;
        this.emit('appeared', { target: this, type: 'appeared' }, this);
        if (this.disappearTimeout > 0 && this.disappearTimeout < Infinity) {
            setTimeout(this.disappear.bind(this), this.disappearTimeout);
        }
    }.bind(this), 100);
};


Toast.property = {};

Toast.property.variant = {
    set: function (value) {
        if (this._variant && this._variant !== value) {
            this.removeClass('as-variant-' + this._variant);
        }
        if (_VariantColors__WEBPACK_IMPORTED_MODULE_4__[/* default */ "a"].has(value) || (['sticky-note'].indexOf(value) >= 0)) {
            this._variant = value;
            this.addClass('as-variant-' + this._variant);
        }
    },
    get: function () {
        return this._variant;
    }
};

Toast.property.message = {
    set: function (value) {
        if (typeof value !== "string" || value.length === 0) {
            value = null;
        }
        if (value) {
            if (!this.$message) {
                this.$message = _({
                    class: 'as-toast-message',
                    child: { text: '' }
                });
            }
            if (!this.$message.parentElement)
                this.$body.addChild(this.$message);
            this.$message.firstChild.data = value;
        }
        else {
            if (this.$message && this.$message.parentElement) {
                this.$message.remove();
            }
        }
        this._message = value;
    },
    get: function () {
        return this._message;
    }
};


Toast.property.timeText = {
    set: function (value) {
        if (value instanceof Date) {
            value = value.toLocaleTimeString();

        }
        else {
            value = value + '';
        }
        this.$timeText.firstChild.data = value;

    },
    get: function () {
        return this.$timeText.firstChild.data;
    }
};

Toast.$toastList = _('.as-toast-list.as-se.as-bscroller');
Toast.$toastList4Pos = {
    se: Toast.$toastList,
    sw: _('.as-toast-list.as-sw.as-bscroller'),
    nw: _('.as-toast-list.as-nw.as-bscroller'),
    ne: _('.as-toast-list.as-ne.as-bscroller'),
};

absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_6__[/* default */ "b"].documentReady.then(function () {
    Toast.$toastList.addTo(document.body);
    Toast.$toastList4Pos.sw.addTo(document.body);
    Toast.$toastList4Pos.nw.addTo(document.body);
    Toast.$toastList4Pos.ne.addTo(document.body);
});

/***
 *
 * @param {AbsolConstructDescriptor|{}} aObject,
 * @param {"se"|"sw"|"ne"|"nw" } [pos="se"]
 * @return {AElementNS|AElement|Text}
 */
Toast.make = function (aObject, pos) {
    pos = pos || 'se';
    aObject = aObject || {};
    if (typeof aObject !== "object") throw  new Error("param must be AbsolConstructDescriptor object!");

    if (Object(absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_6__[/* isDomNode */ "e"])(aObject)) {

    }
    else {
        aObject.tag = aObject.tag || 'toast';

    }
    var toastElt = _(aObject);
    var toastListElt = Toast.$toastList4Pos[pos] || Toast.$toastList;
    toastListElt.addChild(toastElt);
    return toastElt;
};


_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(Toast);

/* harmony default export */ __webpack_exports__["a"] = (Toast);



/***/ }),
/* 36 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
// ESM COMPAT FLAG
__webpack_require__.r(__webpack_exports__);

// EXPORTS
__webpack_require__.d(__webpack_exports__, "blobToFile", function() { return /* binding */ blobToFile; });
__webpack_require__.d(__webpack_exports__, "dataURItoBlob", function() { return /* binding */ dataURItoBlob; });
__webpack_require__.d(__webpack_exports__, "blobToArrayBuffer", function() { return /* binding */ blobToArrayBuffer; });
__webpack_require__.d(__webpack_exports__, "stringToBlob", function() { return /* binding */ stringToBlob; });

// CONCATENATED MODULE: ./node_modules/absol/src/Converter/ext2MineType.js
var ext2MineType = {
    aac: "audio/aac",
    abw: "application/x-abiword",
    arc: "application/x-freearc",
    avi: "video/x-msvideo",
    azw: "application/vnd.amazon.ebook",
    bin: "application/octet-stream",
    bmp: "image/bmp",
    bz: "application/x-bzip",
    bz2: "application/x-bzip2",
    cda: "application/x-cdf",
    csh: "application/x-csh",
    css: "text/css",
    csv: "text/csv",
    doc: "application/msword",
    docx: "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
    eot: "application/vnd.ms-fontobject",
    epub: "application/epub+zip",
    gz: "application/gzip",
    gif: "image/gif",
    htm: "text/html",
    html: "text/html",
    ico: "image/vnd.microsoft.icon",
    ics: "text/calendar",
    jar: "application/java-archive",
    jpeg: "image/jpeg",
    js: "text/javascript",
    json: "application/json",
    jsonld: "application/ld+json",
    mid: "audio/midi",
    mjs: "text/javascript",
    mp3: "audio/mpeg",
    mp4: "video/mp4",
    mpeg: "video/mpeg",
    mpkg: "application/vnd.apple.installer+xml",
    odp: "application/vnd.oasis.opendocument.presentation",
    ods: "application/vnd.oasis.opendocument.spreadsheet",
    odt: "application/vnd.oasis.opendocument.text",
    oga: "audio/ogg",
    ogv: "video/ogg",
    ogx: "application/ogg",
    opus: "audio/opus",
    otf: "font/otf",
    png: "image/png",
    pdf: "application/pdf",
    php: "application/x-httpd-php",
    ppt: "application/vnd.ms-powerpoint",
    pptx: "application/vnd.openxmlformats-officedocument.presentationml.presentation",
    rar: "application/vnd.rar",
    rtf: "application/rtf",
    sh: "application/x-sh",
    svg: "image/svg+xml",
    swf: "application/x-shockwave-flash",
    tar: "application/x-tar",
    tif: "image/tiff",
    tiff: "image/tiff",
    ts: "video/mp2t",
    ttf: "font/ttf",
    txt: "text/plain",
    vsd: "application/vnd.visio",
    wav: "audio/wav",
    weba: "audio/webm",
    webm: "video/webm",
    webp: "image/webp",
    woff: "font/woff",
    woff2: "font/woff2",
    xhtml: "application/xhtml+xml",
    xls: "application/vnd.ms-excel",
    xlsx: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
    xml: "application/xml",
    xul: "application/vnd.mozilla.xul+xml",
    zip: "application/zip",
    "3gp": "video/3gpp",
    "3g2": "video/3gpp2",
    "7z": "application/x-7z-compressed"
};

/* harmony default export */ var Converter_ext2MineType = (ext2MineType);
// CONCATENATED MODULE: ./node_modules/absol/src/Converter/file.js


function blobToFile(theBlob, fileName) {
    return new File([theBlob], fileName);
}

function dataURItoBlob(dataURI) {
    var byteString = atob(dataURI.split(',')[1]);
    var mimeString = dataURI.split(',')[0].split(':')[1].split(';')[0];
    var ab = new ArrayBuffer(byteString.length);
    var ia = new Uint8Array(ab);
    for (var i = 0; i < byteString.length; i++) {
        ia[i] = byteString.charCodeAt(i);
    }
    var blob = new Blob([ab], { type: mimeString });
    return blob;

}

function blobToArrayBuffer(blob) {
    var fileReader = new FileReader();
    return new Promise(function (rs) {
        fileReader.onload = function (event) {
            var arrayBuffer = event.target.result;
            rs(arrayBuffer);
        };
        fileReader.readAsArrayBuffer(blob);
    });
}

function stringToBlob(text, type) {
    type = type || 'text/plain';
    var mineTye = type.split('/').length === 2 ? type : (Converter_ext2MineType[type] || 'text/plain');
    return new Blob([text], {
        type: mineTye
    });
}

/***/ }),
/* 37 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";

// EXPORTS
__webpack_require__.d(__webpack_exports__, "c", function() { return /* binding */ parseMessage; });
__webpack_require__.d(__webpack_exports__, "a", function() { return /* binding */ MessageQuote; });

// UNUSED EXPORTS: MODE_NEW, MODE_EDIT, prepareIcon, MessageInputPlugin

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/messageinput.css
var messageinput = __webpack_require__(177);

// EXTERNAL MODULE: ./node_modules/absol-acomp/ACore.js
var ACore = __webpack_require__(0);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/EventEmitter.js
var EventEmitter = __webpack_require__(3);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/utils.js
var utils = __webpack_require__(4);

// EXTERNAL MODULE: ./node_modules/absol/src/Network/XHR.js
var XHR = __webpack_require__(59);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/EmojiAnims.js
var EmojiAnims = __webpack_require__(33);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/EmojiPicker.js
var EmojiPicker = __webpack_require__(38);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/AElement.js
var AElement = __webpack_require__(8);

// EXTERNAL MODULE: ./node_modules/absol/src/Detector/BrowserDetector.js
var BrowserDetector = __webpack_require__(10);

// EXTERNAL MODULE: ./node_modules/absol/src/String/stringGenerate.js + 1 modules
var stringGenerate = __webpack_require__(12);

// EXTERNAL MODULE: ./node_modules/absol/src/AppPattern/CMDRunner.js
var CMDRunner = __webpack_require__(60);

// CONCATENATED MODULE: ./node_modules/absol/src/Input/keyboard.js
function isFnKey(name) {
    return name.match(/^[fF]([2-9]|(1([0-2]?)))$/)
}

function isSpaceKey(name) {
    return name === ' ' || name.match(/^[sS]pace$/);
}

function isCtrlKey(name) {
    return name.match(/(^([cC]ontrol)|ctrl)$/);
}

function isAltKey(name) {
    return name.match(/^[aA]lt$/);
}

function isShiftKey(name) {
    return name.match(/^[sS]hift$/);
}

function isMetaKey(name) {
    return name.toLowerCase().match(/^(command|windows|meta)$/);
}

/***
 *
 * @param {string} text
 * @return {string}
 */
function normalizeKeyBindingIdent(text) {
    var keys = text.trim().toLowerCase().split(/[-+\s_.]+/)
        .filter(function (w) {
            return w.length > 0;
        });
    var values = {
        meta: 1,
        ctrl: 2,
        alt: 3,
        shift: 4
    };
    keys.sort(function (a, b) {
        var va, vb;
        va = values[a] || 100;
        vb = values[b] || 100;
        return va - vb;
    });
    return keys.join('-');
}

/***
 *
 * @param {KeyboardEvent} event
 * @return {string}
 */
function keyboardEventToKeyBindingIdent(event) {
    var keys = [];
    if (event.metaKey) {
        keys.push('meta');
    }
    if (event.ctrlKey)
        keys.push('ctrl');
    if (event.altKey)
        keys.push('alt');
    if (event.shiftKey)
        keys.push('shift');

    if (isSpaceKey(event.key)) {
        keys.push('space');
    }
    else if (isFnKey(event.key)) {
        keys.push(event.key.toLowerCase())
    }
    else if (!isMetaKey(event.key) && !isAltKey(event.key) && !isCtrlKey(event.key) && !isShiftKey(event.key))
        keys.push(event.key.toLowerCase());
    return keys.join('-');
}
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/MessageInput.js













var _ = ACore["d" /* default */]._;
var $ = ACore["d" /* default */].$;
var $$ = ACore["d" /* default */].$$;


/***
 *
 * @typedef {{text:string, desc: string, img?:string, file?:string}|string} MessageInputQuote
 */

var iconCatalogCaches = {};

var MODE_NEW = 0;
var MODE_EDIT = 1;

var isMobile = BrowserDetector["a" /* default */].isMobile;

/***
 * @extends AElement
 * @constructor
 */
function MessageInput() {
    this._cmdRunner = new CMDRunner["a" /* default */](this);
    this._keyMaps = {};
    this._plugins = [];
    this._mode = MODE_NEW;//edit
    this._editingText = "";
    prepareIcon();
    /**
     * @type {import('./PreInput').default}
     */
    this.$preInput = $('preinput', this);


    this.$preInput.on('change', this.eventHandler.preInputChange)
        .on('keyup', this.eventHandler.preInputKeyUp)
        .on('keydown', this.eventHandler.preInputKeyDown)
        .on('pasteimg', this.eventHandler.preInputPasteImg)
        .on('focus', this.eventHandler.preInputFocus)
        .on('blur', this.eventHandler.preInputBlur);
    // //every can make size change
    this._imageFiles = [];
    this._files = [];


    this._latBound = {};

    this.$quote = $('messagequote.as-message-input-quote', this)
        .on('pressremove', this.eventHandler.clickQuoteRemoveBtn);

    this.$right = $('.as-message-input-right', this);

    this.$attachmentCtn = $('.as-message-input-attachment-ctn', this);
    this.$emojiBtn = $('.as-message-input-plugin-emoji', this)
        .on('click', this.eventHandler.clickEmojiBtn);
    this.$fileBtn = $('.as-message-input-plugin-file', this)
        .on('click', this.openFileDialog.bind(this));
    this.$attachmentAddBtn = $('.as-message-input-attachment-add-btn', this)
        .on('click', this.openFileDialog.bind(this));
    this.$sendBtn = $('.as-message-input-plugin-send', this)
        .on('click', this.notifySend.bind(this));

    this.$cancelBtn = $('.as-message-input-plugin-cancel', this)
        .on('click', this.notifyCancel.bind(this));

    this.$emojiPickerCtn = _('.as-message-input-external-tools-popup');
    this.$emojiPicker = _('emojipicker').addTo(this.$emojiPickerCtn)
        .on('pick', this.eventHandler.pickEmoji);


    this.$attachhook = _('attachhook').addTo(this).on('error', this.notifySizeChange.bind(this));


    this.on('drop', this.eventHandler.drop)
        .on('dragover', this.eventHandler.dragover);

    this.autoSend = false;
    /***
     *
     * @type {MessageInputQuote|null}
     */
    this.quote = null;
}

MessageInput.MODE_EDIT = MODE_EDIT;
MessageInput.MODE_NEW = MODE_NEW;

MessageInput.iconAssetRoot = (function () {
    if (location.hostname.match(/^.*(\.?absol\.cf|absol\.ddns\.net)$/) || location.hostname === 'localhost')
        return 'https://absol.cf/exticons/vivid';
    return '/vivid_exticons';
})();

MessageInput.tag = 'MessageInput'.toLowerCase();

MessageInput.render = function (data) {
    data = data || {};
    data.iconAssetRoot = data.iconAssetRoot || MessageInput.iconAssetRoot;
    return _({
        attr: {
            'data-icon-asset-root': MessageInput.iconAssetRoot
        },
        class: 'as-message-input',
        extendEvent: ['sendtext', 'sendimage', 'sendfile', 'sendquote', 'cancel', 'change', 'sizechange', 'send', 'useraddfile'],
        child: [
            {
                class: 'as-message-input-right',
                child: [
                    {
                        tag: 'button',
                        class: ['as-message-input-plugin-btn', 'as-message-input-plugin-file'],
                        child: 'span.mdi.mdi-attachment.mdi-rotate-90'
                    },
                    {
                        tag: 'button',
                        class: ['as-message-input-plugin-btn', 'as-message-input-plugin-send'],
                        child: 'span.mdi.mdi-send'
                    },
                    {
                        tag: 'button',
                        class: ['as-message-input-plugin-btn', 'as-message-input-plugin-cancel'],
                        child: 'span.mdi.mdi-close'
                    }
                ]
            },
            {
                class: 'as-message-input-pre-ctn',
                child: [
                    'messagequote.as-message-input-quote.as-removable.as-shorten-text',
                    {
                        class: 'as-message-input-emoji-btn-ctn',
                        child: {
                            tag: 'button',
                            class: ['as-message-input-plugin-btn', 'as-message-input-plugin-emoji'],
                            child: 'span.mdi.mdi-emoticon-happy-outline'
                        }
                    },
                    {
                        class: ['as-message-input-attachment-ctn', 'as-bscroller'],
                        child: [{
                            tag: 'button',
                            class: 'as-message-input-attachment-add-btn',
                            child: [
                                'span.mdi.mdi-arrow-down-bold.as-message-input-attachment-add-btn-drop',
                                {
                                    tag: 'span',
                                    class: 'as-message-input-attachment-add-btn-plus',
                                    child: {
                                        text: "+"
                                    }
                                }

                            ]
                        }]
                    },
                    'preinput.as-message-input-pre.absol-bscroller'
                ]
            }
        ]
    });
};


MessageInput.prototype.toggleEmoji = function () {
    if (this.containsClass('as-message-input-show-emoji'))
        this.closeEmoji();
    else
        this.showEmoji();
};


MessageInput.prototype.showEmoji = function () {
    if (this.containsClass('as-message-input-show-emoji')) return;
    var value = this.$preInput.value;
    this._lastInputSelectPosion = this.$preInput.getSelectPosition() || {start: value.length, end: value.length};
    this.addClass('as-message-input-show-emoji');
    this.addChild(this.$emojiPickerCtn);
    var thisMi = this;
    setTimeout(function () {
        $(document.body).on('mousedown', thisMi.eventHandler.mousedownOutEmoji);
    }, 100);
    this.$preInput.focus();
};


MessageInput.prototype.notifyChange = function () {
    this.emit('change', {name: 'change', target: this}, this);
    if (this.autoSend) {
        if (this.files.length > 0 || this.images.length > 0)
            this.notifySend();
    }
};

MessageInput.prototype.notifySend = function () {
    var eventData = {
        imageRemovePrevented: false,
        fileRemovePrevented: false,
        textRemovePrevented: false,
        quoteRemovePrevented: false,
        target: this,
        files: this.files,
        images: this.images,
        text: this.text
    };
    if (eventData.files.length > 0) {
        this.emit('sendfile', Object.assign(eventData, {
            type: 'sendfile', preventDefault: function () {
                this.fileRemovePrevented = true;
            }
        }), this);
    }

    if (eventData.images.length > 0) {
        this.emit('sendimage', Object.assign(eventData, {
            type: 'sendimage', preventDefault: function () {
                this.imageRemovePrevented = true;
            }
        }), this);
    }

    if ((typeof this.quote === "string") || this.quote) {
        this.emit('sendquote', Object.assign(eventData, {
            type: 'sendquote', preventDefault: function () {
                this.quoteRemovePrevented = true;
            }
        }), this);
    }

    if (this.files.length > 0 || eventData.images.length > 0 || eventData.text || ((typeof this.quote === "string") || this.quote)) {
        if (eventData.text) this.$preInput.focus();
        this.emit('send', Object.assign(eventData, {
            type: 'send', preventDefault: function () {
                this.imageRemovePrevented = true;
                this.fileRemovePrevented = true;
                this.imageRemovePrevented = true;
                this.quoteRemovePrevented = true;

            }
        }), this);
    }
    if (!eventData.fileRemovePrevented) this.files = [];
    if (!eventData.imageRemovePrevented) this.images = [];
    if (!eventData.textRemovePrevented) this.text = '';
    if (!eventData.quoteRemovePrevented) this.quote = null;

};

MessageInput.prototype.notifyCancel = function () {
    this.emit('cancel', {
        type: 'cancel',
        name: 'send', target: this, clearAllContent: this.clearAllContent.bind(this)
    }, this);
};

MessageInput.prototype.clearAllContent = function () {
    this.text = '';
    this.quote = null;
    this.files = [];
    this.images = [];
};

MessageInput.prototype.focus = function () {
    var value = this.$preInput.value;
    var range = this.$preInput.getSelectPosition() || {start: value.length, end: value.length};
    this.$preInput.focus();
    this.$preInput.applyData(value, range);
};

MessageInput.prototype.blur = function () {
    this.$preInput.blur();
};


MessageInput.prototype._updateAttachmentClass = function () {
    if (this._imageFiles.length + this._files.length) {
        this.addClass("as-has-attachment");
    } else {
        this.removeClass("as-has-attachment");
    }
};

MessageInput.prototype.addImageFiles = function (imageFiles, urls) {
    var thisMi = this;
    Array.prototype.forEach.call(imageFiles, function (file, index) {
        thisMi._imageFiles.push(file);
        var src;
        if (urls) {
            src = urls[index];
        }
        if (!src) {
            src = URL.createObjectURL(file);
        }
        var itemElt = _({
            class: ['as-message-input-attach-preview', 'as-image'],
            attr: {
                title: file.name
            },
            child: [
                {
                    class: 'as-message-input-attach-preview-image',
                    style: {
                        backgroundImage: 'url(' + src + ')'
                    }
                },
                {
                    tag: 'button',
                    class: 'as-message-input-attach-preview-close-btn',
                    child: 'span.mdi.mdi-close',
                    attr: {
                        title: 'remove'
                    },
                    on: {
                        click: function () {
                            thisMi._imageFiles = thisMi._imageFiles.filter(function (it) {
                                return it !== file;
                            });
                            itemElt.remove();
                            thisMi._updateAttachmentClass();
                            thisMi.notifySizeChange();
                            thisMi.notifyChange();
                        }
                    }
                }, {
                    class: 'as-message-input-attach-preview-info',
                    child: [
                        {
                            class: 'as-message-input-attach-preview-name',
                            child: {text: file.name}
                        },
                        {
                            class: 'as-message-input-attach-preview-size',
                            child: {text: Object(utils["fileSize2Text"])(file.size)}
                        }
                    ]
                }
            ]
        }).addTo(thisMi.$attachmentCtn);
        thisMi.$attachmentCtn.addChildBefore(itemElt, thisMi.$attachmentAddBtn);

    });
    this._updateAttachmentClass();
    this.notifySizeChange();
};

MessageInput.prototype.addFiles = function (files) {
    var thisMi = this;
    Array.prototype.forEach.call(files, function (file, index) {
        thisMi._files.push(file);
        MessageInput.iconSupportAsync.then(function (ExtensionIcons) {
            var src;
            var ext = file.name.split('.').pop().toLowerCase();
            if (ExtensionIcons.indexOf(ext) > 0) {
                src = MessageInput.iconAssetRoot + '/' + ext + '.svg'
            } else {
                src = MessageInput.iconAssetRoot + '/' + 'default' + '.svg'

            }
            var itemElt = _({
                class: ['as-message-input-attach-preview', 'as-file'],
                attr: {
                    title: file.name
                },
                child: [
                    {
                        tag: 'img',
                        class: 'as-message-input-attach-preview-file',
                        props: {
                            src: src
                        }
                    },
                    {
                        tag: 'button',
                        class: 'as-message-input-attach-preview-close-btn',
                        child: 'span.mdi.mdi-close',
                        attr: {
                            title: 'remove'
                        },
                        on: {
                            click: function () {
                                thisMi._files = thisMi._files.filter(function (it) {
                                    return it !== file;
                                });
                                itemElt.remove();
                                thisMi._updateAttachmentClass();
                                thisMi.notifySizeChange();
                                thisMi.notifyChange();
                            }
                        }
                    },
                    {
                        class: 'as-message-input-attach-preview-info',
                        child: [
                            {
                                class: 'as-message-input-attach-preview-name',
                                child: {text: file.name}
                            },
                            {
                                class: 'as-message-input-attach-preview-size',
                                child: {text: Object(utils["fileSize2Text"])(file.size)}
                            }
                        ]
                    }
                ]
            });
            thisMi.$attachmentCtn.addChildBefore(itemElt, thisMi.$attachmentAddBtn);
        });
    });
    this._updateAttachmentClass();
    thisMi.notifySizeChange();
};


MessageInput.prototype.closeEmoji = function () {
    if (!this.containsClass('as-message-input-show-emoji')) return;
    this.removeClass('as-message-input-show-emoji');
    this.removeChild(this.$emojiPickerCtn);
    $(document.body).off('mousedown', this.eventHandler.mousedownOutEmoji);
};


MessageInput.prototype.notifyAddFiles = function (files) {
    var event = {
        resolvedAsync: Promise.resolve(files),
        files: files,
        resolve: function (result) {
            if (!result) {
                this.resolvedAsync = Promise.resolve(undefined);
            } else if (result.then) {
                this.resolvedAsync = result;
            } else {
                this.resolvedAsync = Promise.resolve(result);
            }
        }
    };
    this.emit('useraddfile', event);
    return event.resolvedAsync;
}

MessageInput.prototype.openFileDialog = function () {
    var thisMi = this;
    Object(utils["openFileDialog"])({multiple: true}).then(function (files) {
        if (!thisMi.autoSend) thisMi.$preInput.focus();
        thisMi.notifyAddFiles(files).then(function (files) {
            if (files && files.length > 0)
                thisMi.handleAddingFileByType(files);
        });
    });
};

MessageInput.prototype.handleAddingFileByType = function (files) {
    if (files.length > 0) {
        var imageFiles = [];
        var otherFiles = [];
        var file;
        for (var i = 0; i < files.length; ++i) {
            file = files[i];
            if (!!file.type && file.type.match && file.type.match(/^image\//)) {
                imageFiles.push(file);
            } else {
                otherFiles.push(file);
            }
        }
        this.addImageFiles(imageFiles);
        this.addFiles(otherFiles);
        this.notifyChange();
    }
};


MessageInput.prototype.notifySizeChange = function () {
    var bound = this.getBoundingClientRect();
    if (this._latBound.width != bound.width || this._latBound.height != bound.height) {
        this._latBound.width = bound.width;
        this._latBound.height = bound.height;
        this.emit('sizechange', {name: 'sizechange', bound: bound, target: this}, this);
    }
};

MessageInput.prototype.addPlugin = function (option) {
    var plugin = new this.PluginConstructor(this, option);
    this._plugins.push(plugin);
    this.addStyle('--plugin-buttons-width', this._plugins.length * 45 + 'px');
    return plugin;
};

/***
 *
 * @param {{name?:string, exec:function(_this:MessageInput):void, keyBiding?:string}} option
 */
MessageInput.prototype.addCommand = function (option) {
    option.name = option.name || Object(stringGenerate["randomIdent"])(20);
    this._cmdRunner.add(option.name, option.exec);
    if (option.keyBiding && option.keyBiding.trim) {
        var keyBindingIdent = normalizeKeyBindingIdent(option.keyBiding);
        this._keyMaps[keyBindingIdent] = option.name;
    }
};

MessageInput.prototype.exeCmd = function (name) {
    var args = Array.prototype.slice.call(arguments);
    args[0] = this;
    args.unshift(name);
    this._cmdRunner.invoke.apply(this._cmdRunner, args);
};


MessageInput.prototype._updateQuote = function () {
    this.$quote.data = this._quote;
    if (this._quote)
        this.addClass('as-has-quote');
    else
        this.removeClass('as-has-quote');
    this.notifySizeChange();
};

/**
 * @type {MessageInput}
 */
MessageInput.eventHandler = {};

MessageInput.eventHandler.preInputChange = function (event) {
    var text = this.$preInput.value;
    if (text.length > 0) {
        this.addClass('as-has-text');
    } else {
        this.removeClass('as-has-text');
    }

    if (text === this._editingText) {
        this.removeClass('as-text-changed');
    } else {
        this.addClass('as-text-changed');

    }
    this.notifySizeChange();
    this.notifyChange();
};

MessageInput.eventHandler.preInputKeyDown = function (event) {
    if (!(event.shiftKey || event.ctrlKey || event.altKey) && event.key === 'Enter') {
        this.notifySend();
        event.preventDefault();
    } else if ((event.shiftKey || event.ctrlKey || event.altKey) && event.key === 'Enter') {
        event.preventDefault();
        var text = this.$preInput.value;
        var selectedPos = this.$preInput.getSelectPosition();
        var newText = text.substr(0, selectedPos.start)
            + '\n' + text.substr(selectedPos.end);
        this.$preInput.applyData(newText, selectedPos.start + 1);
        this.notifySizeChange();
        this.$preInput.commitChange(newText, selectedPos.start + 1);
    } else if (event.key === "Escape" && this._mode === MODE_EDIT) {
        this.notifyCancel();
        event.preventDefault();
    }
    var keyBindingIdent = keyboardEventToKeyBindingIdent(event);
    if (this._keyMaps[keyBindingIdent]) {
        event.preventDefault();
        this.exeCmd(this._keyMaps[keyBindingIdent]);
    }
    setTimeout(this.notifySizeChange.bind(this), 1);
};

MessageInput.eventHandler.preInputKeyUp = function (event) {
    var value = this.$preInput.value;
    this._lastInputSelectPosion = this.$preInput.getSelectPosition() || {start: value.length, end: value.length};
    this.notifySizeChange();
};

MessageInput.eventHandler.preInputPasteImg = function (event) {
    if (this._mode == 'edit') return;
    var files = Array.prototype.slice.call(event.imageFiles);
    var urls = event.urls && Array.prototype.slice.call(event.urls);
    this.notifyAddFiles(files).then(function (newFiles) {
        if (!newFiles || newFiles.length === 0) return;
        var newUrls = urls && newFiles.map(function (file) {
            return urls[files.indexOf(file)];
        });
        this.addImageFiles(newFiles, newUrls);
        this.notifyChange();
    }.bind(this));
};


MessageInput.eventHandler.preInputFocus = function () {
    this.addClass('as-focus');
};

MessageInput.eventHandler.preInputBlur = function () {
    this.removeClass('as-focus');
};


MessageInput.eventHandler.clickEmojiBtn = function () {
    this.toggleEmoji();
};

MessageInput.eventHandler.mousedownOutEmoji = function (event) {
    if (EventEmitter["b" /* default */].hitElement(this.$emojiPicker, event) || EventEmitter["b" /* default */].hitElement(this.$emojiBtn, event)) return;
    this.closeEmoji();
};

MessageInput.eventHandler.pickEmoji = function (event) {
    var text = this.$preInput.value;
    var newText = text.substr(0, this._lastInputSelectPosion.start) + event.key + text.substr(this._lastInputSelectPosion.end);
    var selected = this._lastInputSelectPosion;
    var newOffset = selected.start + event.key.length;
    this._lastInputSelectPosion = {start: newOffset, end: newOffset};
    this.$preInput.focus();
    this.$preInput.applyData(newText, newOffset);
    this.$preInput.commitChange(newText, newOffset);
    this.notifySizeChange();
    this.$preInput.focus();//older firefox version will be lost focus
    // this.notifyChange();//not need
};


MessageInput.eventHandler.dragover = function (event) {
    event.preventDefault();
    this.addClass('as-drag-hover');
    this.notifySizeChange();
    if (this._hoverTimeout > 0)
        clearTimeout(this._hoverTimeout);
    var thisMi = this;
    this._hoverTimeout = setTimeout(function () {
        thisMi._hoverTimeout = -1;
        thisMi.removeClass('as-drag-hover');
        thisMi.notifySizeChange();
    }, 200);
    //todo:
};

MessageInput.eventHandler.drop = function (event) {
    event.preventDefault();
    var files = [];
    var file;
    if (event.dataTransfer.items) {
        for (var i = 0; i < event.dataTransfer.items.length; i++) {
            if (event.dataTransfer.items[i].kind === 'file') {
                file = event.dataTransfer.items[i].getAsFile();
                if (!file.type && file.size % 4096 == 0) {
                    //todo: folder
                } else {
                    files.push(file);
                }

            }
        }
    } else {
        for (var i = 0; i < event.dataTransfer.files.length; i++) {
            file = event.dataTransfer.files[i];
            if (!file.type && file.size % 4096 == 0) {

            } else {
                files.push(file);
            }
        }
    }

    this.notifyAddFiles(files).then(function (files) {
        this.handleAddingFileByType(files);
    }.bind(this));
};

MessageInput.eventHandler.clickQuoteRemoveBtn = function () {
    this.quote = null;
    this.notifyChange();
}

MessageInput.property = {};

MessageInput.property.files = {
    set: function (value) {
        $$('.as-file', this.$attachmentCtn).forEach(function (elt) {
            elt.remove();
        });
        value = value || [];
        this._files = [];
        this.addFiles(value);
    },
    get: function () {
        return this._files;
    }
};

MessageInput.property.images = {
    set: function (value) {
        $$('.as-image', this.$attachmentCtn).forEach(function (elt) {
            elt.remove();
        });
        value = value || [];
        this._imageFiles = [];
        this.addImageFiles(value);
    },
    get: function () {
        return this._imageFiles;
    }
};

MessageInput.property.text = {
    set: function (text) {
        this.$preInput.value = '' + text;
        if (text.length > 0) {
            this.addClass('as-has-text');
        } else {
            this.removeClass('as-has-text');
        }
        if (this._mode === MODE_EDIT) {
            this._editingText = text;
        }
        this.removeClass('as-text-changed');
    },
    get: function () {
        return this.$preInput.value;
    }
};


/**
 * @type {MessageInput}
 */
MessageInput.property.mode = {
    set: function (value) {
        value = value || MODE_NEW;
        if (value === MODE_EDIT || (value.toLowerCase && value.toLowerCase() === 'edit')) {
            this.addClass('as-mode-edit');
            value = MODE_EDIT;
            this._editingText = this.$preInput.value;
        } else {
            value = MODE_NEW;
            this._editingText = '';
            this.removeClass('as-mode-edit');
        }
        this.removeClass('as-text-changed');
        this._mode = value;
    },
    get: function () {
        return this._mode === MODE_EDIT ? 'edit' : 'new';
    }
};

MessageInput.property.autoSend = {
    set: function (value) {
        if (value) {
            this.addClass('as-auto-send');
        } else {
            this.removeClass('as-auto-send');
        }
    },
    get: function () {
        return this.containsClass('as-auto-send');
    }
};

MessageInput.property.quote = {
    set: function (quote) {
        this._quote = quote;
        this._updateQuote();
    },
    get: function () {
        return this._quote;
    }
}


ACore["d" /* default */].install(MessageInput);

/* harmony default export */ var js_MessageInput = __webpack_exports__["b"] = (MessageInput);


var urlRex = /^(firefox|opera|chrome|https|http|wss|ws):\/\/[^\s]+$/;

function parseMessage(text, data) {
    data = data || {};
    data.emojiAssetRoot = data.emojiAssetRoot || EmojiPicker["a" /* default */].assetRoot;
    data.staticSize = data.staticSize || 20;
    data.animSize = data.animSize || 60;
    var textLines = text.split(/\r?\n/);
    var lines = textLines.map(function (textLine) {
        var longTokenTexts = textLine.split(/\s/);
        var tokenGroups = longTokenTexts.map(function (longTokenText, longTokenIndex) {
            var tokens = [];
            if (longTokenIndex > 0) tokens.push({
                type: 'text',
                value: ' '
            });

            var emojiKey, emojiKeyTemp;
            var subIndex, subIndexTemp;
            var leftToken;
            var found;
            var emoji;
            while (longTokenText.length > 0) {
                found = false;
                subIndex = 10000000;
                for (var i = 0; i < EmojiAnims["a" /* default */].length; ++i) {
                    emojiKeyTemp = EmojiAnims["a" /* default */][i][0];
                    subIndexTemp = longTokenText.indexOf(emojiKeyTemp);
                    if (subIndexTemp >= 0 && subIndexTemp < subIndex) {
                        subIndex = subIndexTemp;
                        emojiKey = emojiKeyTemp;
                        emoji = EmojiAnims["a" /* default */][i];
                        found = true;
                    }
                }

                if (found) {
                    if (subIndex >= 0) {
                        leftToken = longTokenText.substr(0, subIndex);
                        longTokenText = longTokenText.substr(subIndex + emojiKey.length);
                        if (leftToken.length > 0) {
                            tokens.push({
                                type: 'text',
                                value: leftToken
                            });
                        }
                        tokens.push({
                            type: 'emoji',
                            value: emoji
                        });
                        found = true;
                    }
                } else {
                    tokens.push({
                        type: 'text',
                        value: longTokenText
                    });
                    longTokenText = '';
                }
            }

            tokens.forEach(function (token) {
                if (token.type == 'text') {
                    var urlMatched = token.value.match(urlRex);
                    if (urlMatched) {
                        token.type = 'url';
                        token.protocal = urlMatched[1]
                    }
                }
            })
            return tokens;
        });
        var tokens = [];

        for (var i = 0; i < tokenGroups.length; ++i) {
            tokens.push.apply(tokens, tokenGroups[i]);
        }

        return tokens.reduce(function (ac, token) {
                if (token.type == 'text' && ac.last.type == 'text') {
                    ac.last.value += token.value;
                } else {
                    ac.last = token;
                    ac.result.push(token);
                }
                return ac;
            },
            {result: [], last: {type: 'null'}})
            .result;
    });
    var res = lines.reduce(function (ac, line, lineIndex, lines) {
        line.reduce(function (ac, token) {
            if (token.type == 'text') {
                ac.push({
                    tag: 'span',
                    child: {text: token.value}
                })
            } else if (token.type == 'url') {
                ac.push({
                    tag: 'a',
                    class: 'as-protocal-' + token.protocal,
                    child: {text: token.value},
                    props: {
                        href: token.value
                    }
                })
            } else if (token.type == 'emoji') {
                ac.push({
                    tag: 'span',
                    class: 'as-emoji-text',
                    child: {text: token.value[0]}
                });
                ac.push({
                    tag: 'img',
                    class: 'as-emoji',
                    props: {
                        src: data.emojiAssetRoot + '/static/x' + data.staticSize + '/' + token.value[1]
                    }
                })
            }
            return ac;
        }, ac);
        if (lineIndex < lines.length - 1 || line.length == 0)
            ac.push('br');
        return ac;
    }, []);
    if (res.length == 2 && res[1].class == 'as-emoji') {
        res[1].tag = 'iconsprite',
            res[1].props.fps = 30;
        res[1].props.src = res[1].props.src.replace('/static/x' + data.staticSize, '/anim/x' + data.animSize);
    }
    return res;
}

MessageInput.parseMessage = parseMessage;

function prepareIcon() {
    if (!MessageInput.iconSupportAsync) {
        var catalogiUrl = MessageInput.iconAssetRoot + '/catalog.json';
        MessageInput.iconSupportAsync = MessageInput.iconSupportAsync || iconCatalogCaches[catalogiUrl] ? Promise.resolve(iconCatalogCaches[catalogiUrl]) : XHR["a" /* default */].getRequest(catalogiUrl).then(function (result) {
            iconCatalogCaches[catalogiUrl] = JSON.parse(result);
            return iconCatalogCaches[catalogiUrl];
        });
    }
    return MessageInput.iconSupportAsync;
}


/***
 * @typedef MessageInputPluginOption
 * @property {string} [id]
 * @property {string|Object|AElement} icon
 * @property {function(_thisAdapter: MessageInputPlugin, _:Dom._, Dom.$):AElement} createContent
 * @property {function(_thisAdapter:MessageInputPlugin):void} onPressTrigger
 */


function MessageQuote() {
    prepareIcon();
    /***
     *
     * @type {null|MessageInputQuote}
     * @private
     */
    this._data = null;
    this.$img = $('.as-message-quote-img', this);
    this.$text = $('.as-message-quote-text', this);
    this.$desc = $('.as-message-quote-desc', this);
    this.$removeBtn = $('.as-message-quote-remove-btn', this)
        .on('click', this.eventHandler.clickRemoveBtn);
    Object.defineProperty(this, '$text', {
        set: function () {
            console.trace();
        },
        get: function () {
            return $('.as-message-quote-text', this);
        }
    })

}

MessageQuote.tag = 'MessageQuote'.toLowerCase();

MessageQuote.render = function () {
    return _({
        extendEvent: 'pressremove',
        class: 'as-message-quote-box',
        child: [
            {
                class: 'as-message-quote-img'
            },
            {
                class: 'as-message-quote-sym',
                child: 'span.mdi.mdi-format-quote-open-outline'
            },
            {
                class: 'as-message-quote-content',
                child: [
                    {
                        class: 'as-message-quote-text',
                        child: {
                            text: ''
                        }
                    },
                    {
                        class: 'as-message-quote-desc',
                        child: {text: ''}
                    }
                ]
            },
            {
                tag: 'button',
                class: 'as-message-quote-remove-btn',
                child: 'span.mdi.mdi-close'
            }
        ]
    });
};

MessageQuote.property = {};
MessageQuote.eventHandler = {};

MessageQuote.property.removable = {
    set: function (val) {
        if (val) {
            this.addClass('as-removable');
        } else {
            this.removeClass('as-removable');
        }
    },
    get: function () {
        return this.containsClass('as-removable');
    }
};

MessageQuote.property.shortenText = {
    set: function (val) {
        if (val) {
            this.addClass('as-shorten-text');
        } else {
            this.removeClass('as-shorten-text');
        }
    },
    get: function () {
        return this.containsClass('as-shorten-text');
    }
};

MessageQuote.property.data = {
    set: function (quote) {
        this._data = quote;
        var text, desc;
        var file, img;
        if (typeof quote === "string") {
            text = quote;
            desc = ''
        } else if (quote && (typeof quote === "object")) {
            text = quote.text;
            desc = quote.desc;
            file = quote.file;
            img = quote.img;
        }


        if (text === undefined) {
            this.$text.clearChild();
            this.$desc.firstChild.data = '';
            this.removeClass('as-has-file');
            this.removeClass('as-has-img');
        } else {
            if (file) {
                file = file.toLowerCase().split('.').pop();
                MessageInput.iconSupportAsync.then(function (iconSupport) {
                    if (iconSupport.indexOf(file) < 0) file = 'default';
                    this.$img.addStyle('background-image', 'url(' + MessageInput.iconAssetRoot + '/' + file + '.svg)');
                }.bind(this));
                this.addClass('as-has-file');
            } else
                this.removeClass('as-has-file');

            if (img) {
                this.$img.addStyle('background-image', 'url(' + img + ')');
                this.addClass('as-has-img');
            } else this.removeClass('as-has-img');
            if (this.shortenText) text = text.split(/\r?\n/).shift();
            var parsedText = parseMessage(text);
            var textEltChain = parsedText.map(function (c) {
                return _(c);
            });
            this.$text.clearChild().addChild(textEltChain);
            this.$desc.firstChild.data = desc;
        }
    },
    get: function () {
        return this.data;
    }
};

MessageQuote.eventHandler.clickRemoveBtn = function () {
    this.emit('pressremove', {target: this, type: 'pressclose'}, this);
};

ACore["d" /* default */].install(MessageQuote);


/***
 *
 * @param {MessageInput} inputElt
 * @param {MessageInputPluginOption} option
 * @constructor
 */
function MessageInputPlugin(inputElt, option) {
    this.inputElt = inputElt;
    this.icon = option.icon;
    this.id = option.id || Object(stringGenerate["randomIdent"])(16);
    this.$icon = null;
    this.$triggerBtn = null;
    this.$content = null;
    this.$popup = null;
    if (option.createContent) this.createContent = option.createContent;
    if (option.onPressTrigger) this.onPressTrigger = option.onPressTrigger;
    this.ev_pressTrigger = this.ev_pressTrigger.bind(this);
    this.ev_pressOut = this.ev_pressOut.bind(this);
    this.attach();
}


MessageInputPlugin.prototype.attach = function () {
    this.inputElt.$right.addChildBefore(this.getTriggerButton(), this.inputElt.$right.firstChild);
};

MessageInputPlugin.prototype.ev_pressTrigger = function (event) {
    var value = this.inputElt.$preInput.value;
    this._lastInputSelectPosion = this.inputElt.$preInput.getSelectPosition() || {
        start: value.length,
        end: value.length
    };
    if (this.onPressTrigger) {
        this.onPressTrigger(this);
    } else {
        if (this.isPopupOpened()) {
            this.closePopup();
        } else {
            this.openPopup();
        }
    }
};

MessageInputPlugin.prototype.insertText = function (itext) {
    if (!this._lastInputSelectPosion) {
        throw new Error('Invalid call');
    }

    var text = this.inputElt.$preInput.value;
    var newText = text.substr(0, this._lastInputSelectPosion.start) + itext + text.substr(this._lastInputSelectPosion.end);
    var selected = this._lastInputSelectPosion;
    var newOffset = selected.start + itext.length;
    this.inputElt.$preInput.focus();
    this.inputElt.$preInput.applyData(newText, newOffset);
    this.inputElt.$preInput.commitChange(newText, newOffset);
    this.inputElt.notifySizeChange();
    this.inputElt.$preInput.focus();
};


MessageInputPlugin.prototype.appendText = function (itext) {
    if (!this._lastInputSelectPosion) {
        throw new Error('Invalid call');
    }
    var text = this.inputElt.$preInput.value;
    var newText = text + itext;
    var newOffset = newText.length;
    this.inputElt.$preInput.focus();
    this.inputElt.$preInput.applyData(newText, newOffset);
    this.inputElt.$preInput.commitChange(newText, newOffset);
    this.inputElt.notifySizeChange();
    this.inputElt.$preInput.focus();
}

MessageInputPlugin.prototype.replaceText = function (itext) {
    if (!this._lastInputSelectPosion) {
        throw new Error('Invalid call');
    }
    var newText = itext;
    var newOffset = newText.length;
    this.inputElt.$preInput.focus();
    this.inputElt.$preInput.applyData(newText, newOffset);
    this.inputElt.$preInput.commitChange(newText, newOffset);
    this.inputElt.notifySizeChange();
    this.inputElt.$preInput.focus();
}


MessageInputPlugin.prototype.ev_pressOut = function (event) {
    if (EventEmitter["b" /* default */].hitElement(this.getTriggerButton(), event)) return;
    if (EventEmitter["b" /* default */].hitElement(this.getPopup(), event)) return;
    this.closePopup();
};


MessageInputPlugin.prototype.getIconElt = function () {
    if (!this.$icon)
        this.$icon = _(this.icon);
    return this.$icon;
};


MessageInputPlugin.prototype.getTriggerButton = function () {
    if (!this.$triggerBtn) {
        this.$triggerBtn = _({
            tag: 'button',
            class: ['as-message-input-plugin-btn', 'as-message-input-plugin-' + this.id],
            child: this.getIconElt(),
            on: {
                click: this.ev_pressTrigger
            }
        });
    }
    return this.$triggerBtn;
};

MessageInputPlugin.prototype.createContent = function (_thisAdapter, _, $) {
    throw  new Error("Not implement!");
};

/***
 *
 * @type {null|function(_thisAdapter:MessageInputPlugin):void}
 */
MessageInputPlugin.prototype.onPressTrigger = null;


MessageInputPlugin.prototype.getContent = function () {
    if (!this.$content)
        this.$content = this.createContent(this.inputElt, _, $);
    return this.$content;
};


MessageInputPlugin.prototype.getPopup = function () {
    if (!this.$popup) {
        this.$popup = _({
            class: 'as-message-input-external-tools-popup',
            child: this.getContent()
        });
    }
    return this.$popup;
};

MessageInputPlugin.prototype.openPopup = function () {
    if (this.isPopupOpened()) return;
    this.inputElt.appendChild(this.getPopup());
    document.body.addEventListener('click', this.ev_pressOut);
};


MessageInputPlugin.prototype.closePopup = function () {
    if (!this.isPopupOpened()) return;
    this.getPopup().remove();
    document.body.removeEventListener('click', this.ev_pressOut);

};

MessageInputPlugin.prototype.isPopupOpened = function () {
    return !!this.getPopup().parentElement;
};


MessageInput.prototype.PluginConstructor = MessageInputPlugin;


/***/ }),
/* 38 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_emojipicker_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(154);
/* harmony import */ var _css_emojipicker_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_emojipicker_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var _EmojiAnims__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(33);
/* harmony import */ var _Sprite__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(86);
/* harmony import */ var absol_src_HTML5_AElement__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(8);






var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;

/***
 * @extends AElement
 * @constructor
 */
function EmojiPicker() {
    var thisPicker = this;
    this._aliveTimeout = 90;
    this._assetRoot = this.attr('data-asset-root');
    /***
     *
     * @type {Sprite}
     */
    this.$previewAnim = $('sprite.as-emoji-picker-preview-anim', this)
        .on('ready', this.eventHandler.previewAnimReady)
        .on('frame', this.eventHandler.previewAnimFrame);
    this.$previewAnim.loop = true;
    this.$previewAnim.src = this._assetRoot + '/anim/x120/' + _EmojiAnims__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"][0][1];
    this.$previewAnim.fps = 30;
    this.$desc = $('.as-emoji-picker-preview-desc', this);
    this.$shortcut = $('.as-emoji-picker-preview-shortcut', this);
    this.$desc.clearChild().addChild(_({ text: _EmojiAnims__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"][0][2] }));
    this.$shortcut.clearChild().addChild(_({ text: _EmojiAnims__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"][0][0] }));
    this.$list = $('.as-emoji-picker-list', this);
    this.$items = _EmojiAnims__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].reduce(function (ac, it) {
        var itemElt = _({
            tag: 'img',
            class: 'as-emoji-picker-item',
            props: {
                src: thisPicker._assetRoot + '/static/x20/' + it[1]
            }
        }).addTo(thisPicker.$list);
        itemElt.on('mouseenter', thisPicker.eventHandler.mouseenterItem.bind(thisPicker, it, itemElt));
        itemElt.on('click', thisPicker.eventHandler.clickItem.bind(thisPicker, it));
        ac[it[0]] = itemElt;
        return ac;
    }, {});
    this.$attachook = _('attachhook').addTo(this).on('error', this.eventHandler.attach);
}

EmojiPicker.assetRoot = (function (){
    if (location.hostname.match(/^.*(\.?absol\.cf|absol\.ddns\.net)$/) ||location.hostname.match(/^localhost$/) )
        return  'https://absol.cf/emoji';

    return  '/emoji';
})();


EmojiPicker.tag = 'EmojiPicker'.toLowerCase();

EmojiPicker.render = function (data) {
    data = data || {};
    data.assetRoot = data.assetRoot || EmojiPicker.assetRoot;
    return _({
        class: 'as-emoji-picker',
        extendEvent: 'pick',
        attr: {
            'data-asset-root': data.assetRoot
        },
        child: [
            {
                class: 'as-emoji-picker-preview',
                child: [
                    {
                        class: '.as-emoji-picker-preview-anim-ctn',
                        child: 'sprite.as-emoji-picker-preview-anim'
                    },
                    '.as-emoji-picker-preview-desc',
                    '.as-emoji-picker-preview-shortcut'
                ]
            },
            {
                tag: 'bscroller',
                class: 'as-emoji-picker-list'
            }
        ]
    });
};


/**
 * @type {EmojiPicker}
 */
EmojiPicker.eventHandler = {};


EmojiPicker.eventHandler.attach = function () {
    this._aliveTimeout = 90;
    setTimeout(this.$previewAnim.play.bind(this.$previewAnim), 1);
};

EmojiPicker.eventHandler.previewAnimReady = function () {
    this.$previewAnim.frames = {
        type: 'grid',
        col: 1,
        row: this.$previewAnim.texture.naturalHeight / this.$previewAnim.texture.naturalWidth
    };
    this.$previewAnim.play();
};

EmojiPicker.eventHandler.previewAnimFrame = function () {
    if (this._aliveTimeout == 0) {
        var bound = this.getBoundingClientRect();
        if (bound.width == 0) {
            this.$previewAnim.stop();
        }
        else {
            this._aliveTimeout = 90;
        }
    }
    this._aliveTimeout--;
};


EmojiPicker.eventHandler.mouseenterItem = function (itemData, itemElt, event) {
    if (this.$lastHoverItem == itemElt) return;
    this.$lastHoverItem = itemElt;
    this.$previewAnim.src = this._assetRoot + '/anim/x120/' + itemData[1];
    this.$desc.clearChild().addChild(_({ text: itemData[2] }));
    this.$shortcut.clearChild().addChild(_({ text: itemData[0] }));
};

EmojiPicker.eventHandler.clickItem = function (itemData, event) {
    this.emit('pick', { name: 'pick', key: itemData[0], target: this }, this);
};

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(EmojiPicker);
/* harmony default export */ __webpack_exports__["a"] = (EmojiPicker);


/***/ }),
/* 39 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "wordLike", function() { return wordLike; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "wordsMatch", function() { return wordsMatch; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "phraseMatch", function() { return phraseMatch; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "phraseLike", function() { return phraseLike; });
/* harmony import */ var absol_src_Math_int__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(14);
/**
 *
 * @param {String} a
 * @param {String} b
 */



function wordLike(a, b) {
    var m = a.length;
    var n = b.length;

    function map(i, j) {
        return i * (n + 1) + j;
    }
    var Q = Array((m + 1) * (n + 1)).fill(0);

    for (var i = 0; i < m; ++i)
        for (var j = 0; j < n; ++j)
            if (a.charAt(i) == b.charAt(j)) {
                if (Q[map(i + 1, j + 1)]) {
                    if (Q[map(i + 1, j + 1)] < Q[map(i, j)] + 1)
                        Q[map(i + 1, j + 1)] = Q[map(i, j)] + 1;
                }
                else
                    Q[map(i + 1, j + 1)] = Q[map(i, j)] + 1;
            }
            else
                Q[map(i + 1, j + 1)] = Math.max(Q[map(i + 1, j)], Q[map(i, j + 1)]);

    return Q[map(m, n)] / Object(absol_src_Math_int__WEBPACK_IMPORTED_MODULE_0__["harmonicMean"])(m, n);
}

/**
 *
 * @param {Array<String>} sq1
 * @param {Array<String>} sq2
 */
function wordsMatch(sq1, sq2, matchWordPow) {
    matchWordPow = matchWordPow === undefined ? 1 : matchWordPow;

    var m = sq1.length;
    var n = sq2.length;
    function map(i, j) {
        return i * (n + 1) + j;
    }
    var Q = Array((m + 1) * (n + 1)).fill(0);
    var e = 0.0;
    for (var i = 0; i < m; ++i)
        for (var j = 0; j < n; ++j) {
            e = Math.pow(wordLike(sq1[i], sq2[j]), matchWordPow);

            if (Q[map(i + 1, j + 1)]) {
                if (Q[map(i + 1, j + 1)] < Q[map(i, j)] + e)
                    Q[map(i + 1, j + 1)] = Q[map(i, j)] + e;

            }
            else
                Q[map(i + 1, j + 1)] = Q[map(i, j)] + e;

            e = Math.max(Q[map(i + 1, j)], Q[map(i, j + 1)]);
            if (e > Q[map(i + 1, j + 1)]) Q[map(i + 1, j + 1)] = e;

        }

    return Q[map(m, n)];
}


function phraseMatch(a, b, matchWordPow) {
    matchWordPow = matchWordPow || 1;
    var spliter = /[\s,-\.+?\_]+/;
    var notEmp = function (e) {
        return e.length > 0;
    };
    var sq1 = a.toLowerCase().split(spliter).filter(notEmp);
    var sq2 = b.toLowerCase().split(spliter).filter(notEmp);
    var wordsMatchScore = wordsMatch(sq1, sq2);
    var m = sq1.length;
    var n = sq2.length;
    return wordsMatchScore / Math.max(Object(absol_src_Math_int__WEBPACK_IMPORTED_MODULE_0__["harmonicMean"])(m, n), 1);
};

function phraseLike(a, b, matchWordPow) {
    matchWordPow = matchWordPow || 1;
    var spliter = /[\s,-\.+?\_]+/;
    var notEmp = function (e) {
        return e.length > 0;
    };
    var sq1 = a.toLowerCase().split(spliter).filter(notEmp);
    var sq2 = b.toLowerCase().split(spliter).filter(notEmp);
    var m = sq1.length;
    var n = sq2.length;
    var wordsMatchScore = wordsMatch(sq1, sq2);
    return wordsMatchScore / Math.max(Object(absol_src_Math_int__WEBPACK_IMPORTED_MODULE_0__["harmonicMean"])(m, n), 1);
}



/***/ }),
/* 40 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return MenuButton; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return Dropdown; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return Dropright; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "h", function() { return VMenuLine; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "g", function() { return VMenuItem; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "f", function() { return VMenu; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return HMenuItem; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return HMenu; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "i", function() { return VRootMenu; });
/* harmony import */ var _css_menu_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(140);
/* harmony import */ var _css_menu_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_menu_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1);
/* harmony import */ var absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2);
/* harmony import */ var absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(3);
/* harmony import */ var absol_src_HTML5_AElement__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(8);
/* harmony import */ var _Follower__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(25);
/* harmony import */ var _tool_BlurTrigger__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(58);
/* harmony import */ var absol_src_HTML5_ResizeSystem__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(11);










var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;

/***
 * @extends AElement
 * @constructor
 */
function MenuButton() {
    this.$text = $('.absol-vmenu-button-text', this);
    this.$key = $('.absol-vmenu-button-key', this);


    this.$arrow = $('.absol-vmenu-arrow', this);
    this.$iconCtn = $('.absol-vmenu-button-ext-icon-container', this);

    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].drillProperty(this, this.$text, 'text', 'innerHTML');
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].drillProperty(this, this.$key, 'key', 'innerHTML');
}

MenuButton.tag = 'menubutton';

MenuButton.render = function () {
    return _({
        tag: 'button',
        class: 'absol-vmenu-button',
        child: [
            {
                class: 'absol-vmenu-button-ext-icon-container',
                child: 'img.absol-vmenu-button-icon'
            },
            '.absol-vmenu-button-text',
            '.absol-vmenu-button-key',
            {
                class: 'absol-vmenu-arrow-container',
                child: 'span.absol-vmenu-arrow'
            }
        ]
    });
};

MenuButton.property = {};

MenuButton.property.extendClasses = {
    set: function (value) {
        var self = this;
        this.extendClasses.forEach(function (className) {
            self.removeClass(className);
        });
        this._extendClass = [];
        if (!value) return;
        if (typeof value == 'string') {
            value = value.split(/\s+/).filter(function (c) {
                return c.length > 0
            });
        }

        if (value instanceof Array) {
            this._extendClass = value;
            this._extendClass.forEach(function (className) {
                self.addClass(className);
            });
        }
        else {
            throw new Error('Invalid extendClasses');
        }
    },
    get: function () {
        return this._extendClass || [];
    }
};


MenuButton.property.icon = {
    set: function (value) {
        this.$iconCtn.clearChild();
        this._icon = value;
        if (value) {
            _(value).addTo(this.$iconCtn);
        }
    },
    get: function () {
        return this._icon;
    }
};

MenuButton.property.iconSrc = {
    set: function (value) {
        if (value)
            this.icon = { tag: 'img', props: { src: value } };
        else
            this.icon = value;
    },
    get: function () {
        return this.icon && this.icon.props && this.icon.props.src;
    }
};


MenuButton.property.extendStyle = {
    set: function (value) {
        this.removeStyle(this._extendStyle || {});
        this._extendStyle = value || {};
        this.addStyle(this.extendStyle);
    },
    get: function () {
        return this._extendStyle || {};
    }
};

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(MenuButton);

/***
 *
 * @extends Follower
 * @constructor
 */
function Dropdown() {
    this.$container = $('.absol-dropdown-content', this);
    this.$container.followTarget = this;
    this.$container.anchor = [1, 2, 6, 5];

}

Dropdown.tag = 'dropdown';

Dropdown.render = function () {
    return _({
        class: ['absol-drop-hidden', 'absol-dropdown'], child: 'follower.absol-dropdown-content.as-bscroller'
    });
};


Dropdown.property = {};
Dropdown.property.show = {
    set: function (value) {
        if (value) {
            this.removeClass('absol-drop-hidden');
            absol_src_HTML5_ResizeSystem__WEBPACK_IMPORTED_MODULE_8__[/* default */ "a"].update();
            if (this.$container.lastChild && this.$container.lastChild.$items) {
                this.$container.lastChild.$items.forEach(function (itemElt) {
                    if (itemElt.autoFixParrentSize) {
                        itemElt.autoFixParrentSize();
                    }
                });
            }
            var aPst = this.findAvailablePosition();
            if (aPst.crampedHeight) {
                this.removeClass('overlap-top');
                // this.$container.followTarget = null;?
                this.$container.addStyle({
                    'max-height': aPst.maxHeight + 'px'
                });
                this.$container.refollow();
                this.$container.updatePosition();
                this.$container.addStyle('top', this.getBoundingClientRect().top + aPst.posTop + 'px');


            }
            else {
                this.$container.removeStyle('max-height')
                    .removeStyle('top');
                this.$container.refollow();
                this.$container.updatePosition();
            }
        }
        else {
            this.addClass('absol-drop-hidden');
        }
    },
    get: function () {
        return !this.containsClass('absol-drop-hidden');
    }
};

Dropdown.prototype.findAvailablePosition = function () {
    var outBound = absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__[/* default */ "b"].traceOutBoundingClientRect(document.body);
    var containerBound = this.$container.getBoundingClientRect();
    var bound = this.getBoundingClientRect();
    var distTop = bound.top - outBound.top;
    var distLeft = bound.left - outBound.left;
    var distRight = -bound.right + outBound.right;
    var distBottom = -bound.bottom + outBound.bottom;
    var result = {};

    if (distLeft >= containerBound.width) result.left = true;
    if (distTop >= containerBound.height) result.top = true;
    if (distRight >= containerBound.width) result.right = true;
    if (distBottom >= containerBound.height) result.bottom = true;
    if (distRight + bound.width >= containerBound.width) result.overlapRight = true;
    if (distLeft + bound.width >= containerBound.width) result.overlapLeft = true;
    if (distBottom + bound.height >= containerBound.height) result.overlapBottom = true;
    if (distTop + bound.height >= containerBound.height) result.overlapTop = true;
    if (!result.overlapTop && !result.overlapBottom) {
        result.crampedHeight = true;
        result.maxHeight = outBound.height - 20;
        result.posTop = distBottom - Math.min(containerBound.height, result.maxHeight) + bound.height - 10;
    }

    return result;
};

Dropdown.prototype.addChild = function (child) {
    if (child instanceof Array) {
        for (var i = 0; i < child.length; ++i)
            this.addChild(child[i]);
    }
    else {
        if (!this.$trigger) {
            this.super(child);
            this.$trigger = child;
        }
        else {
            this.$container.addChild(child);
        }
    }
};


Dropdown.prototype.clearChild = function () {
    if (this.$trigger) {
        this.$trigger.selfRemove();
        this.$trigger = undefined;
    }
    this.$container.clearChild();
};


Dropdown.prototype.init = function (props) {
    props = props || {};
    Object.assign(this, props);
};


function Dropright() {
    this.$container = $('.absol-dropright-content', this);
    this.$container.followTarget = this;
    this.$container.anchor = [0, 3, 7, 4];
}

Dropright.tag = 'dropright';

Dropright.render = function () {
    return _({
        class: ['absol-drop-hidden', 'absol-dropright'],
        child: 'follower.absol-dropright-content.as-bscroller',
        data: { $trigger: undefined, $content: undefined, _isShow: false }
    });
}

Object.assign(Dropright.prototype, Dropdown.prototype);


//is the same
Dropright.prototype.addChild = Dropdown.prototype.addChild;
Dropright.prototype.clearChild = Dropdown.prototype.clearChild;
Dropright.property = Object.assign({}, Dropdown.property);


function VMenuLine() {
    return _('<div class="absol-vmenu-line"><div></div></div>');
}

VMenuLine.tag = 'VMenuLine'.toLowerCase();

function VMenuItem() {
    var thisVM = this;

    this.sync = new Promise(function (rs) {
        _('attachhook').addTo(thisVM).on('error', function () {
            this.remove();
            rs();
        })
    });
    this.$dropper = $('dropright', this);
    this.$vmenu = $('vmenu', this);
    this.$button = $('menubutton', this);

    this.$text = thisVM.$button.$text;

    this.$key = thisVM.$button.$key;
    this.$arrow = thisVM.$button.$arrow;
    this.$iconCtn = thisVM.$button.$iconCtn;


    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].drillProperty(this, this.$button, ['text', 'extendClasses', 'extendStyle', 'key', 'icon', 'iconSrc']);
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].drillProperty(this, this.$vmenu, ['activeTab']);

    this.eventHandler = absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].bindFunctions(this, VMenuItem.eventHandler);
    this.$vmenu.on('press', this.eventHandler.pressItem, true);

    this.$button.on('click', this.eventHandler.clickButton, true);
    this.$button.on('mouseenter', this.eventHandler.enterButton, true);
    this._textMarginRight = 0;
}


VMenuItem.tag = 'VMenuItem'.toLowerCase();

VMenuItem.render = function () {
    return _({
        tag: 'dropright',
        extendEvent: ['press', 'enter'],
        child: ['menubutton',
            {
                tag: 'vmenu',
            }]
    });
};

VMenuItem.prototype.init = function (props) {
    Object.assign(this, props || {});
    this.sync = this.sync.then(this.autoFixParrentSize.bind(this));
};


VMenuItem.prototype.autoFixParrentSize = function () {
    var parentWidth = this.$dropper.getBoundingClientRect().width;// dropper is fixed parent content size
    if (!parentWidth) return;
    var buttonWidth = this.$button.getBoundingClientRect().width;
    var fontSize = this.$text.getFontSize();
    this._textMarginRight = parentWidth - buttonWidth + this._textMarginRight;
    this.$text.addStyle('margin-right', this._textMarginRight / fontSize + 'em');
};

VMenuItem.eventHandler = {};


VMenuItem.eventHandler.enterButton = function (event) {
    event.menuItem = this;
    var newEvent = absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].copyEvent(event);
    this.emit('enter', newEvent, this);
};


VMenuItem.eventHandler.pressItem = function (event) {
    var newEvent = absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].copyEvent(event, { target: this });
    this.emit('press', newEvent, this);
};

VMenuItem.eventHandler.clickButton = function (event) {
    event.menuDontHide = this.items && this.items.length > 0;
    event.menuItem = this;
    event.vmenuItem = this;
    var newEvent = absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].copyEvent(event, { target: this });
    this.emit('press', newEvent, this);
};


VMenuItem.property = {};
VMenuItem.property.items = {
    set: function (items) {
        items = items || [];
        if (items.length > 0) {
            this.$arrow.addClass(['mdi', 'mdi-chevron-right']);
        }
        else {
            this.$arrow.removeClass(['mdi', 'mdi-chevron-right']);
        }
        this.$vmenu.items = items;
    },
    get: function () {
        return this.$vmenu.items;
    }
};

VMenuItem.property.disable = {
    set: function (value) {
        if (value) {
            this.addClass('absol-menu-item-disable');
        }
        else {
            this.removeClass('absol-menu-item-disable');
        }
    },
    get: function () {
        return this.containsClass('absol-menu-item-disable');
    }
};


function VMenu() {
    var thisVM = this;

    this.sync = new Promise(function (rs) {
        _('attachhook').addTo(thisVM).on('error', function () {
            this.remove();
            rs();
        })
    });
}

VMenu.tag = 'vmenu';

VMenu.render = function () {
    return _({
        class: 'absol-vmenu',
        extendEvent: 'press'
    });
};


VMenu.property = {};
VMenu.property.activeTab = {
    set: function (tabIndex) {
        this._activeTab = tabIndex;
        if (this.$items) {
            for (var i = 0; i < this.$items.length; ++i) {
                var item = this.$items[i];
                item.show = i == tabIndex && !item.disable;
                item.activeTab = -1;
                if (i == tabIndex && !item.disable) {
                    item.$button && item.items && item.items.length > 0 && item.$button.addClass('absol-vmenu-button-hover');
                }
                else {
                    item.$button && item.$button.removeClass('absol-vmenu-button-hover');
                }
            }
        }
    },
    get: function () {
        return this._activeTab;
    }
};


VMenu.property.extendStyle = {
    set: function (value) {
        this.removeStyle(this._extendStyle || {});
        this._extendStyle = value || {};
        this.addStyle(this.extendStyle);
    },
    get: function () {
        return this._extendStyle || {};
    }
};


VMenu.property.extendClasses = {
    set: function (value) {
        var self = this;
        this.extendClasses.forEach(function (className) {
            self.removeClass(className);
        });
        this._extendClass = [];
        if (!value) return;
        if (typeof value == 'string') {
            value = value.split(/\s+/).filter(function (c) {
                return c.length > 0
            });
        }
        if (value instanceof Array) {
            this._extendClass = value;
            this._extendClass.forEach(function (className) {
                self.addClass(className);
            });
        }
        else {
            throw new Error('Invalid extendClasses');
        }
    },
    get: function () {
        return this._extendClass || [];
    }
};


VMenu.eventHandler = {};
VMenu.eventHandler.enterItem = function (event) {
    var tabIndex = event.menuItem._tabIndex;
    this.activeTab = tabIndex;
};


VMenu.eventHandler.pressItem = function (event) {
    this.emit('press', absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].copyEvent(event, { target: this }), this);
};


VMenu.property.items = {
    set: function (items) {
        this._childFromItems(items || []);
    },
    get: function () {
        return this.$items;
    }
}


VMenu.prototype.init = function (props) {
    Object.assign(this, props || {});
};


VMenu.prototype._childFromItems = function (items) {
    this.clearChild();
    this.$items = items.map(function (item, index) {
        var itemElt;
        if (typeof item === 'string' && (item.substr(0, 1) === '-' || item.substr(0, 1) === '=')) {
            itemElt = _('vmenuline');
        }
        else if (Object(absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__[/* isDomNode */ "e"])(item)) {
            itemElt = item;
        }
        else if (item.child || item.class || item.tag || item.style || typeof item === 'string') {
            itemElt = _(item);
        }
        else {
            itemElt = _({
                tag: 'vmenuitem',
                props: Object.assign({ _tabIndex: index }, item),
                on: {
                    enter: { callback: this.eventHandler.enterItem, cap: true },
                    press: { callback: this.eventHandler.pressItem, cap: true }
                }
            });
        }
        this.addChild(itemElt);
        return itemElt;
    }.bind(this));
    //todo
};


function HMenuItem() {
    this.blurTrigger = null;
    this.$vmenu = $('vmenu', this);
    this.$dropDown = this;
    this.$button = $('button.absol-hmenu-button', this);
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].drillProperty(this, this.$button, 'text', 'innerHTML');
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].drillProperty(this, this.$vmenu, 'items');
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].drillProperty(this, this.$vmenu, 'activeTab');

    this.$button.on('click', this.eventHandler.clickButton);
    this.$button.on('mouseenter', this.eventHandler.enterButton, true);
    this.$vmenu.on('press', this.eventHandler.pressItem, true);

    //property show not need because dropdown is itself
    return this;
}

HMenuItem.tag = 'HMenuItem'.toLowerCase();

HMenuItem.render = function () {
    return _({
        tag: 'dropdown',
        extendEvent: ['press', 'enter'],
        child: ['button.absol-hmenu-button',
            'vmenu'
        ]
    });
};


HMenuItem.eventHandler = {};

HMenuItem.eventHandler.clickButton = function (event) {
    event.menuItem = this;
    event.hmenuItem = this;
    this.emit('press', absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].copyEvent(event, { target: this }), this);
};

HMenuItem.eventHandler.enterButton = function (event) {
    event.menuItem = this;
    this.emit('enter', absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].copyEvent(event, { target: this }), this);
};

HMenuItem.eventHandler.pressItem = function (event) {
    this.emit('press', absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].copyEvent(event, { target: this }), this);
};

HMenuItem.prototype = {};

HMenuItem.prototype.disable = VMenuItem.prototype.disable;


HMenuItem.prototype.init = function (props) {
    props = props || {};
    Object.assign(this, props);
};

/***
 * @extends AElement
 * @constructor
 */
function HMenu() {
}

HMenu.tag = 'hmenu';

HMenu.render = function () {
    return _({
        class: 'absol-hmenu',
        extendEvent: ['press', 'enter', 'activetab', 'cancel']
    });
};


HMenu.eventHandler = {};
HMenu.eventHandler.pressItem = function (event) {
    /**
     * this.activeTab can be undefined
     * undefine >= 0 => false
     * undefine < 0 => false
     */

    if (event.menuItem.items && event.menuItem.items.length > 0 && !(this.activeTab >= 0)) {
        this.activeTab = event.menuItem._tabIndex;
    }
    else {
        event.isLeaf = (!event.menuItem.items || !event.menuItem.items.length);
        this.emit('press', event, this);
    }
};

HMenu.eventHandler.enterItem = function (event) {
    if (this.activeTab >= 0) {
        this.activeTab = event.menuItem._tabIndex;
    }
};


HMenu.eventHandler.clickSomewhere = function (event) {
    // if (EventEmitter.hitElement(this, event)) return;
    this.activeTab = -1;
    // window.removeEventListener('blur', this.eventHandler.clickSomewhere);
};


HMenu.prototype._childFromItems = function (items) {
    this.clearChild();
    this.$items = items.map(function (item, index) {
        var res = _({
            tag: 'hmenuitem',
            props: Object.assign({ _tabIndex: index }, item),
            on: {
                press: { callback: this.eventHandler.pressItem, cap: true },
                enter: { callback: this.eventHandler.enterItem, cap: true }
            }
        });
        this.addChild(res);
        return res;
    }.bind(this));
};

HMenu.prototype.init = function (props) {
    Object.assign(this, props || {});
};


HMenu.property = {};
HMenu.property.items = {
    set: function (items) {
        this._childFromItems(items || []);
    },
    get: function () {
        return this.$items;
    }
};


HMenu.property.activeTab = {
    /***
     * @this HMenu
     * @param tabIndex
     */
    set: function (tabIndex) {
        var lastValue = this._activeTab;
        this._activeTab = tabIndex;
        for (var i = 0; i < this.$items.length; ++i) {
            var item = this.$items[i];
            item.show = i == tabIndex && !item.disable;
            item.activeTab = -1;
            if (i == tabIndex && !item.disable) {
                item.$button && item.items && item.items.length > 0 && item.$button.addClass('absol-hmenu-button-hover');
            }
            else {
                item.$button && item.$button.removeClass('absol-hmenu-button-hover');
            }
        }
        if (!(lastValue >= 0) && (this._activeTab >= 0)) {
            if (this.blurTrigger){
                this.blurTrigger.destroy();
            }

            this.blurTrigger = new _tool_BlurTrigger__WEBPACK_IMPORTED_MODULE_7__[/* default */ "a"]([this], "click", this.eventHandler.clickSomewhere, 100, 10);

        }
        else if ((lastValue >= 0) && !(this._activeTab >= 0)) {
            if (this.blurTrigger){
                this.blurTrigger.destroy();
                this.blurTrigger = null;
            }
        }
        if (lastValue >= 0) {
            if (tabIndex >= 0 && tabIndex != lastValue) {
                this.emit('activetab', { type: 'activetab', tabIndex: tabIndex, target: this }, this);
            }
            else if (!(tabIndex >= 0)) {
                this.emit('cancel', { type: 'cancel', lastActiveIndex: lastValue, target: this }, this);
            }
        }
        else {
            if (tabIndex >= 0) {
                this.emit('activetab', { type: 'activetab', tabIndex: tabIndex, target: this }, this);
            }
        }
    },
    get: function () {
        return this._activeTab;
    }
};

/***
 * @extends AElement
 * @constructor
 */
function VRootMenu() {
    this._items = [];
    this.items = [];
}

VRootMenu.tag = 'VRootMenu'.toLowerCase();

VRootMenu.render = function () {
    return _({
        class: ['as-v-root-menu'],
        extendEvent: ['press', 'enter', 'activetab', 'cancel']
    });
};


VRootMenu.prototype._childFromItems = function (items) {
    var thisM = this;
    this.clearChild();
    this.$items = items.map(function (item, i) {
        var itemElt;
        if (typeof item === 'string' && (item.substr(0, 1) === '-' || item.substr(0, 1) === '=')) {
            itemElt = _('vmenuline');
        }
        else if (Object(absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__[/* isDomNode */ "e"])(item)) {
            itemElt = item;
        }
        else if (item.child || item.class || item.tag || item.style || typeof item === 'string') {
            itemElt = _(item);
        }
        else {
            itemElt = _({
                tag: 'vmenuitem',
                props: item,
                on: {
                    enter: thisM.eventHandler.enterItem,
                    press: thisM.eventHandler.pressItem
                }
            });
        }
        itemElt._tabIndex = i;
        thisM.addChild(itemElt);
        return itemElt;
    });
};

VRootMenu.property = Object.assign({}, HMenu.property);

VRootMenu.eventHandler = Object.assign({}, HMenu.eventHandler);


_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install([HMenu, VMenuItem, VMenu, Dropright, VMenuLine, Dropdown, HMenuItem, VRootMenu]);

/***/ }),
/* 41 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_checkboxinput_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(132);
/* harmony import */ var _css_checkboxinput_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_checkboxinput_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1);
/* harmony import */ var absol_src_HTML5_AElement__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(8);






var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;

var tickIcon = _(['<svg class="as-checkbox-input-check-icon" width="18px" height="18px" version="1.1" viewBox="0 0 18 18" xmlns="http://www.w3.org/2000/svg" >',
        ' <g transform="translate(0 -279)">',
        '  <path class="bound" d="m3 279.69h12c1.3434 0.0111 2.3298 1.5259 2.3131 2.4775v11.836c0.05005 0.89373-1.1834 2.2964-2.3131 2.3131h-12c-0.82692 0.0166-2.3131-1.1834-2.3131-2.3131v-12.237c0.0022374-1.171 0.3775-2.0759 2.3131-2.0759z" style="stroke-linejoin:round; stroke-width: 1"/>',
        '  <path class="tick" d="m3.1656 288.66c-0.10159 0.0612-0.11743 0.12506-0.12993 0.18899l3.7473 4.3467c0.066638 0.0459 0.11813 0.0263 0.16832 1e-3 0 0 1.7699-4.2166 4.7251-7.4568 1.4783-1.6208 3.2406-3.3659 3.2406-3.3659 0.0054-0.14125-0.10946-0.15807-0.1754-0.22551 0 0-2.5832 1.6364-4.7524 3.8336-1.8697 1.8939-3.6666 4.4016-3.6666 4.4016z"/>',
        '  <path class="minus" d="m4 287 h10 v2 h-10z"/>',
        ' </g>',
        '</svg>'
    ].join('')
);


/***
 * @extends AElement
 * @constructor
 */
function CheckboxInput() {
    this.$input = $('input', this)
        .on('change', this.notifyChange.bind(this));
    this.checked = false;
    this.disabled = false;
    this.on('click', this.eventHandler.click);
    this.onchange = null;
}

CheckboxInput.tag = "CheckboxInput".toLowerCase();

CheckboxInput.render = function (data) {
    return _({
            tag: 'label',
            extendEvent: 'change',
            class: 'as-checkbox-input',
            child: [
                {
                    elt: data && data.$input,
                    tag: 'input',
                    class: 'as-checkbox-input-value',
                    attr: {
                        type: 'checkbox'
                    }
                },
                tickIcon.cloneNode(true)
            ]
        }
    )
};

/***
 * as normal, change event will be fired when checkbox change by system
 */
CheckboxInput.prototype.notifyChange = function () {
    var event = {checked: this.checked};
    this.emit('change', event, this);
};

CheckboxInput.prototype._updateCheckedClass = function () {
    if (this.checked) {
        this.addClass('as-checked');
    } else {
        this.removeClass('as-checked');
    }
};


CheckboxInput.property = {};

CheckboxInput.property.disabled = {
    set: function (value) {
        if (value) {
            this.addClass('as-disabled');
        } else {
            this.removeClass('as-disabled');
        }
        this.$input.disabled = !!value;
    },
    get: function () {
        return this.$input.disabled;
    }
};

/***
 *
 * @type {CheckboxInput}
 */
CheckboxInput.property.checked = {
    set: function (value) {
        this.$input.checked = !!value;
        this._updateCheckedClass();
    },
    get: function () {
        return this.$input.checked;
    }
}

CheckboxInput.attribute = {
    checked: {
        set: function (value) {
            if (value === 'false' || value === null) {
                this.checked = false;
            } else {
                this.checked = true;
            }
        },
        get: function () {
            return this.checked ? 'true' : 'false'
        },
        remove: function () {
            this.checked = false;
        }
    },
    disabled: {
        set: function (value) {
            if (value === 'false' || value === null) {
                this.disabled = false;
            } else {
                this.disabled = true;
            }
        },
        get: function () {
            return this.disabled ? 'true' : 'false'
        },
        remove: function () {
            this.disabled = false;
        }
    }
};

/***
 *
 * @type {CheckboxInput}
 */
CheckboxInput.eventHandler = {};

CheckboxInput.eventHandler.click = function () {
    this._updateCheckedClass();
};


_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(CheckboxInput);


CheckboxInput.autoReplace = function () {
    var placeHolders = Array.prototype.slice.call(document.getElementsByTagName(this.tag));
    var ph;
    var attOfPH;
    var attrs;
    var style;
    var classList;
    var attNode;
    var attrName, attrValue;
    var props;
    for (var i = 0; i < placeHolders.length; ++i) {
        ph = placeHolders[i];
        attOfPH = ph.attributes;
        classList = [];
        style = {};
        attrs = {};
        props = {};
        for (var j = 0; j < attOfPH.length; ++j) {
            attNode = attOfPH[j];
            attrName = attNode.nodeName;
            attrValue = attNode.nodeValue;
            if (attrName == 'style') {
                attrValue.trim().split(';').reduce(function (style, prop) {
                    var p = prop.split(':');
                    if (p.length == 2) {
                        style[p[0].trim()] = p[1].trim();
                    }
                    return style;
                }, style);
            } else if (attrName == 'class') {
                classList = attrValue.trim().split(/\s+/);
            } else if (attrName == 'onchange') {
                props.onchange = new Function('event', 'sender', attrValue);
            } else {
                attrs[attrName] = attrValue;
            }
        }
        var newElt = _({
            tag: this.tag,
            attr: attrs,
            class: classList,
            style: style,
            props: props
        });
        $(ph).selfReplace(newElt);
    }
};

CheckboxInput.initAfterLoad = function () {
    absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__[/* default */ "b"].documentReady.then(function () {
        CheckboxInput.autoReplace();
    })
};


/* harmony default export */ __webpack_exports__["a"] = (CheckboxInput);

/***/ }),
/* 42 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2);
/* harmony import */ var absol_src_HTML5_AElement__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(8);
/* harmony import */ var absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(3);






var _ = _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].$;


/***
 * @extends AElement
 * @constructor
 */
function SelectBoxItem() {
    this._themeClassName = null;
    this.$text = $('.absol-selectbox-item-text', this);
    this.$close = $('.absol-selectbox-item-close', this);
    this.$close.on('click', this.eventHandler.clickClose);
    this.on('click', this.eventHandler.click);
};

SelectBoxItem.tag = 'SelectBoxItem'.toLowerCase();
SelectBoxItem.render = function () {
    return _({
        class: ['absol-selectbox-item'],
        extendEvent: ['close', 'press'],
        child: [
            '.absol-selectbox-item-text',
            {
                class: 'absol-selectbox-item-close',
                child: '<span class="mdi mdi-close"></span>'
            }
        ]
    });
};


SelectBoxItem.eventHandler = {};
SelectBoxItem.eventHandler.clickClose = function (event) {
    this.emit('close', event);
};

SelectBoxItem.eventHandler.click = function (event) {
    if (!absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_3__[/* default */ "b"].hitElement(this.$close, event)) {
        this.emit('press', event, this);
    }
};

SelectBoxItem.property = {};

SelectBoxItem.property.data = {
    set: function (value) {
        this._data = value;
        this.$text.clearChild();
        this.$text.addChild(_('<span>' + this.text + '</span>'));
        if (value && value.desc) {
            this.attr('title', value.desc);
        } else {
            this.attr('title', undefined);
        }
        if (this._themeClassName) this.removeClass(this._themeClassName);
        this._themeClassName = null;
        if (this.theme) {
            this._themeClassName = 'as-theme-' + this.theme;
            this.addClass(this._themeClassName);
        }
    },
    get: function () {
        return this._data;
    }
};

SelectBoxItem.property.text = {
    get: function () {
        if (typeof this._data == 'string')
            return this._data;
        else return this._data.text;
    }
};

SelectBoxItem.property.value = {
    get: function () {
        if (typeof this._data == 'string')
            return this._data;
        else return this._data.value;
    }
};

SelectBoxItem.property.theme = {
    get: function () {
        return this._data.theme || null;
    }
};

SelectBoxItem.property.active = {
    set: function (value) {
        if (value) {
            this.addClass('as-active');
        } else {
            this.removeClass('as-active');
        }
    },
    get: function () {
        return this.containsClass('as-active');
    }
};


_ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].install(SelectBoxItem);

/* harmony default export */ __webpack_exports__["a"] = (SelectBoxItem);

/***/ }),
/* 43 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* unused harmony export ContextCaptor */
/* harmony import */ var _css_contextmenu_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(138);
/* harmony import */ var _css_contextmenu_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_contextmenu_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1);
/* harmony import */ var absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(9);
/* harmony import */ var _Menu__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(40);
/* harmony import */ var absol_src_HTML5_AElement__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(8);
/* harmony import */ var _BoardTable__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(71);
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(4);
/* harmony import */ var absol_src_Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(10);











var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;

var supportContextEvent = false;
var isMobile = absol_src_Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].isMobile;


/**
 * @extends AElement
 * @constructor
 */
function ContextCaptor() {
    this.attachedElt = null;
    this.$textarea = $('textarea', this)
        .attr('readonly', 'true')
        .on('contextmenu', this.eventHandler.contextmenu, true);
    this._ss = 0;
    this._isTouch = false;
    /**
     this._target = null;
     * @type {Vec2}
     */
    this._posStart = null;
    /**
     * @type {Vec2}
     */
    this._posCurrent = null;
    this._touchId = -100;
    this._longPressTimeout = -1;
    this._removeTimeout = -1;
    this._fireContextMenuTimeout = -1;
    this.$target = null;
    this._pointerSession = 0;
    this._lastContextSession = 0;

    this.mousedownEvent = null;
    this.sync = Promise.resolve();
};

ContextCaptor.prototype.attachTo = function (elt) {
    if (this.attachedElt) {
        this.attachedElt.removeEventListener('mousedown', this.eventHandler.mousedown);
        this.attachedElt.removeEventListener('touchstart', this.eventHandler.mousedown);
        this.attachedElt = null;
    }
    this.attachedElt = elt;
    if (this.attachedElt) {
        this.attachedElt.addEventListener('mousedown', this.eventHandler.mousedown);
        this.attachedElt.addEventListener('touchstart', this.eventHandler.mousedown);
    }
    return this;
};

ContextCaptor.tag = 'ContextCaptor'.toLowerCase();

ContextCaptor.render = function () {
    return _({
        class: ['absol-context-menu-anchor'],
        extendEvent: 'requestcontextmenu',
        child: [
            'textarea'
        ]
    });
};

ContextCaptor.prototype.showContextMenu = function (x, y, props, onSelectItem) {
    var self = this;
    var anchor = _('.as-context-menu-ctn.absol-context-menu-anchor' + (isMobile ? '.as-anchor-modal' : '')).addTo(document.body);
    var finish = function (event) {
        (document.body).off('click', finish)
            .off('touchcancel', finish)
            .off('touchend', finish)
            .off('contextmenu', finish);
        anchor.off('click', touchModal);


        self.off('requestcontextmenu', finish);
        setTimeout(function () {
            anchor.selfRemove();//
        }, 10);
    };

    function touchModal(event){
        if (event.target.classList && event.target.classList.contains('as-anchor-modal')){
            finish(event);
        }
    }
    var vmenu = _({
        tag: 'vmenu',
        props: props,
        on: {
            press: onSelectItem || function () {
            }
        }
    }).addTo(anchor);


    setTimeout(function () {
        if (!isMobile) {
            var screenSize = absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_3__[/* default */ "b"].getScreenSize();
            var menuBound = vmenu.getBoundingClientRect();
            if (x + menuBound.width > screenSize.width - 17) {
                x -= menuBound.width;
            }
            if (y + menuBound.height > screenSize.height - 17) {
                y -= menuBound.height;
            }

            anchor.addStyle({
                left: x + 'px',
                top: y + 'px'
            });
        }
        anchor.addClass('absol-active');
    }, 30);


    setTimeout(function () {
        $(document.body).on('click', finish)
            .on('contextmenu', finish);
        self.on('requestcontextmenu', finish);
        anchor.on('click', touchModal);
    }, 10)
};

ContextCaptor.prototype._checkNeedHandle = function (target) {
    var current = target;
    var needHandle = false;
    while (current && !needHandle && !current.classList.contains('as-system-context-menu')) {
        if (current.isSupportedEvent && current.isSupportedEvent('contextmenu'))
            needHandle = true;
        current = current.parentElement;
    }
    return needHandle;
};


ContextCaptor.prototype._fireContextMenuEvent = function () {
    if (this._lastContextSession >= this._pointerSession) return false;// prevent fire multi-times in a pointer session
    var showed = false;
    this._lastContextSession = this._pointerSession;
    var baseEventData = {
        clientX: this._posCurrent.x,
        clientY: this._posCurrent.y,
        target: this.$target
    };
    this.emit('requestcontextmenu', baseEventData, this);
    var self = this;

    var propagation = true;
    var localEvent = Object.assign({
        clientX: this._posCurrent.x, clientY: this._posCurrent.y,
        target: this.$target,
        showContextMenu: function (props, onSelectItem) {
            showed = true;
            self.sync = self.sync.then(function () {
                return new Promise(function (rs) {
                    setTimeout(function () {
                        self.showContextMenu(self._posCurrent.x, self._posCurrent.y, props, onSelectItem);
                        rs();
                    }, 30)
                });
            })
        },
        stopPropagation: function () {
            propagation = false;
        }
    }, baseEventData);

    Object.defineProperty(localEvent, 'selectedText', {
        get: function () {
            return Object(_utils__WEBPACK_IMPORTED_MODULE_8__["getSelectionText"])();
        }
    });

    var current = this.$target;
    while (current && propagation) {
        if (current.isSupportedEvent && current.isSupportedEvent('contextmenu')) {
            current.emit('contextmenu', localEvent, current, this);
        }
        current = current.parentElement;
    }
    return showed;
};

/**
 * @type {ContextCaptor}
 */
ContextCaptor.eventHandler = {};

ContextCaptor.eventHandler.mousedown = function (event) {
    if (this._touchId != -100) return;
    this._pointerSession++;
    var target;
    var isTouch;
    var touchId;
    var posCurrent;
    var pointer;
    if (event.type == 'touchstart') {
        isTouch = true;
        pointer = event.changedTouches[0];
        touchId = pointer.identifier;
    }
    else {
        isTouch = false;
        touchId = -1;
        pointer = event;
    }
    target = pointer.target;

    posCurrent = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_4__[/* default */ "a"](pointer.clientX, pointer.clientY);

    if (isTouch) {
        var dragzone = _BoardTable__WEBPACK_IMPORTED_MODULE_7__[/* default */ "a"].prototype._findDragZone(target);
        if (dragzone) return;
        var thisCT = this;
        this._longPressTimeout = setTimeout(function () {
            if (!thisCT._checkNeedHandle(target)) return;
            if (thisCT._removeTimeout > 0) {
                clearTimeout(thisCT._removeTimeout);
                thisCT._removeTimeout = -1;
            }

            thisCT._ss++;
            thisCT.moveTo(thisCT._posCurrent);
            thisCT.active(true);
            thisCT._longPressTimeout = -1;
            if (thisCT._fireContextMenuTimeout >= 0) {
                clearTimeout(thisCT._fireContextMenuTimeout);
            }
            // show if device not support contextmenu event (after 700ms)
            thisCT._fireContextMenuTimeout = setTimeout(function () {
                if (!supportContextEvent) {
                    thisCT._fireContextMenuEvent();
                }
            }, 300);
        }, 400);
        this.$target = target;
        this._isTouch = isTouch;
        this._touchId = touchId;
        this._posCurrent = posCurrent;
        this._posStart = posCurrent;
        $(document.body).on('touchmove', thisCT.eventHandler.mousemove)
            .on('touchend', thisCT.eventHandler.mousefinish)
            .on('touchcancel', thisCT.eventHandler.mousefinish);

    }
    else {
        if (absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_2__[/* default */ "b"].isMouseRight(event) && this._checkNeedHandle(target)) {
            if (this._removeTimeout > 0) {
                clearTimeout(this._removeTimeout);
                this._removeTimeout = -1;
            }
            this.$target = target;
            this._isTouch = isTouch;
            this._posCurrent = posCurrent;
            this._posStart = posCurrent;
            this._touchId = touchId;
            this._ss++;
            this.moveTo(this._posCurrent);
            this.active(true);

            $(document.body).on('mousemove', this.eventHandler.mousemove)
                .on('mouseup', this.eventHandler.mousefinish)
                .on('mouseleave', this.eventHandler.mousefinish);
        }
    }
};

/**
 * @param {Vec2} pos
 */
ContextCaptor.prototype.moveTo = function (pos) {
    this.addStyle({
        left: pos.x - 80 + 'px',
        top: pos.y - 80 + 'px'
    });
};

ContextCaptor.prototype.active = function (flag) {
    if (flag)
        this.addClass('absol-active');
    else
        this.removeClass('absol-active');
};

ContextCaptor.eventHandler.mousemove = function (event) {
    var isTouch = this._isTouch;
    var touchId;
    var pointer;
    var posCurrent;
    if (isTouch) {
        pointer = event.changedTouches[0];
        touchId = pointer.identifier;
    }
    else {
        isTouch = false;
        touchId = -1;
        pointer = event;
    }

    if (touchId != this._touchId) return;
    posCurrent = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_4__[/* default */ "a"](pointer.clientX, pointer.clientY);
    this._posCurrent = posCurrent;
    if (isTouch) {
        if (this._posStart.sub(posCurrent).abs() > 10) this.eventHandler.mousefinish(event);
    }
    this.moveTo(posCurrent);
};


ContextCaptor.eventHandler.mousefinish = function (event) {

    var isTouch = this._isTouch;
    var touchId;
    var pointer;

    if (isTouch) {
        pointer = event.changedTouches[0];
        touchId = pointer.identifier;
    }
    else {
        isTouch = false;
        touchId = -1;
        pointer = event;

    }
    if (touchId != this._touchId) return;
    if (isTouch) {
        $(document.body).off('touchmove', this.eventHandler.mousemove)
            .off('touchend', this.eventHandler.mousefinish)
            .off('touchcancel', this.eventHandler.mousefinish);
        if (this._longPressTimeout > 0) {
            clearTimeout(this._longPressTimeout);
            this._longPressTimeout = -1;
        }
    }
    else {
        $(document.body).off('mousemove', this.eventHandler.mousemove)
            .off('mouseup', this.eventHandler.mousefinish)
            .off('mouseleave', this.eventHandler.mousefinish);
    }

    this._touchId = -100;
    if (this._fireContextMenuTimeout >= 0) {
        clearTimeout(this._fireContextMenuTimeout);
    }
    var thisCT = this;
    this._removeTimeout = setTimeout(function () {
        thisCT.active(false);
        thisCT._removeTimeout = -1;

    }, 1);
};

ContextCaptor.eventHandler.contextmenu = function (event) {
    supportContextEvent = true;
    event.preventDefault();
    this._fireContextMenuEvent();

};


ContextCaptor.auto = function () {
    if (ContextCaptor.$elt) return;
    ContextCaptor.$elt = _('contextcaptor');
    absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_3__[/* default */ "b"].documentReady.then(function () {
        ContextCaptor.$elt.addTo(document.body);
        ContextCaptor.$elt.attachTo(document.body);
    });
};

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(ContextCaptor);

/* harmony default export */ __webpack_exports__["a"] = (ContextCaptor);

/***/ }),
/* 44 */
/***/ (function(module, exports) {

var g;

// This works in non-strict mode
g = (function() {
	return this;
})();

try {
	// This works if eval is allowed (see CSP)
	g = g || new Function("return this")();
} catch (e) {
	// This works if the window reference is available
	if (typeof window === "object") g = window;
}

// g can still be undefined, but nothing to do about it...
// We return undefined, instead of nothing here, so it's
// easier to handle this case. if(!global) { ...}

module.exports = g;


/***/ }),
/* 45 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* unused harmony export makeItem */
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return requireItem; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return releaseItem; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return measureMaxDescriptionWidth; });
/* unused harmony export measureMaxTextWidth */
/* unused harmony export measureListHeight */
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return measureListSize; });
/* harmony import */ var _css_selectlist_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(93);
/* harmony import */ var _css_selectlist_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_selectlist_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(4);
/* harmony import */ var _SelectListItem__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(46);
/* harmony import */ var absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(3);
/* harmony import */ var absol_src_HTML5_AElement__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(8);








var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;

var isSupportedVar = window.CSS && window.CSS.supports && window.CSS.supports('--fake-var', 'red');
/**
 * Setup css
 */
if (isSupportedVar) {
    SelectList.$dynamicStyle = (function () {
        var cssElt = _('style#selectlist-dynamic-style');
        var cssCode = [
            '.absol-selectlist-item>span {',
            '    margin-right: calc(0.35em + var(--select-list-desc-width));',
            '}',

            '.absol-selectlist-item-desc-container {',
            '    width: var(--select-list-desc-width);',
            '}'

        ];

        cssElt.innerHTML = cssCode.join('\n');
        cssElt.addTo(document.head);
        return cssElt;
    })();
}

var itemPool = [];

function onMousedownItem(event) {
    if (absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].isMouseRight(event)) return;
    var thisSL = this.$parent;
    if (thisSL) {
        thisSL.value = this.value;
        thisSL.emit('pressitem', {
            type: 'pressitem',
            target: thisSL,
            itemElt: this,
            value: this.value,
            data: this.data
        });
    }
}

function makeItem() {
    return _({
        tag: 'selectlistitem',
        on: {
            mousedown: onMousedownItem
        }
    });
}

function requireItem($parent) {
    var item;
    if (itemPool.length > 0) {
        item = itemPool.pop();
    } else {
        item = makeItem();
    }
    item.$parent = $parent;
    return item;
}

function releaseItem(item) {
    item.$parent = null;
    item.removeClass('selected');
    itemPool.push(item);
};


function measureMaxDescriptionWidth(items) {
    var maxDescWidth = 0;
    var maxText = 0;
    var maxEst = 0;
    var est;
    for (var i = 0; i < items.length; ++i) {
        if (items[i].desc) {
            est = Object(_utils__WEBPACK_IMPORTED_MODULE_2__["estimateWidth14"])(items[i].desc);
            if (est > maxEst) {
                maxEst = est;
                maxText = items[i].desc;
            }
        }
    }
    if (maxText)
        maxDescWidth = Object(_utils__WEBPACK_IMPORTED_MODULE_2__["measureText"])(maxText, 'italic 14px  sans-serif').width;
    return maxDescWidth;
};


function measureMaxTextWidth(items) {
    var maxTextWidth = 0;
    var maxText = 0;
    var maxEst = 0;
    var maxLv = 0;
    var est;
    var text;
    var item;
    for (var i = 0; i < items.length; ++i) {
        item = items[i];
        if (item.text) {
            text = item.text;
            est = Object(_utils__WEBPACK_IMPORTED_MODULE_2__["estimateWidth14"])(text) + 14 * 0.9 * (item.level || 0);
            if (est > maxEst) {
                maxEst = est;
                maxText = text;
                maxLv = item.level || 0;
            }
        }
    }
    if (maxText)
        maxTextWidth = 14 * 0.9 * maxLv + Object(_utils__WEBPACK_IMPORTED_MODULE_2__["measureText"])(maxText, '14px Arial, Helvetica, sans-serif').width + 14;//padding left, right 7px
    return maxTextWidth;
}

function measureListHeight(items) {
    var border = 0;
    var n = items.length - 1;
    return items.length * 20 + border;
}

function measureListSize(items) {
    var descWidth = measureMaxDescriptionWidth(items);
    var textWidth = measureMaxTextWidth(items);
    var width = textWidth;
    if (descWidth > 0) {
        width += descWidth + 14;
    }
    var height = measureListHeight(items);
    return {
        width: width,
        height: height,
        descWidth: descWidth,
        textWidth: textWidth
    };
}

/*global absol*/
/***
 * @extends AElement
 * @constructor
 */
function SelectList() {
    var thisSL = this;
    this.defineEvent(['pressitem', 'cancelasync', 'valuevisibilityasync', 'finishasync', 'sizechangeasync']);
    this.$attachhook = _('attachhook').addTo(this);
    this.sync = new Promise(function (rs) {
        thisSL.$attachhook.once('error', rs);
    });
    this.$items = [];
    this.$itemByValue = {};//quick find element
    this.$selectedItem = undefined;
    this.measuredSize = {
        width: 0,
        height: 0,
        descWidth: 0,
        textWidth: 0
    };

    this._itemSession = 0;
    this._finished = true;

};

SelectList.tag = "SelectList".toLowerCase();

SelectList.render = function () {
    return _('.absol-selectlist');
};

SelectList.prototype._updateSelectedItem = function () {
    var newSelectedItemElt = this.$itemByValue[this._selectValue];
    if (newSelectedItemElt != this.$selectedItem) {
        if (this.$selectedItem) {
            this.$selectedItem.removeClass('selected');
        }
        if (newSelectedItemElt) {
            newSelectedItemElt.addClass('selected');
            this.$selectedItem = newSelectedItemElt;
        }
    }
};


SelectList.prototype._requireItems = function (itemCout) {
    var item;
    while (this.$items.length < itemCout) {
        item = requireItem(this);
        this.$items.push(item);
        this.addChild(item);
    }

    while (this.$items.length > itemCout) {
        item = this.$items.pop();
        item.remove();
        releaseItem(item);
    }
};

SelectList.prototype._assignItems = function (from, to) {
    var foundSelected = false;
    var itemElt;
    var item;
    for (var i = from; i < to; ++i) {
        itemElt = this.$items[i];
        item = this._items[i];
        itemElt.data = item;
        itemElt.__index__ = i;
        if (this.$itemByValue[item.value]) {
            console.warn('Value  ' + this.$items[i].value + ' is duplicated!');
        } else {
            this.$itemByValue[item.value] = itemElt;
            if (this._selectValue == item.value) {
                itemElt.addClass('selected');
                this.$selectedItem = itemElt;
                foundSelected = true;
            } else {
                itemElt.removeClass('selected');
            }
        }
    }
    return foundSelected;
};


SelectList.prototype.setItemsAsync = function (items) {
    //start process
    this._finished = false;
    var session = Math.floor(Math.random() * 1000000);
    this._itemSession = session;
    this._items = items || [];
    this.$itemByValue = {};
    this.measuredSize = measureListSize(items);
    this.style.setProperty('--select-list-desc-width', this.measuredSize.descWidth + 'px'); //addStyle notWork because of convert to cameCase 

    var thisSL = this;
    var i = 0;
    var limit = 20;

    function tick() {
        if (thisSL._itemSession != session) {
            thisSL.emit('cancelasync', {session: session, type: 'cancelasync'}, this);
            return;
        }
        if (i >= items.length) {
            thisSL._updateSelectedItem();
            thisSL._finished = false;
            thisSL.emit('finishasync', {session: session, type: 'finishasync'}, this);
            return;
        }

        var n = Math.min(items.length - i, limit);
        var itemCout = i + n;
        thisSL._requireItems(itemCout);
        i = itemCout;

        var foundSelected = thisSL._assignItems(itemCout - n, itemCout);
        if (foundSelected) {
            thisSL.emit('valuevisibilityasync', {
                session: session,
                type: 'valuevisibilityasync',
                itemElt: thisSL.$items[i]
            }, thisSL);
        }

        thisSL.emit('sizechangeasync', {session: session, type: 'sizechangeasync'}, this);
        setTimeout(tick, 2);
    }

    setTimeout(tick, 2);
    return Object.assign({session: session}, this.measuredSize);
};


SelectList.prototype.setItems = function (items) {
    this._finished = false;
    var session = Math.floor(Math.random() * 1000000);
    this._itemSession = session;
    this._items = items || [];
    this.$itemByValue = {};
    this.measuredSize = measureListSize(items);
    this.style.setProperty('--select-list-desc-width', this.measuredSize.descWidth + 'px'); //addStyle notWork because of convert to cameCase 
    var itemCount = items.length;
    this._requireItems(itemCount);
    this._assignItems(0, itemCount);

    this._finished = true;
    return {
        session: this._itemSession,
        width: this._descWidth + this._textWidth + 14,
        height: this._height
    }
};


SelectList.property = {};

/**
 * @type {SelectList}
 */
SelectList.property.items = {
    set: function (value) {
        value = value || [];
        this.setItems(value);
    },
    get: function () {
        return this._items || [];
    }
};


SelectList.property.value = {
    set: function (value) {
        this._selectValue = value;
        this._updateSelectedItem();
    },

    get: function () {
        return this._selectValue;
    }
};

SelectList.property.item = {
    get: function () {
        if (this.$selectedItem) return this.$selectedItem.data;
        return undefined;
    }
};


SelectList.property.selectedIndex = {
    get: function () {
        throw new Error("selectedIndex getter is deprecated");
    }
};


SelectList.prototype.init = function (props) {
    props = props || {};
    var value = props.value;
    delete props.value;
    this.super(props);
    if (value !== undefined)
        this.value = value;
};

SelectList.eventHandler = {};

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(SelectList);


/* harmony default export */ __webpack_exports__["a"] = (SelectList);




/***/ }),
/* 46 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return getTextOfListItem; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return getValueOfListItem; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return getDescriptionOfListItem; });
/* harmony import */ var _css_selectlist_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(93);
/* harmony import */ var _css_selectlist_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_selectlist_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var _CheckboxButton__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(61);




var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;

/***
 *
 * @extends AElement
 * @constructor
 */
function SelectListItem() {
    var res = this;
    res.$text = $('span.absol-selectlist-item-text', res);
    res.$textValue = res.$text.childNodes[0];
    res.$descCtn = $('.absol-selectlist-item-desc-container', res);
    res.$desc = $('span.absol-selectlist-item-desc', res.$descCtn);
    res.$descValue = res.$desc.childNodes[0];
    res._extendClasses = [];
    res._extendStyle = {};
    res._data = "";
    res._level = 0;
}

SelectListItem.render = function () {
    return _({
        class: 'absol-selectlist-item',
        child: [
            {
                tag: 'span',
                class: 'absol-selectlist-item-text',
                child: {text: ''}
            },
            {
                class: 'absol-selectlist-item-desc-container',
                child: {
                    tag: 'span',
                    class: 'absol-selectlist-item-desc',
                    child: {text: ''}
                }
            }
        ]
    })
};


SelectListItem.property = {};


SelectListItem.property.extendClasses = {
    set: function (value) {
        var i;
        for (i = 0; i < this._extendClasses.length; ++i) {
            this.removeClass(this._extendClasses[i]);
        }
        this._extendClasses = [];
        if (typeof value == 'string') value = value.trim().split(/\s+/);
        value = value || [];
        for (i = 0; i < value.length; ++i) {
            this._extendClasses.push(value[i]);
            this.addClass(value[i]);
        }
    },
    get: function () {
        return this._extendClasses;
    }
};

SelectListItem.property.extendStyle = {
    set: function (value) {
        this.removeStyle(this._extendStyle);
        this._extendStyle = Object.assign({}, value || {});
        this.addStyle(this._extendStyle);
    },
    get: function () {
        return this._extendClasses;
    }
};


SelectListItem.property.data = {
    set: function (value) {
        this._data = value;
        if (typeof value == 'string') {
            this.$textValue.data = value;
            this.$descValue.data = '';
            this.level = 0;
            this.extendClasses = '';
            this.extendStyle = {};
            this.lastInGroup = false;
            this.isLeaf = false;
            this.selected = false;
        } else {
            this.$textValue.data = value.text || '';
            this.$descValue.data = value.desc || '';
            this.level = value.level || 0;

            this.extendClasses = value.extendClasses;
            this.extendStyle = value.extendStyle;
            this.lastInGroup = !!(value.lastInGroup);
            this.isLeaf = !!(value.isLeaf);
            this.selected = !!(value.selected);
        }
    },
    get: function () {
        return this._data;
    }
};

SelectListItem.property.value = {
    get: function () {
        return getValueOfListItem(this._data);
    }
};

SelectListItem.property.text = {
    get: function () {
        return getTextOfListItem(this._data);
    }
};

SelectListItem.property.desc = {
    get: function () {
        return getDescriptionOfListItem(this._data);
    }
};


SelectListItem.property.level = {
    set: function (value) {
        value = value || 0;
        this._level = value;
        this.$text.addStyle('margin-left', value * 0.9 + 'em');
    },
    get: function () {
        return this._level;
    }
};


SelectListItem.property.lastInGroup = {
    set: function (value) {
        if (value) {
            this.addClass('as-last-in-group');
        } else {
            this.removeClass('as-last-in-group');
        }
    },
    get: function () {
        return this.containsClass('as-last-in-group');
    }
};

SelectListItem.property.isLeaf = {
    set: function (value) {
        if (value) {
            this.addClass('as-is-leaf');
        } else {
            this.removeClass('as-is-leaf');
        }
    },
    get: function () {
        return this.containsClass('as-is-leaf');
    }
};

SelectListItem.property.selected = {
    set: function (value) {
        if (value) {
            this.addClass('as-selected');
        } else {
            this.removeClass('as-selected');
        }
    },
    get: function () {
        return this.containsClass('as-selected');
    }
};

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install('SelectListItem'.toLowerCase(), SelectListItem);


/* harmony default export */ __webpack_exports__["a"] = (SelectListItem);


function getTextOfListItem(item) {
    if (item) {
        if (item.match) {

        } else if (item.text && item.text.match) {
            return item.text;
        } else return '';
    } else return '';
}

function getValueOfListItem(item) {
    if (item) {
        if (item.match) {
            return item;
        } else if (typeof item === "object")
            return item.value;
        else
            return item;
    } else return item;
}

function getDescriptionOfListItem(item) {
    return (item && (typeof item == "object")) ? item.desc : undefined;
}


/***/ }),
/* 47 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
function JSPath(props) {
    this.path = props.path;
}


/**
 *
 * @param {Element} element
 * @returns {Boolean}
 */
JSPath.prototype.match = function (element, query) {
    if (query.id) {
        if (!element.getAttribute || element.getAttribute('id') != query.id) return false;
    }
    if (query.tagName) {
        var matchTag = false;
        if (element._azar_extendTags && element._azar_extendTags[query.tagName]) matchTag = true;
        matchTag = matchTag || ((element.tagName || '').toUpperCase() == query.tagName.toUpperCase());
        if (!matchTag) return false;
    }
    if (query.classList)
        for (var i = 0; i < query.classList.length; ++i) {
            if (!element.classList || !element.classList.contains(query.classList[i])) return false;
        }
    if (query.attributes) {
        for (var key in query.attributes) {
            var value;
            if (element.attr) {
                value = element.attr(key);
                if (value != query.attributes[key]) return false;
            }
            else if (element.getAttribute) {
                value = element.getAttribute(key);
                if (value != query.attributes[key]) return false;
            }
        }
    }
    return true;
};

/**
 * Warning : still fail in some testcase
 */
JSPath.prototype.findFirst = function (root, onFound) {
    var queue = [{ e: root, i: 0 }];
    var current;

    while (queue.length > 0) {
        current = queue.shift();
        var isMathed = false;
        var currentElt = current.e;
        var currentI = current.i;
        if (this.match(currentElt, this.path[currentI])) {
            if (this.path[currentI].childCombinate) {
                var trackI = currentI;
                var trackElement = currentElt;
                var isTrackMatch = true;
                while (isTrackMatch && trackI > 0 && this.path[trackI].childCombinate) {
                    if (!trackElement.parentNode || !this.match(trackElement.parentNode, this.path[trackI - 1])) {
                        isTrackMatch = false;
                    }
                    else {
                        trackElement = trackElement.parentNode;
                        trackI--;
                    }
                }
                if (isTrackMatch) isMathed = true;
            }
            else {
                isMathed = true;
            }
        }


        if (isMathed && currentI + 1 == this.path.length) {
            if (!onFound || (onFound && onFound(currentElt)))
                return currentElt;
        }

        if (currentElt.childNodes) {
            var l = currentElt.childNodes.length;
            for (var i = 0; i < l; ++i) {
                if (currentElt.childNodes[i].tagName)
                    queue.push({
                        e: currentElt.childNodes[i],
                        i: currentI + (isMathed && currentI + 1 < this.path.length ? 1 : 0)
                    });
            }
        }
    }
    return undefined;
};


JSPath.prototype.findAll = function (root, onFound) {
    var res = [];
    var queue = [{ e: root, i: 0 }];
    var current;

    while (queue.length > 0) {
        current = queue.shift();
        var isMathed = false;
        var currentElt = current.e;
        var currentI = current.i;
        if (this.match(currentElt, this.path[currentI])) {
            if (this.path[currentI].childCombinate) {
                var trackI = currentI;
                var trackElement = currentElt;
                var isTrackMatch = true;
                while (isTrackMatch && trackI > 0 && this.path[trackI].childCombinate) {
                    if (!trackElement.parentNode || !this.match(trackElement.parentNode, this.path[trackI - 1])) {
                        isTrackMatch = false;
                    }
                    else {
                        trackElement = trackElement.parentNode;
                        trackI--;
                    }
                }
                if (isTrackMatch) isMathed = true;
            }
            else {
                isMathed = true;
            }
        }

        if (isMathed && currentI + 1 == this.path.length) {
            if (!onFound || (onFound && onFound(currentElt)))
                res.push(currentElt);
        }

        if (currentElt.childNodes) {
            var l = currentElt.childNodes.length;
            for (var i = 0; i < l; ++i) {
                if (currentElt.childNodes[i].tagName)
                    queue.push({
                        e: currentElt.childNodes[i],
                        i: currentI + (isMathed && currentI + 1 < this.path.length ? 1 : 0)
                    });
            }
        }
    }
    return res;
};

var identRegex = /[a-zA-Z0-9\-_]+/;
var stringRegex = /"(([^"\\]*|(\\.))*)"/;
var classRegex = new RegExp('\\.' + identRegex.source);
var idRegex = new RegExp('#' + identRegex.source);
var booleanRegex = /true|false/;
var valueRegex = new RegExp(stringRegex.source + '|' + booleanRegex.source);
var attributeRegex = new RegExp('\\[\\s*(' + identRegex.source + ')\\s*(=\\s*(' + valueRegex.source + '))\\]');
var queryRegex = new RegExp([
    '(',
    identRegex.source, '|',
    attributeRegex.source, '|',
    classRegex.source, '|',
    idRegex.source,
    ')+'
].join(''));


JSPath.__tagRegex = new RegExp(queryRegex.source + '|\\>', 'g');
JSPath.__tagNameRegex = new RegExp('^' + identRegex.source, 'i');
JSPath.__classRegex = new RegExp(classRegex.source, 'g');
JSPath.__idRegex = new RegExp(idRegex.source, 'i');

JSPath.__attrRegex = new RegExp(attributeRegex.source, 'g');


JSPath.parseQuery = function (s) {
    var tag = {};

    s = s.replace(JSPath.__attrRegex, function (full, name, assign, jsonTextValue) {
        tag.attributes = tag.attributes || {};
        if (assign) {
            tag.attributes[name] = JSON.parse(jsonTextValue);
        }
        else
            tag.attributes[name] = true;
        return '';
    });

    var classList = s.match(this.__classRegex);
    var idList = s.match(this.__idRegex);
    var tagList = s.match(this.__tagNameRegex);
    if (idList && idList.length > 0) {
        tag.id = idList[0].substring(1);
    }
    if (tagList && tagList.length > 0) {
        tag.tagName = tagList[0].trim();
    }
    if (classList && classList.length > 0) {
        tag.classList = classList.map(function (s) {
            return s.substring(1)
        });
    }
    return tag;
};


/**
 * @param {String} text
 * @returns {JSPath}
 */
JSPath.compileJSPath = function (text) {
    var tagTexts = text.match(this.__tagRegex) || [''];
    var path = [];
    var childCombinate = false;
    for (var i = 0; i < tagTexts.length; ++i) {
        var s = tagTexts[i];
        if (s == '>') {
            childCombinate = true;
        }
        else {
            var tag = this.parseQuery(s);
            tag.childCombinate = childCombinate;
            path.push(tag);
            childCombinate = false;
        }
    }
    return new JSPath({
        path: path
    });
};


/* harmony default export */ __webpack_exports__["a"] = (JSPath);

/***/ }),
/* 48 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "parseStyleAttr", function() { return parseStyleAttr; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "parseClassAttr", function() { return parseClassAttr; });
/**
 * 
 * @param {String} text 
 *  @returns {Object}
 */
function parseStyleAttr(text) {
    return text.split(';').map(function (line) {
        var parts = line.split(':');
        if (parts.length < 2) return null;
        var key = parts.shift().trim();
        var value = parts.join(':').trim();
        if (key.length == 0 || value.length == 0) return null;
        return [key, value];
    }).filter(function (it) { return it != null }).reduce(function (ac, cr) {
        ac[cr[0]] = cr[1];
        return ac;
    }, {});
}

/**
 * 
 * @param {String} text 
 *  @returns {Array<String>}
 */
function parseClassAttr(text) {
    return text.trim().split(/\s+/);
}

/***/ }),
/* 49 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);


function Draggable(element) {
    if (!element) element = _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"]._('div');
    else _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].$(element);
    element.defineEvent(['predrag', 'drag', 'begindrag', 'enddrag']);
    var body = _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].$('body');
    var isMoving = false;
    var firstMove = false;
    var offsetX;
    var offsetY;
    var fontSize;
    var left0em, top0em, left0, top0;
    var finishMoving = function (event) {
        if (isMoving) {
            isMoving = false;
            body.off('mousemove', mouseMoveEventHandler);

            event.moveDX = event.clientX - offsetX;
            event.moveDY = event.clientY - offsetY;
            event.moveDXem = event.moveDX / fontSize;
            event.moveDYem = event.moveDY / fontSize;
            event.moveToX = left0 + event.moveDX;
            event.moveToY = top0 + event.moveDY;
            element.emit('enddrag', event);
        }
    };

    var mouseUpEventHandler = function (event) {
        finishMoving(event);
    };

    var mouseMoveEventHandler = function (event) {
        event.preventDefault();
        event.moveDX = event.clientX - offsetX;
        event.moveDY = event.clientY - offsetY;
        event.moveDXem = event.moveDX / fontSize;
        event.moveDYem = event.moveDY / fontSize;
        event.moveToX = left0 + event.moveDX;
        event.moveToY = top0 + event.moveDY;

        event.moveToXem = left0em + event.moveDXem;
        event.moveToYem = top0em + event.moveDYem;
        if (firstMove) {
            firstMove = false;
            element.emit('begindrag', event);
        }
        element.emit('drag', event);

    };

    var mouseOutEventHandler = function (event) {
        finishMoving(event);
    };


    var mouseDownEventHandler = function (event) {
        isMoving = true;
        firstMove = true;
        body.on('mousemove', mouseMoveEventHandler);
        body.once('mouseleave', mouseOutEventHandler);
        body.once('mouseup', mouseUpEventHandler);

        fontSize = this.getFontSize();
        offsetX = event.clientX;
        offsetY = event.clientY;
        left0 = parseFloat(element.getComputedStyleValue('left').replace('px', ''));
        top0 = parseFloat(element.getComputedStyleValue('top').replace('px', ''));
        left0em = left0 / fontSize;
        top0em = top0 / fontSize;
        event.x0 = left0;
        event.y0 = top0;
        event.y0em = left0em;
        event.y0em = top0em;
        element.emit('predrag', event);
    };

    element.on('mousedown', mouseDownEventHandler);
    return element;
};


/* harmony default export */ __webpack_exports__["a"] = (Draggable);

/***/ }),
/* 50 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_Element__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(24);





/***
 * @extends {AElement}
 * @constructor
 */
function PositionTracker() {
    this.defineEvent('positionchange');
    this.$trackScrollParents = [];
    this._scrollTrackEventHandler = this.notifyPositionChange.bind(this);
}

PositionTracker.tag = 'PositionTracker'.toLowerCase();

/***
 *
 * @return {AElement}
 */
PositionTracker.render = function () {
    return _('div');
};


PositionTracker.prototype.notifyPositionChange = function (event) {
    this.emit('positionchange', { type: 'positionchange', originEvent: event });
};

PositionTracker.prototype.startTrackPosition = function () {
    if (this.$trackScrollParents.length > 0)
        this.stopTrackPosition();
    var trackElt = this;
    while (trackElt) {
        if (trackElt.addEventListener)
            trackElt.addEventListener('scroll', this._scrollTrackEventHandler, false);
        else
            trackElt.attachEvent('onscroll', this._scrollTrackEventHandler, false);

        this.$trackScrollParents.push(trackElt);
        trackElt = trackElt.parentElement;
    }
    if (document.addEventListener) {
        document.addEventListener('scroll', this._scrollTrackEventHandler, false);
    }
    else {
        document.attachEvent('onscroll', this._scrollTrackEventHandler, false);
    }
    this.$trackScrollParents.push(document);
};

PositionTracker.prototype.stopTrackPosition = function () {
    var trackElt;
    for (var i = 0; i < this.$trackScrollParents.length; ++i) {
        trackElt = this.$trackScrollParents[i];
        if (trackElt.removeEventListener)
            trackElt.removeEventListener('scroll', this._scrollTrackEventHandler, false);
        else
            trackElt.dettachEvent('onscroll', this._scrollTrackEventHandler, false);
    }
    this.$trackScrollParents = [];
};

_ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].install(PositionTracker);

/* harmony default export */ __webpack_exports__["a"] = (PositionTracker);


/***/ }),
/* 51 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "fileExist", function() { return fileExist; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "saveAs", function() { return saveAs; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "saveTextAs", function() { return saveTextAs; });
/* harmony import */ var _Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(10);
/***
 * @typedef {{revokeTimeout?: number, autoBom?:boolean }} FileSaverOpts
 *
 */



function fileExist(url) {
    var xhr = new XMLHttpRequest();
    xhr.open('HEAD', url, true);
    return new Promise(function (resolve) {
        xhr.onreadystatechange = function () {
            if (this.readyState === 4) {
                resolve(xhr.status === 200);
            }
        };

        xhr.onerror = function (err) {};

        xhr.send();
    });
}

/***
 *
 * @param url
 * @param name
 * @param {FileSaverOpts} opts
 */
function download(url, name, opts) {
    var xhr = new XMLHttpRequest();
    xhr.open('GET', url);
    xhr.responseType = 'blob';
    xhr.onload = function () {
        saveAs(xhr.response, name, opts);
    }
    xhr.onerror = function () {
        console.error('Could not download: ' + url);
    };
    xhr.send(null);
}


function bom(blob, opts) {
    if (typeof opts === undefined)
        opts = { autoBom: false };
    else if (typeof opts !== 'object')
        opts = { autoBom: !opts };

    if (opts.autoBom && /^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(blob.type)) {
        return new Blob([String.fromCharCode(0xFEFF), blob], { type: blob.type })
    }
    return blob;
}

function corsEnabled(url) {
    var xhr = new XMLHttpRequest();
    xhr.open('HEAD', url, false);
    try {
        xhr.send();
    } catch (e) {
    }
    return xhr.status >= 200 && xhr.status < 299;
}

function click(node) {
    try {
        node.dispatchEvent(new MouseEvent('click'));
    } catch (e) {
        var evt = document.createEvent('MouseEvents');
        evt.initMouseEvent('click', true, true, window, 0, 0, 0, 80,
            20, false, false, false, false, 0, null);
        node.dispatchEvent(evt);
    }
}

function normalSaveAs(blob, name, opts) {
    var URL = window.URL || window.webkitURL;
    var a = document.createElement('a');
    name = name || blob.name || 'download';
    a.download = name;
    a.rel = 'noopener';
    if (typeof blob === 'string') {
        a.href = blob;
        if (a.origin !== location.origin) {
            if (corsEnabled(a.href)) {
                download(blob, name, opts);
            }
            else {
                a.target = '_blank';
                click(a);
            }
        }
        else {
            click(a);
        }
    }
    else {
        a.href = URL.createObjectURL(blob);
        setTimeout(function () {
        }, ((opts && opts.revokeTimeout) || 4E4));
        setTimeout(function () {
            click(a);
        }, 0);
    }
}

function msSaveAs(blob, name, opts) {
    name = name || blob.name || 'download';
    if (typeof blob === 'string') {
        if (corsEnabled(blob)) {
            download(blob, name, opts);
        }
        else {
            var a = document.createElement('a');
            a.href = blob;
            a.target = '_blank';
            setTimeout(function () {
                click(a);
            });
        }
    }
    else {
        navigator.msSaveOrOpenBlob(bom(blob, opts), name);
    }
}

function popupSaveAs(blob, name, opts, popup) {
    if (typeof blob === 'string') {
        download(blob, name, opts);
        return;
    }
    popup = popup || open('', '_blank');
    if (popup) {
        popup.document.title = name || 'download';
        popup.document.body.innerText = "downloading..."
    }
    name = name || blob.name || 'download';
    blob.name = name;
    var force = blob.type === 'application/octet-stream';
    var isSafari = _Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].isSafari;
    var isChromeIOS = _Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].isChromeIOS;
    var isMacOSWebView = _Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].isMacOSWebView;
    var isSafariUnder13 = (_Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].browser.type === 'safari' && parseFloat(_Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].browser.version) < 13);
    if ((!isChromeIOS || (force && isSafari) || isMacOSWebView)
        && typeof FileReader !== 'undefined' & !isSafariUnder13) {
        var reader = new FileReader();
        reader.onloadend = function () {
            var url = reader.result;
            url = isChromeIOS ? url : url.replace(/^data:[^;]*/, 'data:attachment/file');
            if (popup) popup.location.href = url;
            else location = url;
            popup = null;
        };
        reader.readAsDataURL(blob);
    }
    else {
        var URL = window.URL || window.webkitURL;
        var url = URL.createObjectURL(blob);
        if (popup) popup.location.href = url;
        else location.href = url;
        popup = null;
        setTimeout(function () {
            URL.revokeObjectURL(blob);
        }, (opts && opts.revokeTimeout) || 4E4);
    }
}

/***
 *
 * @param {string  | File | Blob}blob
 * @param {string=} name
 * @param {Object=} opts
 * @param {Object=} popup
 */
function saveAs(blob, name, opts, popup) {
    if (typeof window !== "object" || window !== self) {
        console.error("FileSaver is not support!")
    }
    else if ('download' in HTMLAnchorElement.prototype && !_Detector_BrowserDetector__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].isMacOSWebView) {
        normalSaveAs(blob, name, opts);
    }
    else if ('msSaveOrOpenBlob' in navigator) {
        msSaveAs(blob, name, opts);
    }
    else {
        setTimeout(function () {
            popupSaveAs(blob, name, opts, popup);
        }, 100)
    }
}

function saveTextAs(text, name, opts) {
    var blob = new Blob([text], { type: 'text/plain' });
    saveAs(blob, name, opts);
}


/***/ }),
/* 52 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3);
/* harmony import */ var _String_stringGenerate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(12);
/* harmony import */ var _Code_safeThrow__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(31);




/**
 *
 * @param {Worker} host
 */
function IFrameBridge(host, origin) {
    _HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].call(this);
    this.detach();
    this.origin = origin;
    if (host) this.attach(host);
    this.__azarResolveCallbacks = {};
    this.__azarRejectCallbacks = {};
}

IFrameBridge.prototype.attach = function (host) {
    this.host = host;
    if (this.host.addEventListener) {
        this.host.addEventListener("message", this.__azarMessageListener.bind(this), false);
    }
    else if (this.host.attachEvent) {
        this.host.attachEvent("onmessage", this.__azarMessageListener.bind(this));
    }
    else {
        this.host.onmessage = this.__azarMessageListener.bind(this);
    }
    this.__IFrameBridge_resolve();
};

IFrameBridge.prototype.detach = function () {
    this.sync = new Promise(function (resolve) {
        this.__IFrameBridge_resolve = resolve;
    }.bind(this));
};


IFrameBridge.fromIFrame = function (iframe) {
    var host = iframe.contentWindow || iframe.contentDocument;
    var src = iframe.src;
    var rootOrigin = location.origin;
    var iframeOrigin = src.match(/^(http|https):\/\/[^/]+/);
    if (iframeOrigin) {
        iframeOrigin = iframeOrigin[0];
    }
    else {
        iframeOrigin = rootOrigin;
    }

    if (host) return new IFrameBridge(host, iframeOrigin);
    else {
        var result = new IFrameBridge(undefined, iframeOrigin);
        var attachedHost = function () {
            var host = iframe.contentWindow || iframe.contentDocument;
            result.attach(host);
        };
        if (iframe.addEventListener) {
            iframe.addEventListener("load", attachedHost);
        }

        else {
            iframe.attachEvent("onload", attachedHost);
        }
        return result;
    }
};

IFrameBridge.getInstance = function () {
    if (!IFrameBridge.shareInstance) {
        var origin = location.origin;
        var rootOrigin = IFrameBridge.getParentUrl().match(/^(http|https):\/\/[^/]+/);
        if (rootOrigin) {
            rootOrigin = rootOrigin[0];
        }
        else {
            rootOrigin = origin;
        }

        // IFrameBridge.shareInstance = new IFrameBridge(self, rootOrigin == origin? undefined: "*" || rootOrigin );
        IFrameBridge.shareInstance = new IFrameBridge(self, rootOrigin);
    }
    return IFrameBridge.shareInstance;
};


Object.defineProperties(IFrameBridge.prototype, Object.getOwnPropertyDescriptors(_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].prototype));
IFrameBridge.prototype.constructor = IFrameBridge;

IFrameBridge.isInIFrame = function () {
    return (top !== self);
};


IFrameBridge.getParentUrl = function () {
    var parentUrl = (window.location != window.parent.location)
        ? document.referrer
        : document.location.href;
    return parentUrl;
};

IFrameBridge.prototype.__azarMessageListener = function (event) {
    this.__azarHandleData(event.data);
};


IFrameBridge.prototype.__azarHandleData = function (data) {
    if (data.type) {
        if (data.type == "INVOKE") {
            try {
                var result = this.__azarSelfInvoke(data.name, data.params);
                if (result && typeof result.then == 'function') {
                    result.then(function (result) {
                        this.__azarResolve(data.taskId, result);
                    }.bind(this))
                        .catch(function (err) {
                           Object(_Code_safeThrow__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"])(err);
                            this.__azarResolve(data.taskId, null, err);
                        }.bind(this));
                }
                else {
                    this.__azarResolve(data.taskId, result);
                }
            } catch (err) {
                Object(_Code_safeThrow__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"])(err);
                this.__azarResolve(data.taskId, null, err);
            }
        }
        else if (data.type == "INVOKE_RESULT") {
            if (this.__azarResolveCallbacks[data.taskId]) {
                if (data.error) {
                    this.__azarRejectCallbacks[data.taskId](data.error);
                }
                else {
                    this.__azarResolveCallbacks[data.taskId](data.result);
                }
                delete this.__azarResolveCallbacks[data.taskId];
                delete this.__azarRejectCallbacks[data.taskId];
            }
        }
        else if (data.type == "EMIT") {
            this.fire.apply(this, data.params);
        }
        else this.fire('message', data, this);
    }
};


IFrameBridge.prototype.__azarResolve = function (taskId, result, error) {
    var data = {
        type: "INVOKE_RESULT",
        taskId: taskId,
        result: result,
        error: error
    };

    if (this.origin) {
        this.host.postMessage(data, this.origin);
    }
    else {
        this.host.postMessage(data);
    }
};


IFrameBridge.prototype.__azarSelfInvoke = function (name, params) {
    if (typeof this[name] == 'function') {
        return this[name].apply(this, params);
    }
    else {
        return this[name];
    }
};


IFrameBridge.prototype.emit = function () {
    var params = [];
    params.push.apply(params, arguments);
    this.sync.then(function () {
        var data = {
            type: "EMIT",
            params: params
        };
        if (this.origin) {
            this.host.postMessage(data, this.origin);
        }
        else {
            this.host.postMessage(data);
        }
    }.bind(this));
    return this;
};


IFrameBridge.prototype.invoke = function (name) {
    var params = [];
    params.push.apply(params, arguments);
    params.shift();
    return this.sync.then(function () {
        var indent = Object(_String_stringGenerate__WEBPACK_IMPORTED_MODULE_1__["randomIdent"])(32);
        var data = {
            type: 'INVOKE',
            params: params,
            taskId: indent,
            name: name
        };
        if (this.origin) {
            this.host.postMessage(data, this.origin);
        }
        else {
            this.host.postMessage(data);
        }
        return new Promise(function (resolve, reject) {
            this.__azarResolveCallbacks[indent] = resolve;
            this.__azarRejectCallbacks[indent] = reject;
        }.bind(this));
    }.bind(this));
};

IFrameBridge.prototype.importScriptURLs = function () {
    return this.invoke.apply(this, ['_receiveScriptURLs'].concat(Array.prototype.slice.call(arguments)));
};

IFrameBridge.prototype.importScript = function (code) {
    var blob = new Blob([code], { type: 'application/javascript' });
    var url = URL.createObjectURL(blob);
    return this.importScriptURLs(url);
};


IFrameBridge.prototype.createMethod = function (name, fx) {
    this[name] = function () {
        return this.invoke.apply(this, [name].concat(Array.prototype.slice.call(arguments)));
    };
    return this.invoke.apply(this, ['_receiveMethod', name, fx.toString()]);
};


IFrameBridge.prototype._receiveScriptURLs = function () {
    if (self.importScripts) {
        self.importScripts.apply(self, arguments);
    }
};


IFrameBridge.prototype._receiveMethod = function (name, code) {
    this[name] = (new Function('return ' + code))();
};

/* harmony default export */ __webpack_exports__["a"] = (IFrameBridge);

/***/ }),
/* 53 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return VScroller; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return HScroller; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return Scrollbar; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return VScrollbar; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return HScrollbar; });
/* harmony import */ var _css_scroller_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(130);
/* harmony import */ var _css_scroller_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_scroller_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1);
/* harmony import */ var absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2);
/* harmony import */ var absol_src_HTML5_Element__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(24);
/* harmony import */ var absol_src_Math_int__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(14);







var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$scrollStyle = (function () {
        var element = _('style#vscroller-style');
        element.innerHTML = [
            '.absol-vscroller-viewport{ margin-right: ' + (-17) + 'px;  min-width: calc(100% + ' + (17) + 'px);}',
            '.absol-hscroller-viewport{ margin-bottom: ' + (-17) + 'px;  min-height: calc(100% + ' + (17) + 'px);}'
        ].join('\n');
        document.head.appendChild(element);

        absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__[/* default */ "b"].getScrollSize().then(function (size) {
            element.innerHTML = [
                '.absol-vscroller-viewport{ margin-right: ' + (-size.width) + 'px; min-width: calc(100% + ' + (size.width) + 'px);}',
                '.absol-hscroller-viewport{ margin-bottom: ' + (-size.height) + 'px; min-height: calc(100% + ' + (size.height) + 'px);}'
            ].join('\n');
        });
        return element;
    }
)();

function VScroller() {
    var thisVS = this;
    this.$attachHook = $('attachhook', this);
    this.sync = new Promise(function (rs) {
        thisVS.$attachHook.once('error', function () {
            rs();
        });
    });

    this.$attachHook.on('error', function () {
        thisVS.requestUpdateSize();
    });
    this.$vscrollbar = $('vscrollbar', this).on('scroll', this.eventHandler.scrollScrollbar);
    this.$viewport = $('.absol-vscroller-viewport', this)
        .on('scroll', this.eventHandler.scrollViewport);
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].extends(thisVS.$viewport, {
        removeChild: function () {
            this.super.apply(this, arguments);
            thisVS.requestUpdateSize();
            return thisVS;
        }
    })
}

VScroller.tag = 'vscroller';
VScroller.render = function () {
    return _({
        class: 'absol-vscroller',
        child: ['.absol-vscroller-viewport',
            {
                class: ['absol-scrollbar-container', 'vertical'],
                child: 'vscrollbar'
            },
            'attachhook'
        ]
    });
};


VScroller.prototype.requestUpdateSize = function () {
    // return;
    if (this._isRequestingUpdateSize) return this.sync;
    this._isRequestingUpdateSize = true;
    this.sync = this.sync.then(function () {
        this.$vscrollbar.outerHeight = this.$viewport.clientHeight;
        this.$vscrollbar.innerHeight = this.$viewport.scrollHeight - 2;
        this.$vscrollbar.innerOffset = this.$viewport.scrollTop;
        if (this.$vscrollbar.innerHeight <= this.$vscrollbar.outerHeight) {
            this.$vscrollbar.hidden = true;
            this.addClass('disabled');
        }
        else {
            this.removeClass('disabled');
            this.$vscrollbar.hidden = false;
        }
        this._isRequestingUpdateSize = false;
    }.bind(this));
    return this.sync;
};

VScroller.prototype.init = function (props) {
    this.super(props);
    this.requestUpdateSize();
};

VScroller.prototype.addChild = function () {
    var res = this.$viewport.addChild.apply(this.$viewport, arguments);
    this.requestUpdateSize();
    return res;
};

VScroller.prototype.clearChild = function () {
    var res = this.$viewport.clearChild.apply(this.$viewport, arguments);
    this.requestUpdateSize();
    return res;

};

VScroller.prototype.addChildBefore = function () {
    var res = this.$viewport.addChildBefore.apply(this.$viewport, arguments);
    this.requestUpdateSize();
    return res;
};

VScroller.prototype.addChildAfter = function () {
    var res = this.$viewport.addChildAfter.apply(this.$viewport, arguments);
    this.requestUpdateSize();
    return res;
};

VScroller.prototype.findChildAfter = function () {
    return this.$viewport.findChildAfter.apply(this.$viewport, arguments);
};

VScroller.prototype.findChildBefore = function () {
    return this.$viewport.findChildBefore.apply(this.$viewport, arguments);
};

VScroller.prototype.removeChild = function () {
    var res = this.$viewport.removeChild.apply(this.$viewport, arguments);
    this.requestUpdateSize();
    return res;
};

VScroller.prototype.scrollInto = function (element, padding, scrollTime, beforFrame, afterFrame) {
    padding = padding || 0;
    scrollTime = scrollTime || 0;
    var frameCount = Math.ceil(scrollTime / 15 + 1);
    var self = this;

    function onFrame() {
        beforFrame && beforFrame();
        var elementBound = element.getBoundingClientRect();
        var viewportBound = self.$viewport.getBoundingClientRect();
        var currentScrollTop = self.$viewport.scrollTop;
        var newScrollTop = currentScrollTop;
        if (elementBound.bottom + padding > viewportBound.bottom) {
            newScrollTop = currentScrollTop + ((elementBound.bottom + padding) - viewportBound.bottom) / (Math.log(frameCount) + 1);
        }
        if (elementBound.top - padding < viewportBound.top) {
            newScrollTop = currentScrollTop - (viewportBound.top - (elementBound.top - padding)) / (Math.log(frameCount) + 1);
        }

        if (newScrollTop != currentScrollTop) {
            self.$viewport.scrollTop = newScrollTop;
        }
        afterFrame && afterFrame();
        frameCount--;
        if (frameCount > 0) setTimeout(onFrame, 15)
    }

    if (absol_src_HTML5_Element__WEBPACK_IMPORTED_MODULE_4__[/* default */ "a"].prototype.isDescendantOf.call(element, this.$viewport)) {
        onFrame();
    }
};


VScroller.prototype.scrollBy = function (dy, duration) {
    duration = duration || 0;
    var frameCount = Math.ceil(duration / 20);
    var timeOut = duration / frameCount;
    var i = 0;
    var self = this;
    var start = self.$viewport.scrollTop;
    var end = start + dy;

    function onFrame() {
        self.$viewport.scrollTop = Math.max(Object(absol_src_Math_int__WEBPACK_IMPORTED_MODULE_5__["map"])(i, 0, frameCount, start, end), 0);
        ++i;
        if (i <= frameCount)
            setTimeout(onFrame, timeOut);
    }

    onFrame();
};


VScroller.eventHandler = {};

VScroller.eventHandler.scrollViewport = function (event) {
    this.$vscrollbar.outerHeight = this.$viewport.clientHeight;
    this.$vscrollbar.innerHeight = this.$viewport.scrollHeight;
    this.$vscrollbar.innerOffset = this.$viewport.scrollTop;
};

VScroller.eventHandler.scrollScrollbar = function (event) {
    this.$viewport.scrollTop = this.$vscrollbar.innerOffset;
};


function HScroller() {
    var thisHS = this;
    this.$attachHook = $('attachhook', this)
        .on('error', function () {
            this.requestUpdateSize = this.requestUpdateSize || thisHS.requestUpdateSize.bind(thisHS);
            absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_2__[/* default */ "b"].addToResizeSystem(this);
        });

    this.sync = new Promise(function (rs, rj) {
        thisHS.$attachHook.once('error', rs);
    });
    this.$hscrollbar = $('hscrollbar', this).on('scroll', this.eventHandler.scrollScrollbar);
    this.$viewport = $('.absol-hscroller-viewport', this)
        .on('scroll', this.eventHandler.scrollViewport);
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].extends(this.$viewport, {
        removeChild: function () {
            this.super.apply(this, arguments);
            thisHS.requestUpdateSize();
            return thisHS;
        }
    });
}


HScroller.tag = 'hscroller';

HScroller.render = function () {
    return _({
        class: 'absol-hscroller',
        child: ['.absol-hscroller-viewport',
            {
                class: ['absol-scrollbar-container', 'horizontal'],
                child: 'hscrollbar'
            },
            'attachhook'
        ]
    });
};

HScroller.eventHandler = {};

HScroller.eventHandler.scrollViewport = function (event) {
    this.$hscrollbar.outerWidth = this.$viewport.clientWidth;
    this.$hscrollbar.innerWidth = this.$viewport.scrollWidth;
    this.$hscrollbar.innerOffset = this.$viewport.scrollLeft;
};

HScroller.eventHandler.scrollScrollbar = function (event) {
    this.$viewport.scrollLeft = this.$hscrollbar.innerOffset;
};


Object.assign(HScroller.prototype, VScroller.prototype);

HScroller.prototype.requestUpdateSize = function () {
    // return;
    if (this._isRequestingUpdateSize) return this.sync;
    this._isRequestingUpdateSize = true;
    this.sync = this.sync.then(function () {
        this.$hscrollbar.outerWidth = this.$viewport.clientWidth;
        this.$hscrollbar.innerWidth = this.$viewport.scrollWidth;
        this.$hscrollbar.innerOffset = this.$viewport.scrollLeft;
        if (this.$hscrollbar.innerWidth <= this.$hscrollbar.outerWidth) {
            this.$hscrollbar.hidden = true;
            this.addClass('disabled');
        }
        else {
            this.removeClass('disabled');
            this.$hscrollbar.hidden = false;
        }
        this._isRequestingUpdateSize = false;
    }.bind(this));
    return this.sync;
};

HScroller.prototype.scrollInto = function (element) {
    if (absol_src_HTML5_Element__WEBPACK_IMPORTED_MODULE_4__[/* default */ "a"].prototype.isDescendantOf.call(element, this.$viewport)) {
        var elementBound = element.getBoundingClientRect();
        var viewportBound = this.$viewport.getBoundingClientRect();
        var currentScrollLeft = this.$viewport.scrollLeft;
        var newScrollLeft = currentScrollLeft;
        if (elementBound.right > viewportBound.right) {
            newScrollLeft = currentScrollLeft + (elementBound.right - viewportBound.right);
        }
        if (elementBound.left < viewportBound.left) {
            newScrollLeft = currentScrollLeft - (viewportBound.left - elementBound.left);
        }

        if (newScrollLeft != currentScrollLeft) {
            this.$viewport.scrollLeft = newScrollLeft;
        }
    }
}


function Scrollbar() {
    var thisSB = this;
    this.$button = $('.absol-scrollbar-button', this);
    this.on('active', function () {
        if (!thisSB.$forceModal) thisSB.$forceModal = _('.absol-scrollbar-force-modal');
        thisSB.$forceModal.addTo(document.body);
    }).on('deactive', function () {
        setTimeout(function () {
            thisSB.$forceModal.remove();
        }, 30);
    });
}

Scrollbar.tag = 'scrollbar';

Scrollbar.render = function () {
    return _({
        class: ['absol-scrollbar'],
        extendEvent: ['scroll', 'active', 'deactive'],
        child: '.absol-scrollbar-button'
    });
};

Scrollbar.property = {};
Scrollbar.property.hidden = {
    set: function (value) {
        value = !!value;
        if (value != this._hidden) {
            this._hidden = value;
            if (value)
                this.addClass('absol-hidden');
            else
                this.removeClass('absol-hidden');
        }
    },
    get: function () {
        return this.containsClass('absol-hidden')
    }
};


function VScrollbar() {
    var thisVS = this;
    var top0, innerOffset0;
    var pointerMoveEventHandler = function (event) {
        event.preventDefault();
        var dy = event.clientY - top0;
        var newInnerOffset = innerOffset0 + dy * (thisVS.innerHeight / thisVS.outerHeight) * (thisVS.outerHeight / thisVS.getBoundingClientRect().height);
        if (newInnerOffset + thisVS.outerHeight > thisVS.innerHeight)
            newInnerOffset = thisVS.innerHeight - thisVS.outerHeight;
        if (newInnerOffset < 0) newInnerOffset = 0;
        thisVS.innerOffset = newInnerOffset;
        //todo
        event.innerOffset = newInnerOffset;
        thisVS.emit('scroll', event);
    };

    var finishEventHandler = function (event) {
        var body = $(document.body);
        body.off('pointerleave', finishEventHandler);
        body.off('pointerup', finishEventHandler);
        body.off('pointermove', pointerMoveEventHandler);
        thisVS.removeClass('absol-active');
        thisVS.emit('deactive', { type: 'deactive', originEvent: event, tagert: thisVS });
    };

    var pointerDownEventHandler = function (event) {
        var boundRes = thisVS.getBoundingClientRect();
        var boundButton = thisVS.$button.getBoundingClientRect();
        top0 = event.clientY;
        if (event.target == thisVS.$button) {
            innerOffset0 = thisVS.innerOffset;
        }
        else {
            var newInnerOffset = Object(absol_src_Math_int__WEBPACK_IMPORTED_MODULE_5__["map"])(top0 - boundButton.height / 2 - boundRes.top, 0, boundRes.height, 0, thisVS.innerHeight);
            if (newInnerOffset + thisVS.outerHeight > thisVS.innerHeight)
                newInnerOffset = thisVS.innerHeight - thisVS.outerHeight;
            if (newInnerOffset < 0) newInnerOffset = 0;
            thisVS.innerOffset = newInnerOffset;
            //todo
            event.innerOffset = newInnerOffset;
            innerOffset0 = newInnerOffset;
            thisVS.emit('scroll', event);
        }
        var body = $(document.body);
        body.on('pointerleave', finishEventHandler);
        body.on('pointerup', finishEventHandler);
        body.on('pointermove', pointerMoveEventHandler);
        thisVS.addClass('absol-active');
        thisVS.emit('active', { type: 'active', originEvent: event, tagert: thisVS });
    };

    this.on('pointerdown', pointerDownEventHandler, true);
}

VScrollbar.tag = 'vscrollbar';
VScrollbar.render = function () {
    return _({
        tag: 'scrollbar',
        class: 'absol-vscrollbar'
    }, true);
};


VScrollbar.prototype.updateValue = function () {
    this.$button.addStyle('height', Math.min(this.outerHeight / this.innerHeight, 1) * 100 + '%');
    this.$button.addStyle('top', this.innerOffset / this.innerHeight * 100 + '%');
};


VScrollbar.property = {
    innerOffset: {
        set: function (value) {
            value = value || 0;
            if (this._innerOffset != value) {
                this._innerOffset = value;
                this.updateValue();
            }
        },
        get: function () {
            return this._innerOffset || 0;
        }
    },

    innerHeight: {
        set: function (value) {
            value = value || 1;
            value = Math.max(value, 1);
            if (this._innerHeight != value) {
                this._innerHeight = value;
                this.updateValue();
            }
        },
        get: function () {
            return this._innerHeight || 1;
        }
    },
    outerHeight: {
        set: function (value) {
            value = value || 0;
            value = Math.max(value, 0);
            if (this._outerHeight != value) {
                this._outerHeight = value;
                this.updateValue();
            }
        },
        get: function () {
            return this._outerHeight || 0;
        }
    }
};


function HScrollbar() {
    var thisHS = this;

    var left0, innerOffset0;
    var pointerMoveEventHandler = function (event) {
        event.preventDefault();
        var dy = event.clientX - left0;
        var newInnerOffset = innerOffset0 + dy * (thisHS.innerWidth / thisHS.outerWidth) * (thisHS.outerWidth / thisHS.getBoundingClientRect().width);
        if (newInnerOffset + thisHS.outerWidth > thisHS.innerWidth)
            newInnerOffset = thisHS.innerWidth - thisHS.outerWidth;
        if (newInnerOffset < 0) newInnerOffset = 0;
        thisHS.innerOffset = newInnerOffset;
        //todo
        event.innerOffset = newInnerOffset;
        thisHS.emit('scroll', event);
    };

    var finishEventHandler = function (event) {
        var body = $(document.body);
        body.off('pointerleave', finishEventHandler);
        body.off('pointerup', finishEventHandler);
        body.off('pointermove', pointerMoveEventHandler);
        thisHS.removeClass('absol-active');
        thisHS.emit('deactive', { type: 'deactive', originEvent: event, tagert: thisHS });
    };

    var pointerDownEventHandler = function (event) {
        var boundRes = thisHS.getBoundingClientRect();
        var boundButton = thisHS.$button.getBoundingClientRect();
        left0 = event.clientX;
        if (event.target == thisHS.$button) {
            innerOffset0 = thisHS.innerOffset;
        }
        else {
            var newInnerOffset = Object(absol_src_Math_int__WEBPACK_IMPORTED_MODULE_5__["map"])(left0 - boundButton.width / 2 - boundRes.left, 0, boundRes.width, 0, thisHS.innerWidth);
            if (newInnerOffset + thisHS.outerWidth > thisHS.innerWidth)
                newInnerOffset = thisHS.innerWidth - thisHS.outerWidth;
            if (newInnerOffset < 0) newInnerOffset = 0;
            thisHS.innerOffset = newInnerOffset;
            //todo
            event.innerOffset = newInnerOffset;
            innerOffset0 = newInnerOffset;
            thisHS.emit('scroll', event);
        }
        var body = $(document.body);
        body.on('pointerleave', finishEventHandler);
        body.on('pointerup', finishEventHandler);
        body.on('pointermove', pointerMoveEventHandler);
        thisHS.addClass('absol-active');
        thisHS.emit('active', { type: 'deactive', originEvent: event, tagert: thisHS });
    };

    this.on('pointerdown', pointerDownEventHandler, true);
}

HScrollbar.tag = 'hscrollbar';

HScrollbar.render = function () {
    return _({
        tag: 'scrollbar',
        class: 'absol-hscrollbar'
    }, true);
}

HScrollbar.prototype.updateValue = function () {
    this.$button.addStyle('width', Math.min(this.outerWidth / this.innerWidth, 1) * 100 + '%');
    this.$button.addStyle('left', this.innerOffset / this.innerWidth * 100 + '%');
};


HScrollbar.property = {
    innerOffset: {
        set: function (value) {
            value = value || 0;
            if (this._innerOffset != value) {
                this._innerOffset = value;
                this.updateValue();
            }
        },
        get: function () {
            return this._innerOffset || 0;
        }
    },

    innerWidth: {
        set: function (value) {
            value = value || 1;
            value = Math.max(value, 1);
            if (this._innerWidth != value) {
                this._innerWidth = value;
                this.updateValue();
            }
        },
        get: function () {
            return this._innerWidth || 1;
        }
    },
    outerWidth: {
        set: function (value) {
            value = value || 0;
            value = Math.max(value, 0);
            if (this._outerWidth != value) {
                this._outerWidth = value;
                this.updateValue();
            }
        },
        get: function () {
            return this._outerWidth || 0;
        }
    }
};

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install([VScrollbar, HScrollbar, Scrollbar, VScroller, HScroller]);

/***/ }),
/* 54 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_variantcolors_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(262);
/* harmony import */ var _css_variantcolors_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_variantcolors_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1);



function VariantColor() {
    this.keys = ['primary', 'secondary',
        'success', 'info',
        'warning', 'error', 'danger',
        'light', 'dark',
        'link',
        'note'];
    this.base = {
        primary: "#007bff",
        secondary: "#6c757d",
        success: "#28a745",
         info: "#17a2b8",
        warning: "#ffc107",
        error: "#ff4052",
        danger: "#dc3545",
        light: "#f8f9fa",
        dark: "#343a40",
        link: "#007bff",
        note: '#ffff88'
    };
    this.mediumContract = {
        primary: '#e2edd5',
        secondary: '#fca75b',
        success: '#fce8e8',
        info: '#fcf5e8',
        warning: '#5e5a75',
        error: '#e0dfce',
        danger: "#e5e8d5",
        light: '#7a5b3c',
        dark: "#bf7d3b",
        link: "#dde8c9",
        note: '#1e1ec8'
    }
    absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_1__[/* default */ "b"].documentReady.then(this.loadFromCss.bind(this));
}

VariantColor.prototype.has = function (name) {
    return this.keys.indexOf(name) >= 0;
};

VariantColor.prototype.loadFromCss = function () {
    this.base = this.keys.reduce(function (ac, name) {
        var style = window.getComputedStyle(document.body);
        ac[name] = style.getPropertyValue('--variant-color-' + name);
        return ac;
    }, {});
    this.mediumContract = this.keys.reduce(function (ac, name) {
        var style = window.getComputedStyle(document.body);
        ac[name] = style.getPropertyValue('--variant-medium-contract-color-' + name);
        return ac;
    }, {});
};

/* harmony default export */ __webpack_exports__["a"] = (new VariantColor());

/***/ }),
/* 55 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_onscreenwindow_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(181);
/* harmony import */ var _css_onscreenwindow_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_onscreenwindow_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2);
/* harmony import */ var absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(3);
/* harmony import */ var _Draggable__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(49);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(1);







var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;

/***
 * @extends AElement
 * @constructor
 */
function OnScreenWindow() {
    var res = this;
    this._lastSize = {
        width: 0,
        height: 0
    }
    res.$headerbar = $('.absol-onscreen-window-head-bar', res)
        .on('dragstart', res.eventHandler.beginDragHeaderbar);

    res.$bottomResizer = $('.absol-onscreen-window-resizer.absol-onscreen-window-resize-bottom', res)
        .on('dragstart', res.eventHandler.beginDragBottom);

    res.$rightResizer = $('.absol-onscreen-window-resizer.absol-onscreen-window-resize-right', res)
        .on('dragstart', res.eventHandler.beginDragRight);

    res.$topResizer = $('.absol-onscreen-window-resizer.absol-onscreen-window-resize-top', res)
        .on('dragstart', res.eventHandler.beginDragTop);

    res.$leftResizer = $('.absol-onscreen-window-resizer.absol-onscreen-window-resize-left', res)
        .on('dragstart', res.eventHandler.beginDragLeft);

    res.$bottomRightResizer = $('.absol-onscreen-window-resizer.absol-onscreen-window-resize-bottom-right', res)
        .on('dragstart', res.eventHandler.beginDragButtonRight);

    res.$bottomLeftResizer = $('.absol-onscreen-window-resizer.absol-onscreen-window-resize-bottom-left', res)
        .on('dragstart', res.eventHandler.beginDragBottomLeft);

    res.$topLeftResizer = $('.absol-onscreen-window-resizer.absol-onscreen-window-resize-top-left', res)
        .on('dragstart', res.eventHandler.beginDragTopLeft);

    res.$topRightResizer = $('.absol-onscreen-window-resizer.absol-onscreen-window-resize-top-right', res)
        .on('dragstart', res.eventHandler.beginDragTopRight);


    res.$headerButtonCtn = $('.absol-onscreen-window-head-bar-buttons', res.$headerbar);
    res.$windowIcon = $('span.absol-onscreen-window-head-bar-icon.mdi.mdi-settings', res);
    res.$windowTitle = $('.absol-onscreen-window-head-bar-title', res);
    res._windowIcon = 'span.absol-onscreen-window-head-bar-icon.mdi.mdi-settings';
    res._windowTitle = '';
    res.$bodyContainer = $('.absol-onscreen-window-body-container', res);
    res.$attachhook = _('attachhook').addTo(res)
        .on('error', function () {
            this.updateSize = this.updateSize || res.relocation.bind(res);
            absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_5__[/* default */ "b"].addToResizeSystem(this);
        });

    res.$minimizeBtn = $('button.absol-onscreen-window-head-bar-button-minimize', res);
    res.$closeBtn = $('button.absol-onscreen-window-head-bar-button-close', res);
    res.$dockBtn = $('button.absol-onscreen-window-head-bar-button-dock', res);
}

OnScreenWindow.tag = 'OnScreenWindow'.toLowerCase();

OnScreenWindow.render = function () {
    return _({
        extendEvent: ['sizechange', 'drag', 'relocation'],
        class: 'absol-onscreen-window',
        child: {
            class: 'absol-onscreen-window-content',
            child: [
                {
                    tag: 'hanger',
                    class: 'absol-onscreen-window-head-bar',
                    child: [
                        'span.absol-onscreen-window-head-bar-icon.mdi.mdi-settings',
                        {
                            tag: 'span',
                            class: 'absol-onscreen-window-head-bar-title',
                            child: { text: '' }
                        },
                        {
                            class: "absol-onscreen-window-head-bar-buttons",
                            child: [
                                {
                                    tag: 'button',
                                    class: 'absol-onscreen-window-head-bar-button-minimize',
                                    child: 'span.mdi.mdi-window-minimize'
                                },
                                {
                                    tag: 'button',
                                    class: 'absol-onscreen-window-head-bar-button-dock',
                                    child: 'span.mdi.mdi-dock-window'
                                },
                                {
                                    tag: 'button',
                                    class: 'absol-onscreen-window-head-bar-button-close',
                                    child: 'span.mdi.mdi-close'
                                }
                            ]
                        }
                    ]
                },
                {
                    class: 'absol-onscreen-window-body-container'
                },
                'hanger.absol-onscreen-window-resizer.absol-onscreen-window-resize-bottom',
                'hanger.absol-onscreen-window-resizer.absol-onscreen-window-resize-top',
                'hanger.absol-onscreen-window-resizer.absol-onscreen-window-resize-left',
                'hanger.absol-onscreen-window-resizer.absol-onscreen-window-resize-right',
                'hanger.absol-onscreen-window-resizer.absol-onscreen-window-resize-bottom-right',
                'hanger.absol-onscreen-window-resizer.absol-onscreen-window-resize-bottom-left',
                'hanger.absol-onscreen-window-resizer.absol-onscreen-window-resize-top-left',
                'hanger.absol-onscreen-window-resizer.absol-onscreen-window-resize-top-right'

            ]
        }
    });
};

OnScreenWindow.prototype.maybeSizeChange = function () {
    var bound = this.getBoundingClientRect();
    if (this._lastSize.width !== bound.width || this._lastSize.height !== bound.height) {
        this._lastSize = bound;
        window.dispatchEvent(new Event('resize'));
        this.emit('sizechange', {size: bound, target: this, type: 'sizechange'}, this);
    }
};

OnScreenWindow.eventHandler = {};

OnScreenWindow.eventHandler.beginDragHeaderbar = function (event) {
    if (!absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_3__[/* default */ "b"].hitElement(this.$headerButtonCtn, event)) {
        this.$headerbar.on('drag', this.eventHandler.dragHeaderbar);
        this.$headerbar.on('dragend', this.eventHandler.endDragHeaderbar);
        var screenSize = absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_5__[/* default */ "b"].getScreenSize();
        var bound = this.getBoundingClientRect();
        this.__moveData__ = {
            bound: bound,
            modal: _('.absol-onscreen-window-moving-modal').addTo(document.body),
            maxLeft: screenSize.width - bound.width - 1,
            maxY: screenSize.height - bound.height - 1,
        };
    }
};

OnScreenWindow.eventHandler.dragHeaderbar = function (event) {
    var d = event.currentPoint.sub(event.startingPoint);
    var dx = d.x;
    var dy = d.y;
    var newX = Math.max(0, Math.min(this.__moveData__.maxLeft, this.__moveData__.bound.left + dx));
    var newY = Math.max(0, Math.min(this.__moveData__.maxY, this.__moveData__.bound.top + dy));
    this.addStyle({
        top: newY + 'px',
        left: newX + 'px'
    });
    this.emit('drag', event, this);
};

OnScreenWindow.eventHandler.endDragHeaderbar = function (event) {
    this.$headerbar.off('drag', this.eventHandler.dragHeaderbar);
    this.$headerbar.off('dragend', this.eventHandler.endDragHeaderbar);
    this.__moveData__.modal.remove();
    this.__moveData__ = undefined;
    this.emit('relocation', { type: 'relocation', target: this }, this);
};


OnScreenWindow.eventHandler.beginDragBottom = function (event) {
    if (event.target != this.$bottomResizer) return;
    this.$bottomResizer.on('drag', this.eventHandler.dragBottom);
    this.$bottomResizer.on('dragend', this.eventHandler.endDragBottom);
    var screenSize = absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_5__[/* default */ "b"].getScreenSize();
    var bound = this.getBoundingClientRect();
    this.__moveData__ = {
        bound: bound,
        minHeight: this.getFontSize() * 1.4,
        maxHeight: screenSize.height - bound.top,
        modal: _('.absol-onscreen-window-moving-modal.absol-onscreen-window-resize-bottom').addTo(document.body)
    };
};

OnScreenWindow.eventHandler.dragBottom = function (event) {
    var d = event.currentPoint.sub(event.startingPoint);
    var dy = d.y;
    var newHeight = Math.max(this.__moveData__.minHeight, Math.min(this.__moveData__.maxHeight, this.__moveData__.bound.height + dy));
    this.addStyle('height', newHeight + 'px');
    this.maybeSizeChange();
};


OnScreenWindow.eventHandler.endDragBottom = function (event) {
    this.$bottomResizer.off('drag', this.eventHandler.dragBottom);
    this.$bottomResizer.off('dragend', this.eventHandler.endDragBottom);
    this.__moveData__.modal.remove();
    this.__moveData__ = undefined;
};


OnScreenWindow.eventHandler.beginDragRight = function (event) {
    if (event.target != this.$rightResizer) return;
    this.$rightResizer.on('drag', this.eventHandler.dragRight);
    this.$rightResizer.on('dragend', this.eventHandler.endDragRight);
    var screenSize = absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_5__[/* default */ "b"].getScreenSize();
    var bound = this.getBoundingClientRect();
    var minWidth = this.$windowTitle.getBoundingClientRect().right - bound.left + this.$headerButtonCtn.getBoundingClientRect().width;
    this.__moveData__ = {
        minWidth: minWidth,
        bound: bound,
        maxWidth: screenSize.width - bound.left,
        modal: _('.absol-onscreen-window-moving-modal.absol-onscreen-window-resize-right').addTo(document.body)
    };
};

OnScreenWindow.eventHandler.dragRight = function (event) {
    var d = event.currentPoint.sub(event.startingPoint);
    var dx = d.x;
    var newWidth = Math.max(this.__moveData__.minWidth, Math.min(this.__moveData__.maxWidth, this.__moveData__.bound.width + dx));
    this.addStyle('width', newWidth + 'px');
    this.maybeSizeChange();
};


OnScreenWindow.eventHandler.endDragRight = function (event) {
    this.$rightResizer.off('drag', this.eventHandler.dragRight);
    this.$rightResizer.off('dragend', this.eventHandler.endDragRight);
    this.__moveData__.modal.remove();
    this.__moveData__ = undefined;
};


OnScreenWindow.eventHandler.beginDragTop = function (event) {
    if (event.target != this.$topResizer) return;
    this.$topResizer.on('drag', this.eventHandler.dragTop);
    this.$topResizer.on('dragend', this.eventHandler.endDragTop);
    // var screenSize = Dom.getScreenSize();
    var bound = this.getBoundingClientRect();
    var fontSize = this.getFontSize();
    this.__moveData__ = {
        fontSize: fontSize,
        bound: bound,
        maxTop: bound.bottom - 1.4 * fontSize,
        modal: _('.absol-onscreen-window-moving-modal.absol-onscreen-window-resize-top').addTo(document.body)
    };
};

OnScreenWindow.eventHandler.dragTop = function (event) {
    var d = event.currentPoint.sub(event.startingPoint);
    var dy = d.y;
    var newTop = Math.max(0, Math.min(this.__moveData__.maxTop, this.__moveData__.bound.top + dy));
    var newHeight = this.__moveData__.bound.bottom - newTop;
    this.addStyle({
        'top': newTop + 'px',
        'height': newHeight + 'px',
    });
    this.emit('relocation', { type: 'relocation', target: this }, this);
    this.maybeSizeChange();
};


OnScreenWindow.eventHandler.endDragTop = function (event) {
    this.$topResizer.off('drag', this.eventHandler.dragTop);
    this.$topResizer.off('dragend', this.eventHandler.endDragTop);
    this.__moveData__.modal.remove();
    this.__moveData__ = undefined;

};


OnScreenWindow.eventHandler.beginDragLeft = function (event) {
    if (event.target != this.$leftResizer) return;
    this.$leftResizer.on('drag', this.eventHandler.dragLeft);
    this.$leftResizer.on('dragend', this.eventHandler.endDragLeft);
    var bound = this.getBoundingClientRect();
    var minWidth = this.$windowTitle.getBoundingClientRect().right - bound.left + this.$headerButtonCtn.getBoundingClientRect().width;
    this.__moveData__ = {
        maxLeft: bound.right - minWidth,
        bound: bound,
        modal: _('.absol-onscreen-window-moving-modal.absol-onscreen-window-resize-left').addTo(document.body)
    };
};

OnScreenWindow.eventHandler.dragLeft = function (event) {
    var d = event.currentPoint.sub(event.startingPoint);
    var dx = d.x;
    var newLeft = Math.max(0, Math.min(this.__moveData__.maxLeft, this.__moveData__.bound.left + dx));
    var newWidth = this.__moveData__.bound.right - newLeft;
    this.addStyle({
        width: newWidth + 'px',
        left: newLeft + 'px'
    });
    this.emit('relocation', { type: 'relocation', target: this }, this);
    this.maybeSizeChange();
};


OnScreenWindow.eventHandler.endDragLeft = function (event) {
    this.$leftResizer.off('drag', this.eventHandler.dragLeft);
    this.$leftResizer.off('dragend', this.eventHandler.endDragLeft);
    this.__moveData__.modal.remove();
    this.__moveData__ = undefined;
};


//todo
OnScreenWindow.eventHandler.beginDragButtonRight = function (event) {
    if (event.target != this.$bottomRightResizer) return;
    this.$bottomRightResizer.on('drag', this.eventHandler.dragButtonRight);
    this.$bottomRightResizer.on('dragend', this.eventHandler.endDragButtonRight);
    var screenSize = absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_5__[/* default */ "b"].getScreenSize();
    var bound = this.getBoundingClientRect();
    var minWidth = this.$windowTitle.getBoundingClientRect().right - bound.left + this.$headerButtonCtn.getBoundingClientRect().width;
    this.__moveData__ = {
        minHeight: this.getFontSize() * 1.4,
        minWidth: minWidth,
        bound: bound,
        maxWidth: screenSize.width - bound.left,
        maxHeight: screenSize.height - bound.top,
        modal: _('.absol-onscreen-window-moving-modal.absol-onscreen-window-resize-bottom-right').addTo(document.body)
    };
};

OnScreenWindow.eventHandler.dragButtonRight = function (event) {
    var d = event.currentPoint.sub(event.startingPoint);
    var dx = d.x;
    var dy = d.y;
    var newWidth = Math.max(this.__moveData__.minWidth, Math.min(this.__moveData__.maxWidth, this.__moveData__.bound.width + dx));
    var newHeight = Math.max(this.__moveData__.minHeight, Math.min(this.__moveData__.maxHeight, this.__moveData__.bound.height + dy));
    this.addStyle('width', newWidth + 'px');
    this.addStyle('height', newHeight + 'px');

    this.maybeSizeChange();
};


OnScreenWindow.eventHandler.endDragButtonRight = function (event) {
    this.$bottomRightResizer.off('drag', this.eventHandler.dragButtonRight);
    this.$bottomRightResizer.off('dragend', this.eventHandler.endDragButtonRight);
    this.__moveData__.modal.remove();
    this.__moveData__ = undefined;
};


OnScreenWindow.eventHandler.beginDragBottomLeft = function (event) {
    if (event.target != this.$bottomLeftResizer) return;
    this.$bottomLeftResizer.on('drag', this.eventHandler.dragBottomLeft);
    this.$bottomLeftResizer.on('dragend', this.eventHandler.endDragBottomLeft);
    var bound = this.getBoundingClientRect();
    var minWidth = this.$windowTitle.getBoundingClientRect().right - bound.left + this.$headerButtonCtn.getBoundingClientRect().width;
    var screenSize = absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_5__[/* default */ "b"].getScreenSize();
    this.__moveData__ = {
        maxLeft: bound.right - minWidth,
        bound: bound,
        minHeight: this.getFontSize() * 1.4,
        maxHeight: screenSize.height - bound.top,
        modal: _('.absol-onscreen-window-moving-modal.absol-onscreen-window-resize-bottom-left').addTo(document.body)
    };
};

OnScreenWindow.eventHandler.dragBottomLeft = function (event) {
    var d = event.currentPoint.sub(event.startingPoint);
    var dx = d.x;
    var dy = d.y;
    var newLeft = Math.max(0, Math.min(this.__moveData__.maxLeft, this.__moveData__.bound.left + dx));
    var newWidth = this.__moveData__.bound.right - newLeft;
    var newHeight = Math.max(this.__moveData__.minHeight, Math.min(this.__moveData__.maxHeight, this.__moveData__.bound.height + dy));
    this.addStyle('height', newHeight + 'px');
    this.addStyle({
        width: newWidth + 'px',
        left: newLeft + 'px'
    });
    this.emit('relocation', { type: 'relocation', target: this }, this);
};


OnScreenWindow.eventHandler.endDragBottomLeft = function (event) {
    this.$bottomLeftResizer.off('drag', this.eventHandler.dragLeft);
    this.$bottomLeftResizer.off('dragend', this.eventHandler.endDragLeft);
    this.__moveData__.modal.remove();
    this.__moveData__ = undefined;
};


OnScreenWindow.eventHandler.beginDragTopLeft = function (event) {
    if (event.target != this.$topLeftResizer) return;
    this.$topLeftResizer.on('drag', this.eventHandler.dragTopLeft);
    this.$topLeftResizer.on('dragend', this.eventHandler.endDragTopLeft);
    var bound = this.getBoundingClientRect();
    var fontSize = this.getFontSize();
    var minWidth = this.$windowTitle.getBoundingClientRect().right - bound.left + this.$headerButtonCtn.getBoundingClientRect().width;
    this.__moveData__ = {
        maxLeft: bound.right - minWidth,
        fontSize: fontSize,
        bound: bound,
        maxTop: bound.bottom - 1.4 * fontSize,
        modal: _('.absol-onscreen-window-moving-modal.absol-onscreen-window-resize-top-left').addTo(document.body)
    };
};

OnScreenWindow.eventHandler.dragTopLeft = function (event) {
    var d = event.currentPoint.sub(event.startingPoint);
    var dx = d.x;
    var dy = d.y;
    var newTop = Math.max(0, Math.min(this.__moveData__.maxTop, this.__moveData__.bound.top + dy));
    var newHeight = this.__moveData__.bound.bottom - newTop;
    var newLeft = Math.max(0, Math.min(this.__moveData__.maxLeft, this.__moveData__.bound.left + dx));
    var newWidth = this.__moveData__.bound.right - newLeft;
    this.addStyle({
        top: newTop + 'px',
        height: newHeight + 'px',
        width: newWidth + 'px',
        left: newLeft + 'px'
    });
    this.emit('relocation', { type: 'relocation', target: this }, this);
    this.maybeSizeChange();
};


OnScreenWindow.eventHandler.endDragTopLeft = function (event) {
    this.$topLeftResizer.off('drag', this.eventHandler.dragTopLeft);
    this.$topLeftResizer.off('dragend', this.eventHandler.endDragTopLeft);
    this.__moveData__.modal.remove();
    this.__moveData__ = undefined;

};


OnScreenWindow.eventHandler.beginDragTopRight = function (event) {
    if (event.target != this.$topRightResizer) return;
    this.$topRightResizer.on('drag', this.eventHandler.dragTopRight);
    this.$topRightResizer.on('dragend', this.eventHandler.endDragTopRight);
    var screenSize = absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_5__[/* default */ "b"].getScreenSize();
    var bound = this.getBoundingClientRect();
    var fontSize = this.getFontSize();
    var minWidth = this.$windowTitle.getBoundingClientRect().right - bound.left + this.$headerButtonCtn.getBoundingClientRect().width;
    this.__moveData__ = {
        minWidth: minWidth,
        fontSize: fontSize,
        bound: bound,
        maxWidth: screenSize.width - bound.left,
        maxTop: bound.bottom - 1.4 * fontSize,
        modal: _('.absol-onscreen-window-moving-modal.absol-onscreen-window-resize-top-right').addTo(document.body)
    };
};

OnScreenWindow.eventHandler.dragTopRight = function (event) {
    var d = event.currentPoint.sub(event.startingPoint);
    var dx = d.x;
    var dy = d.y;
    var newWidth = Math.max(this.__moveData__.minWidth, Math.min(this.__moveData__.maxWidth, this.__moveData__.bound.width + dx));
    var newTop = Math.max(0, Math.min(this.__moveData__.maxTop, this.__moveData__.bound.top + dy));
    var newHeight = this.__moveData__.bound.bottom - newTop;
    this.addStyle({
        'top': newTop + 'px',
        'height': newHeight + 'px',
        width: newWidth + 'px'
    });
    this.emit('relocation', { type: 'relocation', target: this }, this);
    this.maybeSizeChange();
};


OnScreenWindow.eventHandler.endDragTopRight = function (event) {
    this.$topRightResizer.off('drag', this.eventHandler.dragTopRight);
    this.$topRightResizer.off('dragend', this.eventHandler.endDragTopRight);
    this.__moveData__.modal.remove();
    this.__moveData__ = undefined;

};


['addChild', 'addChildBefore', 'addChildAfter', 'clearChild', 'findChildBefore', 'findChildAfter'].forEach(function (key) {
    OnScreenWindow.prototype[key] = function () {
        return this.$bodyContainer[key].apply(this.$bodyContainer, arguments);
    };
});


OnScreenWindow.property = {};

OnScreenWindow.property.windowIcon = {
    set: function (value) {
        this._windowIcon = value;
        if (this.$windowIcon) {
            this.$windowIcon.remove();
            this.$windowIcon = undefined;
        }
        if (value) {
            this.$windowIcon = _(value).addClass('absol-onscreen-window-head-bar-icon');
            this.$headerbar.addChildBefore(this.$windowIcon, this.$headerbar.childNodes[0]);
        }
    },
    get: function () {
        return this._windowIcon;
    }
};


OnScreenWindow.property.windowTitle = {
    set: function (value) {
        this._windowTitle = value;
        this.$windowTitle
            .clearChild()
            .addChild(_({
                text: '' + value
            }));
    },
    get: function () {
        return this._windowTitle;
    }
};


OnScreenWindow.prototype.relocation = function () {
    var bound = this.getBoundingClientRect();
    var screenSize = absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_5__[/* default */ "b"].getScreenSize();
    var isRelocated = false;
    if (bound.bottom >= screenSize.height) {
        this.addStyle('top', Math.max(0, screenSize.height - bound.height) + 'px');
        isRelocated = true;
    }
    if (bound.right >= screenSize.width) {
        this.addStyle('left', Math.max(0, screenSize.width - bound.width) + 'px');
        isRelocated = true;
    }

    if (isRelocated) {
        this.emit('relocation', { type: 'relocation', target: this }, this)
    }
};


_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(OnScreenWindow);

/* harmony default export */ __webpack_exports__["a"] = (OnScreenWindow);

/***/ }),
/* 56 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _AElement__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(8);
/* harmony import */ var _OOP__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2);



/***
 * @augments AElement
 * @augments SVGGraphicsElement
 * @constructor
 */
function AElementNS() {
    _AElement__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].call(this);
}

_AElement__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].prototype.afterAttached = function () {
    if (this.isDescendantOf(document.body)) return Promise.resolve();
    var attachHookElt = this.$attachhook || this.querySelector('.absol-attachhook');
    if (!attachHookElt) {
        var constructor;
        if (this.tagName.toLowerCase() === 'svg' || this.getBBox) {
            attachHookElt = document.createElementNS('http://www.w3.org/2000/svg', 'image');
            attachHookElt.setAttributeNS(null,  'href','');
            constructor = AElementNS;
        }
        else {
            attachHookElt = document.createElement('img');
            attachHookElt.src = '';
            constructor = AElementNS;
        }

        attachHookElt.classList.add('absol-attachhook');
        Object.assign(attachHookElt, constructor.prototype);
        constructor.call(attachHookElt);
        attachHookElt.defineEvent('attached');
        this.$attachhook = attachHookElt;
        this.$attachhook.on('error', function (event) {
            if (this.isDescendantOf(document.body)) this.emit('attached', event, this);
        });
        this.appendChild(attachHookElt);
    }
    return new Promise(function (rs) {
        attachHookElt.once('attached', rs);
    });
};


_OOP__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"].mixClass(AElementNS, _AElement__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"]);

AElementNS.prototype.attr = function () {
    if (arguments.length == 1) {
        if (typeof (arguments[0]) == 'string') {
            if (this._azar_extendAttributes[arguments[0]]) {
                return this._azar_extendAttributes[arguments[0]].get.call(this);
            }
            else
                return this.getAttributeNS(null, arguments[0]);
        }
        else {
            for (var key in arguments[0]) {

                this.attr(key, arguments[0][key]);
            }
        }
    }
    else {
        if (arguments.length == 2) {
            if (arguments[1] === null || arguments[1] === undefined) {
                if (this._azar_extendAttributes[arguments[0]]) {
                    this._azar_extendAttributes[arguments[0]].remove.call(this, arguments[1]);
                }
                else
                    this.removeAttributeNS(null, arguments[0]);
            }
            else {
                if (this._azar_extendAttributes[arguments[0]]) {
                    this._azar_extendAttributes[arguments[0]].set.call(this, arguments[1]);
                }
                else {
                    this.setAttributeNS(null, arguments[0], arguments[1]);
                }
            }
        }
    }
    return this;
};



/* harmony default export */ __webpack_exports__["a"] = (AElementNS);

/***/ }),
/* 57 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _JSMaker_TemplateString__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(26);


function Color(rgba) {
    this.rgba = rgba.slice();
}


Color.prototype.toHex6 = function () {
    return this.rgba.slice(0, 3).map(function (b) {
        b = b * 255 >> 0;
        return (b < 16 ? '0' : '') + b.toString(16);
    }).join('');
};

Color.prototype.toHex8 = function () {
    return this.rgba.map(function (b) {
        b = b * 255 >> 0;
        return (b < 16 ? '0' : '') + b.toString(16);
    }).join('');
};

Color.prototype.toHex3 = function () {
    return this.rgba.slice(0, 3).map(function (b) {
        b = b * 255 / 17 >> 0;
        return b.toString(16);
    }).join('');
};

Color.prototype.toHex4 = function () {
    return this.rgba.map(function (b) {
        b = b * 255 / 17 >> 0;
        return b.toString(16);
    }).join('');
};


Color.prototype.toHSLA = function () {
    return Color.rgbaToHSLA(this.rgba);
};


Color.prototype.toHSBA = function () {
    return Color.rgbaToHSBA(this.rgba);
};

Color.prototype.toHWBA = function () {
    return Color.rgbaToHWBA(this.rgba);
};


Color.prototype.getHightContrastColor = function () {
    var hsba = this.toHSBA();
    var h, s, b;
    h = hsba[0] > 0.5 ? hsba[0] - 0.5 : hsba[0] + 0.5;
    s = hsba[1] > 0.5 ? hsba[1] - 0.5 : hsba[1] + 0.5;
    b = hsba[2] > 0.5 ? hsba[2] - 0.5 : hsba[2] + 0.5;
    return Color.fromHSB(h, s, b);
};


Color.prototype.getContrastYIQ = function () {
    var r = this.rgba[0] * 255;
    var g = this.rgba[1] * 255;
    var b = this.rgba[2] * 255;
    var yiq = ((r * 299) + (g * 587) + (b * 114)) / 1000;
    return (yiq >= 128) ? new Color([0, 0, 0, 1]) : new Color([1, 1, 1, 1]);
};

Color.prototype.clone = function () {
    return new Color(this.rgba.slice());
};

Color.prototype.toString = function (mode) {
    mode = mode || 'rgba';
    mode = mode.toLocaleLowerCase();
    return Color.templates[mode](this);
};

/***
 *
 */
Color.prototype.nearestNamedColor = function (notStandard, hsbWeight) {
    hsbWeight = hsbWeight ||[5, 3, 1]
    var hsba = this.toHSBA();
    var bestMatch = null;
    var dist = 1000;
    Object.keys(Color.namedColors).concat(notStandard ? Object.keys(Color.nonStandarNamedColors) : []).forEach(function (name) {
        var c = Color.parse(Color.namedColors[name] || Color.nonStandarNamedColors[name]);
        var cHSBA = c.toHSBA();
        var cDist = Math.abs(hsba[0] - cHSBA[0]) * hsbWeight[0] + Math.abs(hsba[1] - cHSBA[1]) *  hsbWeight[1] + Math.abs(hsba[2] - cHSBA[2])*  hsbWeight[2];
        if (cDist < dist) {
            dist = cDist;
            bestMatch = name;
        }
    });
    return bestMatch;
};

Color.templates = [
    ['rgba', 'rgba', 'rgba({{x[0]*255>>0}}, {{x[1]*255>>0}}, {{x[2]*255>>0}}, {{x[3]}})'],
    ['rgb', 'rgba', 'rgb({{x[0]*255>>0}}, {{x[1]*255>>0}}, {{x[2]*255>>0}})'],
    ['hsl', 'toHSLA()', 'hsl({{x[0] * 360}}, {{x[1] * 100}}%, {{x[2] * 100}}%)'],
    ['hsla', 'toHSLA()', 'hsla({{x[0] * 360}}, {{x[1] * 100}}%, {{x[2] * 100}}%, {{x[3]}})'],
    ['hsb', 'toHSBA()', 'hsb({{x[0] * 360}}, {{x[1] * 100}}%, {{x[2] * 100}}%)'],
    ['hsba', 'toHSBA()', 'hsba({{x[0] * 360}}, {{x[1] * 100}}%, {{x[2] * 100}}%, {{x[3]}})'],
    ['hex3', 'toHex3()', '#{{x}}'],
    ['hex4', 'toHex4()', '#{{x}}'],
    ['hex6', 'toHex6()', '#{{x}}'],
    ['hex8', 'toHex8()', '#{{x}}'],
    ['hwb', 'toHWBA()', 'hwb({{x[0] * 360}}, {{x[1] * 100}}%, {{x[2] * 100}}%)'],
    ['hwba', 'toHWBA()', 'hwba({{x[0] * 360}}, {{x[1] * 100}}%, {{x[2] * 100}}%, {{x[3]}})']
].reduce(function (ac, cr) {
    ac[cr[0]] = new Function('color', [
        'var x = color.' + cr[1] + ';',
        'return ' + _JSMaker_TemplateString__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].parse(cr[2]).toJSCode() + ';'
    ].join('\n'));
    return ac;
}, {});


Color.regexes = {
    whiteSpace: /\s*/, // Match zero or more whitespace characters.
    integer: /(\d{1,3})/, // Match integers: 79, 255, etc.
    decimal: /((?:\d+(?:\.\d+)?)|(?:\.\d+))/, // Match 129.6, 79, .9, etc.
    percent: /((?:\d+(?:\.\d+)?)|(?:\.\d+))%/, // Match 12.9%, 79%, .9%, etc.
    hex3: /^#([a-f0-9])([a-f0-9])([a-f0-9])$/i,

    // Match colors in format #XXXX, e.g. #5123.
    hex4: /^#([a-f0-9])([a-f0-9])([a-f0-9])([a-f0-9])$/i,

    // Match colors in format #XXXXXX, e.g. #b4d455.
    hex6: /^#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})$/i,

    // Match colors in format #XXXXXXXX, e.g. #b4d45535.
    hex8: /^#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})$/i
};


Color.regexes.percent = new RegExp(Color.regexes.decimal.source + '%');

Color.regexes.rgb = new RegExp(
    [
        '^rgb\\(',
        Color.regexes.integer.source,
        ',',
        Color.regexes.integer.source,
        ',',
        Color.regexes.integer.source,
        '\\)$'
    ].join(Color.regexes.whiteSpace.source),
    'i'
);

Color.regexes.rgbPercent = new RegExp(
    [
        '^rgb\\(',
        Color.regexes.percent.source,
        ',',
        Color.regexes.percent.source,
        ',',
        Color.regexes.percent.source,
        '\\)$'
    ].join(Color.regexes.whiteSpace.source),
    'i'
);

// Match colors in format rgb(R, G, B, A), e.g. rgb(255, 0, 128, 0.25).
Color.regexes.rgba = new RegExp(
    [
        '^rgba\\(',
        Color.regexes.integer.source,
        ',',
        Color.regexes.integer.source,
        ',',
        Color.regexes.integer.source,
        ',',
        Color.regexes.decimal.source,
        '\\)$'
    ].join(Color.regexes.whiteSpace.source),
    'i'
);

// Match colors in format rgb(R%, G%, B%, A), e.g. rgb(100%, 0%, 28.9%, 0.5).
Color.regexes.rgbaPercent = new RegExp(
    [
        '^rgba\\(',
        Color.regexes.percent.source,
        ',',
        Color.regexes.percent.source,
        ',',
        Color.regexes.percent.source,
        ',',
        Color.regexes.decimal.source,
        '\\)$'
    ].join(Color.regexes.whiteSpace.source),
    'i'
);
// Match colors in format hsla(H, S%, L%), e.g. hsl(100, 40%, 28.9%).
Color.regexes.hsl = new RegExp(
    [
        '^hsl\\(',
        Color.regexes.integer.source,
        '[deg]*',
        ',',
        Color.regexes.percent.source,
        ',',
        Color.regexes.percent.source,
        '\\)$'
    ].join(Color.regexes.whiteSpace.source),
    'i'
);

// Match colors in format hsla(H, S%, L%, A), e.g. hsla(100, 40%, 28.9%, 0.5).
Color.regexes.hsla = new RegExp(
    [
        '^hsla\\(',
        Color.regexes.integer.source,
        '[deg]*',
        ',',
        Color.regexes.percent.source,
        ',',
        Color.regexes.percent.source,
        ',',
        Color.regexes.decimal.source,
        '\\)$'
    ].join(Color.regexes.whiteSpace.source),
    'i'
);

// Match colors in format hsb(H, S%, B%), e.g. hsb(100, 40%, 28.9%).
Color.regexes.hsb = new RegExp(
    [
        '^hsb\\(',
        Color.regexes.integer.source,
        '[deg]*',
        ',',
        Color.regexes.percent.source,
        ',',
        Color.regexes.percent.source,
        '\\)$'
    ].join(Color.regexes.whiteSpace.source),
    'i'
);

// Match colors in format hsba(H, S%, B%, A), e.g. hsba(100, 40%, 28.9%, 0.5).
Color.regexes.hsba = new RegExp(
    [
        '^hsba\\(',
        Color.regexes.integer.source,
        '[deg]*',
        ',',
        Color.regexes.percent.source,
        ',',
        Color.regexes.percent.source,
        ',',
        Color.regexes.decimal.source,
        '\\)$'
    ].join(Color.regexes.whiteSpace.source),
    'i'
);

Color.regexes.hwb = new RegExp(
    [
        '^hwb\\(',
        Color.regexes.integer.source,
        '[deg]*',
        ',',
        Color.regexes.percent.source,
        ',',
        Color.regexes.percent.source,
        '\\)$'
    ].join(Color.regexes.whiteSpace.source),
    'i'
);

// Match colors in format hsba(H, S%, B%, A), e.g. hsba(100, 40%, 28.9%, 0.5).
Color.regexes.hwba = new RegExp(
    [
        '^hwba\\(',
        Color.regexes.integer.source,
        '[deg]*',
        ',',
        Color.regexes.percent.source,
        ',',
        Color.regexes.percent.source,
        ',',
        Color.regexes.decimal.source,
        '\\)$'
    ].join(Color.regexes.whiteSpace.source),
    'i'
);


Color.fromInt = function (code, bits) {
    var r, g, b, a;
    if (bits == 32) {
        b = (code & 0xff) / 255;
        g = ((code & 0xff00) >> 8) / 255;
        r = ((code & 0xff0000) >> 16) / 255;
        a = (code >> 24) / 255;
    }
    else if (bits == 24) {
        b = (code & 0xff) / 255;
        g = ((code & 0xff00) >> 8) / 255;
        r = ((code & 0xff0000) >> 16) / 255;
        a = 1;
    }
    else if (bits == 16) {
        b = (code & 0x1f) / 0x1f;
        g = ((code & 0x7e0) >> 5) / 0x3f;
        b = (code >> 10) / 0x1f;
        a = 1;
    }
    else if (bits == 8) {//gray-scale
        b = (code & 0x3) / 0x3;
        g = ((code & 0x1c) >> 2) / 0x7;
        b = (code >> 5) / 0x7;
        a = 1;
    }

    return new Color([r, g, b, a]);
};


Color.fromRGB = function (r, g, b) {
    return new Color([r, g, b, 1]);
};

Color.fromRGBA = function (r, g, b, a) {
    return new Color([r, g, b, a]);
};

Color.fromHSL = function (h, s, l) {
    var rgba = this.hslaToRGBA([h, s, l, 1]);
    return new Color(rgba);
};

Color.fromHSLA = function (h, s, l, a) {
    var rgba = this.hslaToRGBA([h, s, l, a]);
    return new Color(rgba);
};

Color.fromHSB = function (h, s, b) {
    var rgba = this.hsbaToRGBA([h, s, b, 1]);
    return new Color(rgba);
};

Color.fromHSBA = function (h, s, b, a) {
    var rgba = this.hsbaToRGBA([h, s, b, a]);
    return new Color(rgba);
};

Color.fromHWB = function (h, s, b) {
    var rgba = this.hwbaToRGBA([h, s, b, 1]);
    return new Color(rgba);
};

Color.fromHWBA = function (h, s, b, a) {
    var rgba = this.hwbaToRGBA([h, s, b, a]);
    return new Color(rgba);
};


/**
 * @param {String} text
 * @returns {Color}
 */
Color.parse = function (text) {
    if (this.namedColors[text]) text = this.namedColors[text];
    if (this.nonStandarNamedColors[text]) text = this.nonStandarNamedColors[text];
    if (this.regexes.hex8.test(text)) {
        return this.fromRGBA.apply(this,
            this.regexes.hex8.exec(text)
                .slice(1)
                .map(function (v) {
                    return parseInt(v, 16) / 255;
                }));
    }
    else if (this.regexes.hex6.test(text)) {
        return this.fromRGB.apply(this,
            this.regexes.hex6.exec(text)
                .slice(1)
                .map(function (v) {
                    return parseInt(v, 16) / 255;
                }));
    }
    else if (this.regexes.hex4.test(text)) {
        return this.fromRGBA.apply(this,
            this.regexes.hex4.exec(text)
                .slice(1)
                .map(function (v) {
                    return parseInt(v + v, 16) / 255;
                }));
    }
    else if (this.regexes.hex3.test(text)) {
        return this.fromRGB.apply(this,
            this.regexes.hex3.exec(text)
                .slice(1)
                .map(function (v) {
                    return parseInt(v + v, 16) / 255;
                }));
    }
    else if (this.regexes.rgba.test(text)) {
        return this.fromRGBA.apply(this,
            this.regexes.rgba.exec(text)
                .slice(1)
                .map(function (v, i) {
                    return i < 3 ? parseFloat(v, 10) / 255 : parseFloat(v, 10);
                }));
    }
    else if (this.regexes.rgb.test(text)) {
        return this.fromRGB.apply(this,
            this.regexes.rgb.exec(text)
                .slice(1)
                .map(function (v, i) {
                    return parseFloat(v, 10) / 255;
                }));
    }
    else if (this.regexes.rgbPercent.test(text)) {
        return this.fromRGB.apply(this,
            this.regexes.rgbPercent.exec(text)
                .slice(1)
                .map(function (v, i) {
                    return parseFloat(v, 10) / 100;
                }));
    }
    else if (this.regexes.rgbaPercent.test(text)) {
        return this.fromRGBA.apply(this,
            this.regexes.rgbaPercent.exec(text)
                .slice(1)
                .map(function (v, i) {
                    return parseFloat(v, 10) / (i < 3 ? 100 : 1);
                }));
    }
    else if (this.regexes.hsl.test(text)) {
        return this.fromHSL.apply(this,
            this.regexes.hsl.exec(text)
                .slice(1)
                .map(function (v, i) {
                    return parseFloat(v, 10) / (i == 0 ? 360 : 100);
                }));
    }
    else if (this.regexes.hsla.test(text)) {
        return this.fromHSLA.apply(this,
            this.regexes.hsla.exec(text)
                .slice(1)
                .map(function (v, i) {
                    return parseFloat(v, 10) / (i == 0 ? 360 : i < 3 ? 100 : 1);
                }));
    }
    else if (this.regexes.hsb.test(text)) {
        return this.fromHSB.apply(this,
            this.regexes.hsb.exec(text)
                .slice(1)
                .map(function (v, i) {
                    return parseFloat(v, 10) / (i == 0 ? 360 : 100);
                }));
    }
    else if (this.regexes.hsba.test(text)) {
        return this.fromHSBA.apply(this,
            this.regexes.hsba.exec(text)
                .slice(1)
                .map(function (v, i) {
                    return parseFloat(v, 10) / (i == 0 ? 360 : i < 3 ? 100 : 1);
                }));
    }
    else if (this.regexes.hwb.test(text)) {
        return this.fromHWB.apply(this,
            this.regexes.hwb.exec(text)
                .slice(1)
                .map(function (v, i) {
                    return parseFloat(v, 10) / (i == 0 ? 360 : 100);
                }));
    }
    else if (this.regexes.hwba.test(text)) {
        return this.fromHWBA.apply(this,
            this.regexes.hwba.exec(text)
                .slice(1)
                .map(function (v, i) {
                    return parseFloat(v, 10) / (i == 0 ? 360 : i < 3 ? 100 : 1);
                }));
    }
    else {
        throw new Error("Fail to parse " + text);
    }
};

/***
 * @typedef {"aliceblue"|"antiquewhite"|"aqua"|"aquamarine"|"azure"|"beige"|"bisque"|"black"|"blanchedalmond"|"blue"|"blueviolet"|"brown"|"burlywood"|"cadetblue"|"chartreuse"|"chocolate"|"coral"|"cornflowerblue"|"cornsilk"|"crimson"|"cyan"|"darkblue"|"darkcyan"|"darkgoldenrod"|"darkgray"|"darkgreen"|"darkgrey"|"darkkhaki"|"darkmagenta"|"darkolivegreen"|"darkorange"|"darkorchid"|"darkred"|"darksalmon"|"darkseagreen"|"darkslateblue"|"darkslategray"|"darkslategrey"|"darkturquoise"|"darkviolet"|"deeppink"|"deepskyblue"|"dimgray"|"dimgrey"|"dodgerblue"|"firebrick"|"floralwhite"|"forestgreen"|"fuchsia"|"gainsboro"|"ghostwhite"|"gold"|"goldenrod"|"gray"|"green"|"greenyellow"|"grey"|"honeydew"|"hotpink"|"indianred"|"indigo"|"ivory"|"khaki"|"lavender"|"lavenderblush"|"lawngreen"|"lemonchiffon"|"lightblue"|"lightcoral"|"lightcyan"|"lightgoldenrodyellow"|"lightgray"|"lightgreen"|"lightgrey"|"lightpink"|"lightsalmon"|"lightseagreen"|"lightskyblue"|"lightslategray"|"lightslategrey"|"lightsteelblue"|"lightyellow"|"lime"|"limegreen"|"linen"|"magenta"|"maroon"|"mediumaquamarine"|"mediumblue"|"mediumorchid"|"mediumpurple"|"mediumseagreen"|"mediumslateblue"|"mediumspringgreen"|"mediumturquoise"|"mediumvioletred"|"midnightblue"|"mintcream"|"mistyrose"|"moccasin"|"navajowhite"|"navy"|"oldlace"|"olive"|"olivedrab"|"orange"|"orangered"|"orchid"|"palegoldenrod"|"palegreen"|"paleturquoise"|"palevioletred"|"papayawhip"|"peachpuff"|"peru"|"pink"|"plum"|"powderblue"|"purple"|"red"|"rosybrown"|"royalblue"|"saddlebrown"|"salmon"|"sandybrown"|"seagreen"|"seashell"|"sienna"|"silver"|"skyblue"|"slateblue"|"slategray"|"slategrey"|"snow"|"springgreen"|"steelblue"|"tan"|"teal"|"thistle"|"tomato"|"turquoise"|"violet"|"wheat"|"white"|"whitesmoke"|"yellow"|"yellowgreen"|"transparent"} NamedColor
 */

Color.namedColors = {
    aliceblue: '#f0f8ff',
    antiquewhite: '#faebd7',
    aqua: '#00ffff',
    aquamarine: '#7fffd4',
    azure: '#f0ffff',
    beige: '#f5f5dc',
    bisque: '#ffe4c4',
    black: '#000000',
    blanchedalmond: '#ffebcd',
    blue: '#0000ff',
    blueviolet: '#8a2be2',
    brown: '#a52a2a',
    burlywood: '#deb887',
    cadetblue: '#5f9ea0',
    chartreuse: '#7fff00',
    chocolate: '#d2691e',
    coral: '#ff7f50',
    cornflowerblue: '#6495ed',
    cornsilk: '#fff8dc',
    crimson: '#dc143c',
    cyan: '#00ffff',
    darkblue: '#00008b',
    darkcyan: '#008b8b',
    darkgoldenrod: '#b8860b',
    darkgray: '#a9a9a9',
    darkgreen: '#006400',
    darkgrey: '#a9a9a9',
    darkkhaki: '#bdb76b',
    darkmagenta: '#8b008b',
    darkolivegreen: '#556b2f',
    darkorange: '#ff8c00',
    darkorchid: '#9932cc',
    darkred: '#8b0000',
    darksalmon: '#e9967a',
    darkseagreen: '#8fbc8f',
    darkslateblue: '#483d8b',
    darkslategray: '#2f4f4f',
    darkslategrey: '#2f4f4f',
    darkturquoise: '#00ced1',
    darkviolet: '#9400d3',
    deeppink: '#ff1493',
    deepskyblue: '#00bfff',
    dimgray: '#696969',
    dimgrey: '#696969',
    dodgerblue: '#1e90ff',
    firebrick: '#b22222',
    floralwhite: '#fffaf0',
    forestgreen: '#228b22',
    fuchsia: '#ff00ff',
    gainsboro: '#dcdcdc',
    ghostwhite: '#f8f8ff',
    gold: '#ffd700',
    goldenrod: '#daa520',
    gray: '#808080',
    green: '#008000',
    greenyellow: '#adff2f',
    grey: '#808080',
    honeydew: '#f0fff0',
    hotpink: '#ff69b4',
    indianred: '#cd5c5c',
    indigo: '#4b0082',
    ivory: '#fffff0',
    khaki: '#f0e68c',
    lavender: '#e6e6fa',
    lavenderblush: '#fff0f5',
    lawngreen: '#7cfc00',
    lemonchiffon: '#fffacd',
    lightblue: '#add8e6',
    lightcoral: '#f08080',
    lightcyan: '#e0ffff',
    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',
    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',
    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',
    transparent: '#00000000'
};

Color.nonStandarNamedColors = {
    night: '#0C090A',
    gunmetal: '#2C3539',
    midnight: '#2B1B17',
    charcoal: '#34282C',
    oil: '#3B3131',
    blackcat: '#413839',
    iridium: '#3D3C3A',
    blackeel: '#463E3F',
    blackcow: '#4C4646',
    graywolf: '#504A4B',
    vampiregray: '#565051',
    graydolphin: '#5C5858',
    carbongray: '#625D5D',
    ashgray: '#666362',
    cloudygray: '#6D6968',
    smokeygray: '#726E6D',
    granite: '#837E7C',
    battleshipgray: '#848482',
    graycloud: '#B6B6B4',
    graygoose: '#D1D0CE',
    platinum: '#E5E4E2',
    metallicsilver: '#BCC6CC',
    bluegray: '#98AFC7',
    raven: '#657383',
    jetgray: '#616D7E',
    mistblue: '#646D7E',
    marbleblue: '#566D7E',
    shipcove: '#737CA1',
    mariner: '#4863A0',
    bluejay: '#2B547E',
    biscay: '#2B3856',
    navyblue: '#000080',
    bluewhale: '#342D7E',
    lapisblue: '#15317E',
    denimdarkblue: '#151B8D',
    earthblue: '#0000A0',
    cobaltblue: '#0020C2',
    blueberryblue: '#0041C2',
    sapphireblue: '#2554C7',
    blueeyes: '#1569C7',
    blueorchid: '#1F45FC',
    bluelotus: '#6960EC',
    lightslateblue: '#736AFF',
    windowsblue: '#357EC7',
    glacialblueice: '#368BC1',
    silkblue: '#488AC7',
    blueivy: '#3090C7',
    bluekoi: '#659EC7',
    columbiablue: '#87AFC7',
    babyblue: '#95B9C7',
    oceanblue: '#2B65EC',
    blueribbon: '#306EFF',
    bluedress: '#157DEC',
    butterflyblue: '#38ACEC',
    iceberg: '#56A5EC',
    crystalblue: '#5CB3FF',
    denimblue: '#79BAEC',
    dayskyblue: '#82CAFF',
    jeansblue: '#A0CFEC',
    blueangel: '#B7CEEC',
    pastelblue: '#B4CFEC',
    seablue: '#C2DFFF',
    coralblue: '#AFDCEC',
    robineggblue: '#BDEDFF',
    palebluelily: '#CFECEC',
    water: '#EBF4FA',
    lightslate: '#CCFFFF',
    lightaquamarine: '#93FFE8',
    electricblue: '#9AFEFF',
    cyanoraqua: '#00FFFF',
    tronblue: '#7DFDFE',
    bluezircon: '#57FEFF',
    bluelagoon: '#8EEBEC',
    celeste: '#50EBEC',
    bluediamond: '#4EE2EC',
    tiffanyblue: '#81D8D0',
    cyanopaque: '#92C7C7',
    bluehosta: '#77BFC7',
    northernlightsblue: '#78C7C7',
    jellyfish: '#46C7C7',
    bluegreen: '#7BCCB5',
    macawbluegreen: '#43BFC7',
    seaturtlegreen: '#438D80',
    greenishblue: '#307D7E',
    grayishturquoise: '#5E7D7E',
    beetlegreen: '#4C787E',
    camouflagegreen: '#78866B',
    sagegreen: '#848b79',
    hazelgreen: '#617C58',
    venomgreen: '#728C00',
    ferngreen: '#667C26',
    darkforestgreen: '#254117',
    mediumforestgreen: '#347235',
    seaweedgreen: '#437C17',
    pinegreen: '#387C44',
    junglegreen: '#347C2C',
    shamrockgreen: '#347C17',
    greenonion: '#6AA121',
    clovergreen: '#3EA055',
    greensnake: '#6CBB3C',
    aliengreen: '#6CC417',
    greenapple: '#4CC417',
    kellygreen: '#4CC552',
    zombiegreen: '#54C571',
    froggreen: '#99C68E',
    greenpeas: '#89C35C',
    dollarbillgreen: '#85BB65',
    iguanagreen: '#9CB071',
    avocadogreen: '#B2C248',
    pistachiogreen: '#9DC209',
    saladgreen: '#A1C935',
    hummingbirdgreen: '#7FE817',
    nebulagreen: '#59E817',
    stoplightgogreen: '#57E964',
    algaegreen: '#64E986',
    jadegreen: '#5EFB6E',
    emeraldgreen: '#5FFB17',
    dragongreen: '#6AFB92',
    mintgreen: '#98FF98',
    greenthumb: '#B5EAAA',
    lightjade: '#C3FDB8',
    teagreen: '#CCFB5D',
    slimegreen: '#BCE954',
    harvestgold: '#EDE275',
    sunyellow: '#FFE87C',
    cornyellow: '#FFF380',
    parchment: '#FFFFC2',
    cream: '#FFFFCC',
    blonde: '#FBF6D9',
    champagne: '#F7E7CE',
    vanilla: '#F3E5AB',
    tanbrown: '#ECE5B6',
    peach: '#FFE5B4',
    mustard: '#FFDB58',
    rubberduckyyellow: '#FFD801',
    brightgold: '#FDD017',
    goldenbrown: '#EAC117',
    macaroniandcheese: '#F2BB66',
    saffron: '#FBB917',
    beer: '#FBB117',
    cantaloupe: '#FFA62F',
    beeyellow: '#E9AB17',
    brownsugar: '#E2A76F',
    deeppeach: '#FFCBA4',
    gingerbrown: '#C9BE62',
    schoolbusyellow: '#E8A317',
    fallleafbrown: '#C8B560',
    orangegold: '#D4A017',
    sand: '#C2B280',
    cookiebrown: '#C7A317',
    caramel: '#C68E17',
    brass: '#B5A642',
    camelbrown: '#C19A6B',
    bronze: '#CD7F32',
    tigerorange: '#C88141',
    cinnamon: '#C58917',
    bulletshell: '#AF9B60',
    copper: '#B87333',
    wood: '#966F33',
    oakbrown: '#806517',
    armybrown: '#827B60',
    sandstone: '#786D5F',
    mocha: '#493D26',
    taupe: '#483C32',
    coffee: '#6F4E37',
    brownbear: '#835C3B',
    reddirt: '#7F5217',
    sepia: '#7F462C',
    orangesalmon: '#C47451',
    rust: '#C36241',
    redfox: '#C35817',
    sedona: '#CC6600',
    papayaorange: '#E56717',
    halloweenorange: '#E66C2C',
    pumpkinorange: '#F87217',
    constructionconeorange: '#F87431',
    sunriseorange: '#E67451',
    mangoorange: '#FF8040',
    basketballorange: '#F88158',
    tangerine: '#E78A61',
    beanred: '#F75D59',
    valentinered: '#E55451',
    shockingorange: '#E55B3C',
    scarlet: '#FF2400',
    rubyred: '#F62217',
    ferrarired: '#F70D1A',
    fireenginered: '#F62817',
    lavared: '#E42217',
    lovered: '#E41B17',
    grapefruit: '#DC381F',
    chestnutred: '#C34A2C',
    cherryred: '#C24641',
    mahogany: '#C04000',
    chillipepper: '#C11B17',
    cranberry: '#9F000F',
    redwine: '#990012',
    burgundy: '#8C001A',
    chestnut: '#954535',
    bloodred: '#7E3517',
    sangria: '#7E3817',
    plumpie: '#7D0541',
    velvetmaroon: '#7E354D',
    plumvelvet: '#7D0552',
    rosyfinch: '#7F4E52',
    puce: '#7F5A58',
    dullpurple: '#7F525D',
    khakirose: '#C5908E',
    pinkbow: '#C48189',
    lipstickpink: '#C48793',
    rose: '#E8ADAA',
    rosegold: '#ECC5C0',
    desertsand: '#EDC9AF',
    pigpink: '#FDD7E4',
    cottoncandy: '#FCDFFF',
    pinkbubblegum: '#FFDFDD',
    flamingopink: '#F9A7B0',
    pinkrose: '#E7A1B0',
    pinkdaisy: '#E799A3',
    cadillacpink: '#E38AAE',
    carnationpink: '#F778A1',
    blushred: '#E56E94',
    watermelonpink: '#FC6C85',
    violetred: '#F6358A',
    pinkcupcake: '#E45E9D',
    pinklemonade: '#E4287C',
    neonpink: '#F535AA',
    dimorphothecamagenta: '#E3319D',
    brightneonpink: '#F433FF',
    tulippink: '#C25A7C',
    roguepink: '#C12869',
    burntpink: '#C12267',
    bashfulpink: '#C25283',
    darkcarnationpink: '#C12283',
    violapurple: '#7E587E',
    purpleiris: '#571B7E',
    plumpurple: '#583759',
    purplemonster: '#461B7E',
    purplehaze: '#4E387E',
    eggplant: '#614051',
    grape: '#5E5A80',
    purplejam: '#6A287E',
    purpleflower: '#A74AC7',
    purpleamethyst: '#6C2DC7',
    purplesagebush: '#7A5DC7',
    lovelypurple: '#7F38EC',
    aztechpurple: '#893BFF',
    jasminepurple: '#A23BEC',
    purpledaffodil: '#B041FF',
    tyrianpurple: '#C45AEC',
    crocuspurple: '#9172EC',
    purplemimosa: '#9E7BFF',
    heliotropepurple: '#D462FF',
    purpledragon: '#C38EC7',
    lilac: '#C8A2C8',
    blushpink: '#E6A9EC',
    mauve: '#E0B0FF',
    wisteriapurple: '#C6AEC7',
    blossompink: '#F9B7FF',
    periwinkle: '#E9CFEC',
    lavenderpinocchio: '#EBDDE2',
    lavenderblue: '#E3E4FA',
    pearl: '#FDEEF4',
    milkwhite: '#FEFCFF'
};

/********************** COLOR CONVERTER *******************/


Color.rgbToHex = function (rgb) {
    return '#' + rgb.slice(0, 3).map(function (c) {
        var res = ((c * 255) >> 0).toString(16);
        if (res < 10) res = '0' + res;
        return res.toUpperCase();
    }).join('');
};

Color.rgbaToHex = function (rgb) {
    return '#' + rgb.map(function (c) {
        var res = ((c * 255) >> 0).toString(16);
        if (res < 10) res = '0' + res;
        return res.toUpperCase();
    }).join('');
};

Color.hsbaToText = function (hsba) {
    return 'hsba(' + (hsba[0] * 360 >> 0) + 'deg, ' + (hsba[1] * 100 >> 0) + '%, ' + (hsba[2] * 100 >> 0) + '%, ' + (hsba[3].toFixed(3)) + ')';
};

Color.hslaToText = function (hsla) {
    return 'hsla(' + (hsla[0] * 360 >> 0) + 'deg, ' + (hsla[1] * 100 >> 0) + '%, ' + (hsla[2] * 100 >> 0) + '%, ' + (hsla[3].toFixed(3)) + ')';
};

Color.rgbaToText = function (rgba) {
    return 'rgba(' + (rgba[0] * 255 >> 0) + ', ' + (rgba[1] * 255 >> 0) + ', ' + (rgba[2] * 255 >> 0) + ', ' + (rgba[3].toFixed(3)) + ')';
};

Color.hsbToText = function (hsba) {
    return 'hsb(' + (hsba[0] * 360 >> 0) + 'deg, ' + (hsba[1] * 100 >> 0) + '%, ' + (hsba[2] * 100 >> 0) + '%)';
};

Color.hslToText = function (hsl) {
    return 'hsl(' + (hsl[0] * 360 >> 0) + 'deg, ' + (hsl[1] * 100 >> 0) + '%, ' + (hsl[2] * 100 >> 0) + '%)';
};

Color.rgbToText = function (rgba) {
    return 'rgb(' + (rgba[0] * 255 >> 0) + ', ' + (rgba[1] * 255 >> 0) + ', ' + (rgba[2] * 255 >> 0) + ')';
};


Color.hsbaToHSLA = function (hsba) {
    var hue = hsba[0];
    var sat = hsba[1];
    var val = hsba[2];

    // Calculate lightness.
    var li = (2 - sat) * val / 2;

    // Convert saturation.
    if (li !== 0) {
        if (li === 1) {
            sat = 0;
        }
        else if (li < 0.5) {
            sat = sat / (2 - sat);
        }
        else {
            sat = sat * val / (2 - li * 2);
        }
    }

    // Hue and alpha stay the same.
    return [hue, sat, li, hsba[3]];
};

Color.hsbaToRGBA = function (hsba) {
    var hue = hsba[0] * 6; // We will split hue into 6 sectors.
    var sat = hsba[1];
    var val = hsba[2];

    var RGBA = [];

    if (sat === 0) {
        RGBA = [val, val, val, hsba[3]]; // Return early if grayscale.
    }
    else {
        var sector = Math.floor(hue);
        var tint1 = val * (1 - sat);
        var tint2 = val * (1 - sat * (hue - sector));
        var tint3 = val * (1 - sat * (1 + sector - hue));
        var red, green, blue;
        if (sector === 1) {
            // Yellow to green.
            red = tint2;
            green = val;
            blue = tint1;
        }
        else if (sector === 2) {
            // Green to cyan.
            red = tint1;
            green = val;
            blue = tint3;
        }
        else if (sector === 3) {
            // Cyan to blue.
            red = tint1;
            green = tint2;
            blue = val;
        }
        else if (sector === 4) {
            // Blue to magenta.
            red = tint3;
            green = tint1;
            blue = val;
        }
        else if (sector === 5) {
            // Magenta to red.
            red = val;
            green = tint1;
            blue = tint2;
        }
        else {
            // Red to yellow (sector could be 0 or 6).
            red = val;
            green = tint3;
            blue = tint1;
        }
        RGBA = [red, green, blue, hsba[3]];
    }
    return RGBA;
};


Color.hslaToHSBA = function (hsla) {
    var hue = hsla[0];
    var sat = hsla[1];
    var li = hsla[2];

    // Calculate brightness.
    var val;
    if (li < 0.5) {
        val = (1 + sat) * li;
    }
    else {
        val = li + sat - li * sat;
    }

    // Convert saturation.
    sat = 2 * (val - li) / val;

    // Hue and alpha stay the same.
    return [hue, sat, val, hsla[3]];
};

Color.hslaToRGBA = function (hsla) {
    var hue = hsla[0] * 6; // We will split hue into 6 sectors.
    var sat = hsla[1];
    var li = hsla[2];

    var RGBA = [];

    if (sat === 0) {
        RGBA = [li, li, li, hsla[3]]; // Return early if grayscale.
    }
    else {
        // Calculate brightness.
        var val;
        if (li < 0.5) {
            val = (1 + sat) * li;
        }
        else {
            val = li + sat - li * sat;
        }

        // Define zest.
        var zest = 2 * li - val;

        // Implement projection (project onto green by default).
        var hzvToRGB = function (hue, zest, val) {
            if (hue < 0) {
                // Hue must wrap to allow projection onto red and blue.
                hue += 6;
            }
            else if (hue >= 6) {
                hue -= 6;
            }
            if (hue < 1) {
                // Red to yellow (increasing green).
                return zest + (val - zest) * hue;
            }
            else if (hue < 3) {
                // Yellow to cyan (greatest green).
                return val;
            }
            else if (hue < 4) {
                // Cyan to blue (decreasing green).
                return zest + (val - zest) * (4 - hue);
            }
            else {
                // Blue to red (least green).
                return zest;
            }
        };

        // Perform projections, offsetting hue as necessary.
        RGBA = [
            hzvToRGB(hue + 2, zest, val),
            hzvToRGB(hue, zest, val),
            hzvToRGB(hue - 2, zest, val),
            hsla[3]
        ];
    }

    return RGBA;
};


Color.rgbaToHSBA = function (rgba) {
    var red = rgba[0];
    var green = rgba[1];
    var blue = rgba[2];

    var val = Math.max(red, green, blue);
    var chroma = val - Math.min(red, green, blue);

    var hue, sat;
    if (chroma === 0) {
        // Return early if grayscale.
        hue = 0;
        sat = 0;
    }
    else {
        sat = chroma / val;
        if (red === val) {
            // Magenta to yellow.
            hue = (green - blue) / chroma;
        }
        else if (green === val) {
            // Yellow to cyan.
            hue = 2 + (blue - red) / chroma;
        }
        else if (blue === val) {
            // Cyan to magenta.
            hue = 4 + (red - green) / chroma;
        }
        if (hue < 0) {
            // Confine hue to the interval [0, 1).
            hue += 6;
        }
        else if (hue >= 6) {
            hue -= 6;
        }
    }

    return [hue / 6, sat, val, rgba[3]];
};

Color.rgbaToHSLA = function (rgba) {
    var red = rgba[0];
    var green = rgba[1];
    var blue = rgba[2];

    var val = Math.max(red, green, blue);
    var min = Math.min(red, green, blue);
    var li = val + min; // We will halve this later.
    var chroma = val - min;

    var hue, sat;
    if (chroma === 0) {
        // Return early if grayscale.
        hue = 0;
        sat = 0;
    }
    else {
        if (li < 1) {
            sat = chroma / li;
        }
        else {
            sat = chroma / (2 - li);
        }
        if (red === val) {
            // Magenta to yellow.
            hue = (green - blue) / chroma;
        }
        else if (green === val) {
            // Yellow to cyan.
            hue = 2 + (blue - red) / chroma;
        }
        else if (blue === val) {
            // Cyan to magenta.
            hue = 4 + (red - green) / chroma;
        }
        if (hue < 0) {
            // Confine hue to the interval [0, 1).
            hue += 6;
        }
        else if (hue >= 6) {
            hue -= 6;
        }
    }

    return [hue / 6, sat, li / 2, rgba[3]];
};


Color.hwbaToHSBA = function (hwba) {
    return [hwba[0], 1 - hwba[1] / (1 - hwba[2]), 1 - hwba[2], hwba[3]];
};

Color.hsbaToHWBA = function (hsla) {
    return [hsla[0], (1 - hsla[1]) * hsla[2], 1 - hsla[2], hsla[3]];
};

Color.rgbaToHWBA = function (rgba) {
    return this.hsbaToHWBA(this.rgbaToHSBA(rgba));
};

Color.hwbaToRGBA = function (hwba) {
    return this.hsbaToRGBA(this.hwbaToHSBA(hwba));
};

/* harmony default export */ __webpack_exports__["a"] = (Color);

/***/ }),
/* 58 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3);


var STATE_INIT = 0;
var STATE_ATTACHED = 1;
var STATE_RELEASED = 2;
var STATE_FIRED = 3;
var STATE_DESTROYED = 4;

/***
 *
 * @param {AElement[]|AElement} eltList
 * @param {"click"|"mousedown"} eventType
 * @param {function} callback
 * @param {number=} initAfter
 * @param {number=} fireDelay
 * @param {*[]=} args
 * @constructor
 */
function BlurTrigger(eltList, eventType, callback, initAfter, fireDelay, args) {
    this.args = args || [];
    this.callback = callback;
    this.eltTargets = eltList || [];
    this.initAfter = initAfter || 0;
    this.fireDelay = fireDelay || 0;
    this.state = STATE_INIT;
    this.eventType = eventType;
    this['ev_mouse'] = this.ev_mouse.bind(this);
    this['ev_blur'] = this.ev_blur.bind(this);
    if (this.initAfter > 0) {
        setTimeout(this._attach.bind(this));
    }
    else this._attach();
}

BlurTrigger.prototype._attach = function () {
    if (this.state !== STATE_INIT) return;
    document.addEventListener(this.eventType, this.ev_mouse);
    window.addEventListener('blur', this.ev_blur);
    this.state = STATE_ATTACHED;
};

BlurTrigger.prototype._fire = function () {
    if (this.state !== STATE_RELEASED) return;
    this.callback.apply(this, this.args);
    this.state = STATE_FIRED;
};

BlurTrigger.prototype._release = function () {
    if (this.state !== STATE_ATTACHED) return;
    document.removeEventListener(this.eventType, this.ev_mouse);
    window.removeEventListener('blur', this.ev_blur);
    this.state = STATE_RELEASED;
};


BlurTrigger.prototype.destroy = function () {
    if (this.state === 4) return;
    if (this.state === STATE_ATTACHED) this._release();
    this.state = STATE_DESTROYED;
};

BlurTrigger.prototype._prepareFire = function () {
    if (this.fireDelay > 0) {
        setTimeout(this._fire.bind(this), this.fireDelay);
    }
    else {
        this._fire();
    }
}

BlurTrigger.prototype.ev_mouse = function (event) {
    var hit = false;
    if (this.eltTargets instanceof Array) {
        hit = this.eltTargets.some(function (elt) {
            return Object(absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_0__[/* hitElement */ "d"])(elt, event);
        });
    }
    else if (typeof hit === "function") {
        hit = this.eltTargets.call(this, event.target);
    }
    if (!hit) {
        this._release();
        this._prepareFire();
    }
};

BlurTrigger.prototype.ev_blur = function () {
    setTimeout(function () {
        if (this.state !== STATE_ATTACHED) return;
        var tagName = (document.activeElement && document.activeElement.tagName) || '';
        tagName = tagName.toLowerCase();
        if (tagName === 'iframe') {
            this._release();
            this._prepareFire();
        }
    }.bind(this), 0);
};

/* harmony default export */ __webpack_exports__["a"] = (BlurTrigger);


/***/ }),
/* 59 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";

var XHR = {};


XHR.makeHttpObject = function () {
    try {
        return new XMLHttpRequest();
    }
    catch (error) { }
    try {
        return new ActiveXObject("Msxml2.XMLHTTP");
    }
    catch (error) { }
    try {
        return new ActiveXObject("Microsoft.XMLHTTP");
    }
    catch (error) { }

    throw new Error("Could not create HTTP request object.");
};

/***
 * 
 * @param {String} url
 * @param {String} body
 * @param {String} responseType
 * @param {Function} success
 * @param {Function} failure
 * @returns {Promise}
 */
XHR.getRequest = function (url, props, success, failure) {
    return new Promise(function (rs, rj) {
        var request = XHR.makeHttpObject();
        request.open("GET", url, true);
        if (typeof props == 'string')
            request.responseType = props || '';
        else if (props && (typeof props == 'object')) {
            Object.assign(request, props);
        }
        request.send(null);
        request.onreadystatechange = function () {
            if (request.readyState == 4) {
                if (request.status == 200) {
                    var response = request.response;
                    success && success(response);
                    rs(response);
                }
                else {
                    failure && failure(request.status, request.statusText);
                    rj(request.status);
                }
            }
        };

        request.onerror = function () {
            failure && failure(request.status, request.statusText);
            rj(new Error(request.status + request.statusText));
        };
    });
};


XHR.postRepquest = function (url, payload, props, headers, success, failure) {
    return new Promise(function (rs, rj) {
        var method = "POST";
        var shouldBeAsync = true;

        var request = XHR.makeHttpObject();

        request.onreadystatechange = function () {
            if (request.readyState == 4) {
                if (request.status == 200) {
                    success && success(request.response);
                    rs(request.response);
                }
                else if (failure) {
                    failure && failure(request.status, request.statusText);
                    rj({ status: request.status, statusText: request.statusText });
                }
            }
        };

        request.onerror = function () {
            failure && failure(request.status, request.statusText);
            rj(new Error(request.status + request.statusText));
        };

        request.open(method, url, shouldBeAsync);
        if (typeof props == 'string')
            request.responseType = props || '';
        else if (props && (typeof props == 'object')) {
            Object.assign(request, props);
        }
        headers = headers || {};
        headers["Content-Type"] = headers["Content-Type"] || "application/json;charset=UTF-8";
        Object.keys(headers).forEach(function (key) {
            request.setRequestHeader(key, headers[key]);
        });

        request.send(payload);
    });
};

XHR.request = function (method, url, props, headers, body, successCallback, failureCallback) {
    return new Promise(function (rs, rj) {
        var shouldBeAsync = true;
        var request = new XMLHttpRequest();

        request.onreadystatechange = function () {
            if (request.readyState == 4) {
                if (request.status == 200) {
                    successCallback && successCallback(request.response);
                    rs(request.response);
                }
                else {
                    failureCallback && failureCallback(request.status, request.statusText);
                    rj({ status: request.status, statusText: request.statusText });
                }
            }
        };

        request.onerror = function () {
            var error = new Error("Network Error!");
            if (failureCallback) failureCallback(error);
            rj(error);
        };

        request.open(method, url, shouldBeAsync);
        if (typeof props == 'string')
            request.responseType = props || '';
        else if (props && (typeof props == 'object')) {
            Object.assign(request, props);
        }
        headers = headers || {};
        headers["Content-Type"] = headers["Content-Type"] || "application/json;charset=UTF-8";
        Object.keys(headers).forEach(function (key) {
            request.setRequestHeader(key, headers[key]);
        });
        request.send(body);
    });
};

/* harmony default export */ __webpack_exports__["a"] = (XHR);

/***/ }),
/* 60 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
function CMDRunner(_this, commands) {
    this._this = _this;
    this.commands = {};
    this.assign(commands);
}



CMDRunner.prototype.has = function (cmdName) {
    return !!this.commands[cmdName];
};


CMDRunner.prototype.add = function (cmdName, handler) {
    this.commands[cmdName] = handler;
    return this;
};


CMDRunner.prototype.remove = function (cmdName) {
    delete this.commands[cmdName];
    return this;
};

CMDRunner.prototype.assign = function (obj) {
    for (var cmdName in obj) {
        if (typeof obj[cmdName] == 'function') {
            this.add(cmdName, obj[cmdName]);
        }
    }
};

CMDRunner.prototype.invoke = function () {
    if (this.commands[arguments[0]]) {
        var args = Array.prototype.slice.call(arguments, 1);
        return this.commands[arguments[0]].apply(this._this, args);
    }
    else {
        throw new Error('No command: ' + arguments[0]);
    }
};

/* harmony default export */ __webpack_exports__["a"] = (CMDRunner);



/***/ }),
/* 61 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_checkboxbutton_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(192);
/* harmony import */ var _css_checkboxbutton_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_checkboxbutton_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var _CheckBoxInput__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(41);




_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install('checkboxbutton', _CheckBoxInput__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"]);
/* harmony default export */ __webpack_exports__["a"] = (_CheckBoxInput__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"]);

/***/ }),
/* 62 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_snackbar_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(255);
/* harmony import */ var _css_snackbar_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_snackbar_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2);
/* harmony import */ var absol_src_HTML5_AElement__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(8);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1);






var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;

var t = document.createElement;

/***
 * @extends AElement
 * @constructor
 */
function SnackBar() {
    // OOP.drillProperty(this, this.firstChild, 'message', 'data');
    /***
     *
     * @type {*}
     */
    this._message = null;
    this.message = null;
}

SnackBar.tag = 'SnackBar'.toLowerCase();

SnackBar.render = function () {
    return _({
        class: 'as-snackbar'
    })
};

SnackBar.property = {};

SnackBar.property.message = {
    set: function (value) {
        this._message = value;
        if (value instanceof Array) {
            this.clearChild();
            this.addChild(value.map(function (item) {
                return _(item);
            }));
        }
        else if (typeof value === 'string') {
            this.innerHTML = value;
        }
        else if (Object(absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_4__[/* isDomNode */ "e"])(value)) {
            this.clearChild()
                .addChild(value);
        }
        else if (value && typeof value === 'object' &&
            (value.text
                || value.props || value.tag || value.attr
                || value.style || value.child
                || (value.child && value.child instanceof Array))) {
            this.clearChild()
                .addChild(_(value));
        }
        else {
            this.clearChild();
            this._message = null;
        }
    },
    get: function () {
        return this._message;
    }
}


_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(SnackBar);

SnackBar.$instance = _('snackbar');
SnackBar._removeTimeout = -1;

SnackBar.show = function (message) {
    if (SnackBar._removeTimeout > 0) {
        clearTimeout(SnackBar._removeTimeout);
    }
    if (!SnackBar.$instance.parentElement) document.body.appendChild(SnackBar.$instance);
    SnackBar.$instance.removeClass('as-hiding');
    SnackBar._removeTimeout = setTimeout(function () {
        SnackBar.$instance.addClass('as-show');
        SnackBar.$instance.message = message;
        SnackBar._removeTimeout = setTimeout(function () {
            SnackBar.$instance.removeClass('as-show').addClass('as-hiding');
            SnackBar._removeTimeout = setTimeout(function () {
                SnackBar.$instance.remove();
                SnackBar._removeTimeout = -1;
                SnackBar.$instance.removeClass('as-hiding');
            }, 500);
        }, 3000);
    }, 1);
}


/* harmony default export */ __webpack_exports__["a"] = (SnackBar);

/***/ }),
/* 63 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3);
/* harmony import */ var _HTML5_OOP__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2);



/***
 * @extends EventEmitter
 * @constructor
 */
function FlagManager() {
    _HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"].call(this);
    this.flag = {};
    this.readSetting();
}

_HTML5_OOP__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"].mixClass(FlagManager, _HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_0__[/* default */ "b"]);

FlagManager.prototype.STORE_KEY = "ABSOL_FLAG"

FlagManager.prototype.readSetting = function () {
    var flagText = localStorage.getItem(this.STORE_KEY) || '{}';
    var newFlag = {};
    try {
        newFlag = JSON.parse(flagText);
    } catch (err) {

    }
    this.applyFlag(newFlag);
};

FlagManager.prototype.applyFlag = function (newFlag, save) {
    var changed = [];
    Object.keys(Object.assign({}, this.flag, newFlag)).forEach(function (key) {
        if (key in window) {
            if (key in newFlag) {
                if (window[key] !== newFlag[key]) {
                    window[key] = newFlag[key];
                    changed.push(key);
                }
            }
            else {
                changed.push(key);
                delete window[key];
            }
        }
        else {
            if (key in newFlag) {
                if (window[key] !== newFlag[key]) {
                    window[key] = newFlag[key];
                    changed.push(key);
                }
            }
        }
    });
    this.flag = newFlag;
    if (save) this.saveSetting();
    if (changed.length > 0) {
        this.emit('change', { type: 'change', target: this, keys: changed })
    }
};

FlagManager.prototype.saveSetting = function () {
    localStorage.setItem(this.STORE_KEY, JSON.stringify(this.flag));
};

/***
 *
 * @param {string} key
 * @param {boolean=} value
 */
FlagManager.prototype.add = function (key, value) {
    if (!key || (typeof (key) != 'string')) return;
    if (key in this.flag) return;
    if (typeof (value) != "boolean") {
        value = !!window[key];
    }
    this.flag[key] = value;
    window[key] = value;
    this.saveSetting();
    this.emit('change', { type: 'change', target: this, keys: [key] });
};

FlagManager.prototype.set = function (key, value) {
    if (!key || (typeof (key) != 'string')) return;
    if (typeof (value) != "boolean") {
        value = !!window[key];
    }
    var changed = false;
    this.flag[key] = value;
    if (window[key] !== value) {
        changed = true;
    }
    this.saveSetting();
    if (changed) {
        this.emit('change', { type: 'change', target: this, keys: [key] });
    }
};

FlagManager.prototype.remove = function (key) {
    if (key in this.flag) {
        delete window[key];
        delete this.flag[key];
        this.emit('change', { type: 'change', target: this, keys: [key] });
    }
};

/* harmony default export */ __webpack_exports__["a"] = (new FlagManager());

/***/ }),
/* 64 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";

// UNUSED EXPORTS: publicCreators

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/autocompleteinput.css
var autocompleteinput = __webpack_require__(115);

// EXTERNAL MODULE: ./node_modules/absol-acomp/ACore.js
var ACore = __webpack_require__(0);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/OOP.js
var OOP = __webpack_require__(2);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/Dom.js + 1 modules
var Dom = __webpack_require__(1);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/adapter/SearchStringArrayAdapter.js
/**
 * @typedef {Object} SearchArrayAdapterOption
 * @property {function} searchFuntion
 * 
 * 
 * 
 * @param {Array<String>} arr 
 * @param {SearchArrayAdapterOption} options not implement yet
 */
function SearchStringArrayAdapter(texts, options) {
    if (!this.queryItems) return new SearchStringArrayAdapter(texts, options);
    
    this.texts = texts;
}

SearchStringArrayAdapter.prototype.queryItems = function (query, mInput) {
    var query = query.toLocaleLowerCase();
    return this.texts.map(function (text) {
        var start = text.toLocaleLowerCase().indexOf(query);
        if (start >= 0) {
            var hightlightedText = text.substr(0, start) + '<strong style="color:red">' + text.substr(start, query.length) + '</strong>' + text.substr(start + query.length);
            return {
                text: text,
                hightlightedText: hightlightedText
            }
        }
        else return null;
    }).filter(function (it) { return it !== null; })
};


SearchStringArrayAdapter.onAttached = function(parent){
    this.parent = parent;
};

SearchStringArrayAdapter.prototype.getItemText = function (item, mInput) {
    return item.text;
};

SearchStringArrayAdapter.prototype.getItemView = function (item, index, _, $, query, reuseItem, refParent, mInput) {
    if (reuseItem) {
        reuseItem.childNodes[0].innerHTML = item.hightlightedText;
        return reuseItem;
    }
    else
        return _({
            tag: 'div',
            child: {
                tag: 'span',
                class: 'absol-autocomplete-input-item-text',
                props: {
                    innerHTML: item.hightlightedText
                }
            }
        })
}

/* harmony default export */ var adapter_SearchStringArrayAdapter = (SearchStringArrayAdapter);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/adapter/SearchObjectArrayAdapter.js
/**
 * @typedef {Object} SearchObjectArrayAdapter
 * @property {function} getItemText
 * 
 * 
 * 
 * @param {Array<Object>} arr 
 * @param {SearchArrayAdapterOption} options
 */
function SearchObjectArrayAdapter(objects, options) {
    if (!this.queryItems) return new SearchObjectArrayAdapter(texts, options);
    this.objects = objects;
    this.options = options;
}

SearchObjectArrayAdapter.prototype.queryItems = function (query, mInput) {
    var query = query.toLocaleLowerCase();
    return this.objects.map(function (object) {
        var text = this.getItemText(object);
        var start = text.toLocaleLowerCase().indexOf(query);
        if (start >= 0) {
            var hightlightedText = text.substr(0, start) + '<strong style="color:red">' + text.substr(start, query.length) + '</strong>' + text.substr(start + query.length);
            return Object.assign(object, {
                __hightlightedText__: hightlightedText
            });
        }
        else return null;
    }.bind(this)).filter(function (it) { return it !== null; })
};


SearchObjectArrayAdapter.prototype.onAttached = function (parent) {
    this.parent = parent;
    parent.getSelectedObject = function () {
        if (this._selectedIndex >= 0) {
            return this.$poolItems[this._selectedIndex]._holderItem;
        }
        else {
            return null;
        }
    }
};

SearchObjectArrayAdapter.prototype.getItemText = function (item, mInput) {
    if (this.options && this.options.getItemText)
        return this.options.getItemText.call(this, item, mInput);
    else if (typeof item.text == 'string') {
        return item.text;
    }
    else
        return item.toString();
};

SearchObjectArrayAdapter.prototype.getItemView = function (item, index, _, $, query, reuseItem, refParent, mInput) {
    if (reuseItem) {
        reuseItem.childNodes[0].innerHTML = item.__hightlightedText__;
        return reuseItem;
    }
    else
        return _({
            tag: 'div',
            child: {
                tag: 'span',
                props: {
                    innerHTML: item.__hightlightedText__
                }
            }
        })
}

/* harmony default export */ var adapter_SearchObjectArrayAdapter = (SearchObjectArrayAdapter);
// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/EventEmitter.js
var EventEmitter = __webpack_require__(3);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/AutoCompleteInput.js









var _ = ACore["d" /* default */]._;
var $ = ACore["d" /* default */].$;

function AutoCompleteInput() {
    this.$input = $('input', this)
        .on('keyup', this.eventHandler.keyup)
        .on('keydown', this.eventHandler.keydown)
        .on('focus', this.eventHandler.focus)
        .on('blur', this.eventHandler.blur);


    this.$dropdown = $('.absol-autocomplete-input-dropdown', this);
    this.$vscroller = $('bscroller', this).on('click', this.eventHandler.vscrollerClick);
    this.$poolItems = [];
    this._currentData = [];
    this._sessionIndex = 0;
    this._updatedSession = -1;
    this._cache = {};
    OOP["a" /* default */].drillProperty(this, this.$input, 'value');

    return this;
}

AutoCompleteInput.tag = 'AutoCompleteInput';

AutoCompleteInput.render = function () {
    return _({
        extendEvent: 'change',
        class: 'absol-autocomplete-input',
        child: [
            'input[type="text"].absol-autocomplete-input-text',
            {
                class: 'absol-autocomplete-input-dropdown',
                style: {
                    display: 'none'
                },
                child: {
                    tag: 'bscroller',
                    style: {
                        'max-height': '500px'
                    }
                }
            }
        ]
    });
};


AutoCompleteInput.eventHandler = {};
AutoCompleteInput.eventHandler.keyup = function (event) {
    if (this._keyTimeout) {
        clearTimeout(this._keyTimeout);
        this._keyTimeout = 0;
    }

    var cTimeout = setTimeout(function () {
        clearTimeout(cTimeout);
        this.find();
    }.bind(this), 300);


    if (this._cacheTimeout) {
        clearTimeout(this._cacheTimeout);
        this._cacheTimeout = 0;
    }

    var cacheTimeout = setTimeout(function () {
        clearTimeout(cacheTimeout);
        this.clearCache();
    }.bind(this), 300);

    this._cacheTimeout = cacheTimeout;
    this._keyTimeout = cTimeout;
};


AutoCompleteInput.eventHandler.blur = function () {
    this.removeClass('focus');
};

AutoCompleteInput.eventHandler.focus = function () {
    this.addClass('focus');
    $(document.body).on('mousedown', this.eventHandler.clickOut);

    //todo
}

AutoCompleteInput.eventHandler.clickOut = function (event) {
    if (EventEmitter["b" /* default */].hitElement(this, event)) return;
    $(document.body).off('mousedown', this.eventHandler.clickOut);
    var text = this.$input.value;

    if (this._lastValue != text) {
        this._lastValue = text;
        this.$dropdown.addStyle('display', 'none');
        this._lastValue = text;
        this.emit('change', { target: this, value: text }, this);
    }

}


AutoCompleteInput.eventHandler.vscrollerClick = function (event) {
    var current = event.target;
    while (current && !current.containsClass('absol-autocomplete-input-item') && current != this.$vscroller) {
        current = current.parentElement;
    }

    if (current && current._holderItem) {
        var text = this.getItemText(current._holderItem);
        this.$input.value = text;
        this._lastQuery = text;
        this._selectedIndex = current._holderIndex;
        this.$dropdown.addStyle('display', 'none');
        this._lastValue = text;
        this.emit('change', { target: this, value: text }, this);
    }
};

AutoCompleteInput.eventHandler.keydown = function (event) {
    var key = event.key;
    if (key == 'ArrowDown') {
        if (this._selectedIndex + 1 < this._currentData.length) {
            if (this.$poolItems[this._selectedIndex]) {
                this.$poolItems[this._selectedIndex].removeClass('active');
            }
            this._selectedIndex += 1;
            if (this.$poolItems[this._selectedIndex]) {
                this.$poolItems[this._selectedIndex].addClass('active');
                this.$vscroller.scrollInto(this.$poolItems[this._selectedIndex]);
            }

        }
        event.preventDefault();
    }
    else if (key == 'ArrowUp') {
        if (this._selectedIndex - 1 >= 0) {
            if (this.$poolItems[this._selectedIndex]) {
                this.$poolItems[this._selectedIndex].removeClass('active');
            }
            this._selectedIndex -= 1;
            if (this.$poolItems[this._selectedIndex]) {
                this.$poolItems[this._selectedIndex].addClass('active');
                this.$vscroller.scrollInto(this.$poolItems[this._selectedIndex]);
            }

        }
        event.preventDefault();
    }
    else if (key == 'Enter') {
        var text;
        if (this._currentData[this._selectedIndex] === undefined) {
            text = this.$input.value;
        }
        else {
            text = this.getItemText(this._currentData[this._selectedIndex]);
            this.$input.value = text;
        }
        this._lastQuery = text;
        this.$dropdown.addStyle('display', 'none');
        this._lastValue = text;
        this.emit('change', { target: this, value: text }, this);
    }
};

AutoCompleteInput.prototype.focus = function () {
    if (this.disabled) return;
    this.$input.focus.apply(this.$input, arguments);

};

AutoCompleteInput.prototype.blur = function () {
    this.$input.blur.apply(this.$input, arguments);

};

AutoCompleteInput.prototype.select = function () {
    this.$input.select.apply(this.$input, arguments);
}

AutoCompleteInput.prototype.find = function () {
    var query = this.$input.value;
    if (query == this._lastQuery) return;
    this._lastQuery = query;
    var currentSession = ++this._sessionIndex;
    if (!query) {
        this.pushData([], currentSession, query)
        return;
    }
    if (this.disableCache) {
        var onReciveData = function (data) {
            cacheHolder.data = data;
            this.pushData(data, currentSession, query);//sessionIndex may be change
        }.bind(this);
        var result = this.queryItems(query);
        if (typeof result.then == 'function')
            result.then(onReciveData);
        else onReciveData(result)
    }
    else {
        if (this._cache[query]) {
            this._cache[query].sessionIndex = currentSession;
            if (!this._cache[query].pending) {
                var data = this._cache[query].data;
                this.pushData(data, currentSession);
            }
        }
        else {
            var cacheHolder = { pending: true, sessionIndex: currentSession };
            var onReciveData = function (data) {
                cacheHolder.data = data;
                cacheHolder.pending = false;
                this.pushData(data, cacheHolder.sessionIndex, query);//sessionIndex may be change
            }.bind(this);
            var result = this.queryItems(query);
            if (typeof result.then == 'function')
                result.then(onReciveData);
            else onReciveData(result)

            this._cache[query] = cacheHolder;
        }
    }
};

AutoCompleteInput.prototype.pushData = function (data, sessionIndex, query) {
    if (sessionIndex > this._updatedSession) {
        this._updatedSession = sessionIndex;
        this.$vscroller.clearChild();
        this._currentData = data;
        if (data && data.length > 0) {
            this.$dropdown.removeStyle('display');
        }
        else {
            this.$dropdown.addStyle('display', 'none');
        }

        var maxHeight = this.getComputedStyleValue('max-height');
        if (maxHeight == 'none' || !maxHeight) {
            maxHeight = 10000;
        }
        else {
            maxHeight = parseFloat(maxHeight.replace('px', ''));
        }

        var outBound = Dom["b" /* default */].traceOutBoundingClientRect(this);
        var bound = this.$input.getBoundingClientRect();
        var aTop = bound.top - outBound.top;
        var aBotom = outBound.bottom - bound.bottom;
        this.$dropdown.removeClass('top');
        if (aTop > aBotom) {
            maxHeight = Math.min(maxHeight, aTop - 10);
        }
        else {
            maxHeight = Math.min(maxHeight, aBotom - 10);
        }

        this.$vscroller.addStyle('max-height', maxHeight + 'px');
        this._selectedIndex = -1;
        data.reduce(function (sync, item, i, arr) {
            return sync.then(function () {
                if (this._updatedSession != sessionIndex) return;
                return new Promise(function (rs) {
                    if (this._updatedSession != sessionIndex) return;
                    var reuseItem = this.$poolItems.length > i ? this.$poolItems[i] : undefined;
                    if (reuseItem) {
                        reuseItem.removeClass('active');
                    }
                    var newView = this.getItemView(item, i, _, $, query, reuseItem, this);
                    newView.addClass('absol-autocomplete-input-item');
                    newView._holderItem = item;
                    newView._holderIndex = i;
                    if (i == this._selectedIndex)
                        newView.addClass('active');
                    if (this.$poolItems.length <= i) {
                        this.$poolItems.push(newView);
                    }
                    else {
                        this.$poolItems[i] = newView;
                    }
                    this.$vscroller.addChild(newView);
                    if (i == 0) {
                        var estimateHeight = newView.getBoundingClientRect().height * arr.length;
                        if (aTop > aBotom && estimateHeight > aBotom) {
                            this.$dropdown.addClass('top');
                        }
                    }
                    if (i >= 50 && i % 50 == 0)
                        setTimeout(rs, 0);
                    else rs();
                }.bind(this));
            }.bind(this))
        }.bind(this), Promise.resolve());
    }
};


AutoCompleteInput.prototype.getItemText = function (item) {
    if (this.adapter && this.adapter.getItemText) {
        return this.adapter.getItemText(item, this);
    }
    else if (typeof item == 'string') {
        return item;
    }
    else {
        throw Error('You need adapter.getItemText(item, mAutoCompleteInput) to handle your item text!');
    }

}

AutoCompleteInput.prototype.getItemView = function (item, index, _, $, query, reuseItem, refParent) {
    if (this.adapter && this.adapter.getItemView) {
        return this.adapter.getItemView(item, index, _, $, query, reuseItem, refParent, this);
    }
    else {
        var text = this.getItemText(item);
        if (reuseItem) {
            reuseItem.childNodes[0].innerHTML = text;
            return reuseItem;
        }

        return _({
            child: {
                tag: 'span',
                class: 'absol-autocomplete-input-item-text',
                child: { text: text }
            }
        });
    }
};


/**
 * @param {String} query
 * @returns {Array}
 */
AutoCompleteInput.prototype.queryItems = function (query) {
    if (this.adapter && this.adapter.queryItems) {
        return this.adapter.queryItems(query, this);
    }
    else {
        throw new Error('Invalid adapter: queryItems(query, mAutoCompleteInput) not found!');
    }
};


AutoCompleteInput.prototype.clearCache = function (old) {
    if (typeof old != "number") old = 30;
    for (var key in this._cache) {
        var cacheHolder = this._cache[key];
        if (this._sessionIndex - cacheHolder.sessionIndex > old) {
            delete this._cache[key];
        }
    }
}

AutoCompleteInput.property = {};
AutoCompleteInput.property.adapter = {
    set: function (value) {
        if (value instanceof Array) {
            if (value[0] == 'SearchStringArray') {
                this._adapter = new adapter_SearchStringArrayAdapter(value[1], value[2]);
            }
            else if (value[0] == 'SearchObjectArray') {
                this._adapter = new adapter_SearchObjectArrayAdapter(value[1], value[2]);
            }
            else {
                throw new Error("Unknown adapter type name");
            }
        }
        else {
            this._adapter = value;
        }
        if (this.adapter && this.adapter.onAttached) {
            this.adapter.onAttached(this);
        }
    },
    get: function () {
        return this._adapter;
    }
};

AutoCompleteInput.property.disabled = {
    set: function (value) {
        if (value) {
            this.addClass('absol-disabled');
        }
        else {
            this.removeClass('absol-disabled');
        }
    },
    get: function () {
        return this.containsClass('absol-disabled');
    }
};

AutoCompleteInput.attribute = {};
AutoCompleteInput.attribute.disabled = {
    set: function (value) {
        if (value === true || value === 'true' || value === null) {
            this.disabled = true;
        }
        else {
            this.disabled = false;
        }
    },
    get: function () {
        return this.disabled ? 'true' : 'false'
    },
    remove: function () {
        this.disabled = false;
    }
};


ACore["d" /* default */].install('AutoCompleteInput'.toLowerCase(), AutoCompleteInput);


/* harmony default export */ var js_AutoCompleteInput = (AutoCompleteInput);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/BoardTable.js
var BoardTable = __webpack_require__(71);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Board.js
var Board = __webpack_require__(85);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/bscroller.css
var bscroller = __webpack_require__(122);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/Element.js
var Element = __webpack_require__(24);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/BScroller.js





var BScroller_ = ACore["d" /* default */]._;
var BScroller_$ = ACore["d" /* default */].$;



/***
 * @extends AElement
 * @constructor
 */
function BScroller() {
    this.addClass('as-bscroller');
}


BScroller.tag = "bscroller";

BScroller.render = function (data) {
    if (data && data.elt) {
        return BScroller_$(data.elt)
    }
    else
        return BScroller_('div');
};

BScroller.prototype.scrollInto = function (element) {
    if (Element["a" /* default */].prototype.isDescendantOf.call(element, this)) {
        var elementBound = element.getBoundingClientRect();
        var viewportBound = this.getBoundingClientRect();
        var currentScrollTop = this.scrollTop;
        var newScrollTop = currentScrollTop;
        if (elementBound.bottom > viewportBound.bottom) {
            newScrollTop = currentScrollTop + (elementBound.bottom - viewportBound.bottom);
        }
        if (elementBound.top < viewportBound.top) {
            newScrollTop = currentScrollTop - (viewportBound.top - elementBound.top);
        }

        if (newScrollTop != currentScrollTop) {
            this.scrollTop = newScrollTop;
        }

        var currentScrollLeft = this.scrollLeft;
        var newScrollLeft = currentScrollLeft;
        if (elementBound.right > viewportBound.right) {
            newScrollLeft = currentScrollLeft + (elementBound.right - viewportBound.right);
        }
        if (elementBound.left < viewportBound.left) {
            newScrollLeft = currentScrollLeft - (viewportBound.left - elementBound.left);
        }

        if (newScrollLeft != currentScrollLeft) {
            this.scrollLeft = newScrollLeft;
        }
    }
}


ACore["d" /* default */].install(BScroller);

/* harmony default export */ var js_BScroller = (BScroller);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/buttonarray.css
var buttonarray = __webpack_require__(124);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/AElement.js
var AElement = __webpack_require__(8);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/ButtonArray.js




var ButtonArray_ = ACore["d" /* default */]._;
var ButtonArray_$ = ACore["d" /* default */].$;


/***
 * @extends AElement
 * @constructor
 */
function ButtonArray() {
    this._dict = {};
    this._pool = [];
    this._items = [];
    this.$lastActiveBtn = null;
    this._value = undefined;
    this._lastValue = this._value;
}

ButtonArray.tag = 'buttonarray';
ButtonArray.render = function () {
    return ButtonArray_({
        extendEvent: ['change'],
        class: 'as-button-array'
    });
};

ButtonArray.prototype._newButton = function () {
    var button = ButtonArray_({
        tag: 'button',
        class: 'as-button-array-item',
        child: { text: 'null' }
    });
    button.on('click', this.eventHandler.clickItem.bind(this, button));
    return button;
};

ButtonArray.prototype._requestButton = function (items) {
    var button;
    if (this._pool.length > 0) {
        button = this._pool.pop();
    }
    else {
        button = this._newButton();
    }
    return button;
};

ButtonArray.prototype._assignButton = function (button, data) {
    button._data = data;
    button.childNodes[0].data = data.text;
};

ButtonArray.prototype._releaseButton = function (button) {
    this._pool.push(button);
};

ButtonArray.prototype._getFullFormat = function (item) {
    var res = {};
    if ((typeof item == 'string') || (typeof item == 'number') || (typeof item == 'boolean') || (item === null) || (item === undefined)) {
        res.ident = item;
        res.value = item;
        res.text = item + '';
    }
    else if (item && (typeof item == 'object')) {
        res.value = item.value;
        res.ident = res.value + '';
        res.text = item.text;
    }
    return res;
};


ButtonArray.property = {};

/**
 * @type {ButtonArray}
 */
ButtonArray.property.items = {
    set: function (items) {
        items = items || [];
        this._items = items;
        var child;
        while (this.childNodes.length > items.length) {
            child = this.lastChild;
            this._releaseButton(child);
            this.removeChild(child);
        }

        while (this.childNodes.length < items.length) {
            this.addChild(this._requestButton());
        }
        var item;
        for (var i = 0; i < items.length; ++i) {
            item = this._getFullFormat(items[i]);
            this._assignButton(this.childNodes[i], item);
            this._dict[item.ident] = {
                elt: this.childNodes[i],
                data: item
            }
        }
        if (items.length > 0) {
            if (!this._dict[this._value + '']) {
                this._value = this._getFullFormat(items[0]).value;
            }
        }
        this.value = this._value;
    },
    get: function () {
        return this._items;
    }
};

ButtonArray.property.value = {
    set: function (value) {
        this._value = value;
        this._lastValue = this._value;
        if (this.$lastActiveBtn) {
            this.$lastActiveBtn.removeClass('as-active');
            this.$lastActiveBtn = null;
        }
        var hodler = this._dict[value + ''];
        if (hodler) {
            hodler.elt.addClass('as-active');
            this.$lastActiveBtn = hodler.elt;
        }
    },
    get: function () {
        return this._value;
    }
};


ButtonArray.eventHandler = {};

ButtonArray.eventHandler.clickItem = function (item, event) {
    if (this._lastValue != item._data.value) {
        this.value = item._data.value;
        this.emit('change', { target: this, value: this.value, type: 'change' }, this);
    }
};


ACore["d" /* default */].install(ButtonArray);

/* harmony default export */ var js_ButtonArray = (ButtonArray);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/calendarinput.css
var calendarinput = __webpack_require__(126);

// EXTERNAL MODULE: ./node_modules/absol/src/Time/datetime.js
var datetime = __webpack_require__(5);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/ChromeCalendar.js
var ChromeCalendar = __webpack_require__(32);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/CalendarInput.js







var CalendarInput_ = ACore["d" /* default */]._;
var CalendarInput_$ = ACore["d" /* default */].$;



/**
 * @extends AElement
 * @constructor
 */
function CalendarInput() {
    var thisCI = this;
    this.$input = CalendarInput_$('input', this);
    this._value = null;

    this._quickOption = ChromeCalendar["a" /* default */].showWhenClick(this, {
        minLimitDate: this.minLimitDate || this.minDateLimit,
        maxLimitDate: this.maxLimitDate || this.maxDateLimit,
        selectedDates: [new Date()]
    }, 'auto', function (value) {
        thisCI._value = value;
        thisCI.$input.value = thisCI.formatDateString(value);
        thisCI._quickOption.calendarProps.selectedDates = [value];//change new option
        thisCI.emit('change', { target: thisCI, value: value }, thisCI);
    });

    OOP["a" /* default */].drillProperty(this, this._quickOption.calendarProps, {
        minLimitDate: 'minLimitDate',
        maxLimitDate: 'maxLimitDate',
        minDateLimit: 'minLimitDate',
        maxDateLimit: 'maxLimitDate'
    });

}

CalendarInput.tag = 'CalendarInput'.toLowerCase();

CalendarInput.render = function () {
    return CalendarInput_({
        extendEvent: ['change'],
        class: 'absol-calendar-input',
        child: 'input[type="text"][readonly="true"][value="dd/mm/yyyy"]'
    });
};

CalendarInput.property = {};

CalendarInput.property.value = {
    set: function (value) {
        if (value === null || value === undefined) {
            this.$input.value = this.formatDateString(value);
            this._quickOption.calendarProps.selectedDates = [];
            this._value = value;
            this._quickOption.calendarProps.selectedDates = [new Date()]
        }
        else {
            if (typeof value == 'number') value = new Date(value);
            this._value = value;
            this.$input.value = this.formatDateString(value);
            this._quickOption.calendarProps.selectedDates = [value];
        }
    },
    get: function () {
        return this._value;
    }
};


CalendarInput.property.disabled = {
    set: function (value) {
        this.$input.disabled = !!value;
        if (value) {
            this.addClass('absol-disabled');
        }
        else {
            this.removeClass('absol-disabled');
        }
    },
    get: function () {
        return this.$input.disabled;
    }
};

CalendarInput.attribute = {
    disabled: {
        set: function (value) {
            this.$input.attr('disabled', value);
            if (this.$input.disabled)
                this.addClass('absol-disabled');
        },
        get: function () {
            return this.$input.attr('disabled');
        },
        remove: function () {
            this.$input.attr('disabled', undefined);
            this.removeClass('absol-disabled');
        }
    }
};


CalendarInput.property.dateToString = {
    set: function (value) {
        this._dateToString = value;
        this.$input.value = this.formatDateString(this.value);
    },
    get: function () {
        return this._dateToString;
    }
};

CalendarInput.prototype.formatDateString = function (date) {
    if (!date) {
        return {
            'undefined': 'dd/mm/yyyy',
            'function': '--/--/--',
            'object': 'dd/mm/yyyy',
            'string': typeof this.dateToString
        }[typeof this.dateToString] || '--/--/--';
    }
    if (!this.dateToString) {
        return Object(datetime["formatDateString"])(date);
    }
    else if (typeof this.dateToString == 'string') {
        return Object(datetime["formatDateString"])(date, this.dateToString);
    }
    else if (typeof this.dateToString == 'function') {
        return this.dateToString(date);
    }
};

ACore["d" /* default */].install(CalendarInput);

function OldCalendarInput(){

}

OldCalendarInput.tag = 'calendar-input';

OldCalendarInput.render = function(data){
    return CalendarInput_({
        tag: 'calendarinput',
        extendEvent: 'changed',
        props: data,
        on: {
            change: function (ev) {
                this.emit('changed', ev.value);
            }
        }
    });
};

ACore["d" /* default */].install(OldCalendarInput);

/* harmony default export */ var js_CalendarInput = (CalendarInput);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/CheckBoxInput.js
var CheckBoxInput = __webpack_require__(41);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/checkbox.css
var css_checkbox = __webpack_require__(134);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/CheckBox.js







var CheckBox_ = ACore["d" /* default */]._;
var CheckBox_$ = ACore["d" /* default */].$;
var $$ = ACore["d" /* default */].$$;


/***
 * @extends AElement
 * @constructor
 */
function CheckBox() {
    this.defineEvent('change');
    /***
     *
     * @type {CheckboxInput}
     */
    this.$input = CheckBox_$('checkboxinput', this).on('change',
        this.notifyChange.bind(this)
    );
    this.$labels = $$('span', this);
    this.on('click', this.eventHandler.click);
    OOP["a" /* default */].drillProperty(this, this.$input, ['checked'])
}

CheckBox.tag = 'checkbox';

CheckBox.render = function () {
    return CheckBox_({
        class: ['absol-checkbox','as-no-label'],
        child: [
            {
                tag: 'span',
                class: ['absol-checkbox-label', 'as-left'],
                child: { text: '' }
            },
            'checkboxinput',
            {
                tag: 'span',
                class: ['absol-checkbox-label', 'as-right'],
                child: { text: '' }
            }
        ]
    });
};


CheckBox.prototype.notifyChange = function () {
    this.emit('change', { type: 'change', checked: this.checked, target: this }, this);
};
//v, labelText, checked

CheckBox.attribute = {
    checked: {
        set: function (value) {
            if (value === 'false' || value == null) {
                this.checked = false;
            }
            else {
                this.checked = true;
            }

        },
        get: function () {
            return this.checked ? 'true' : 'false'
        },
        remove: function () {
            this.checked = false;
        }
    },
    disabled: {
        set: function (value) {
            if (value === 'false' || value === null) {
                this.disabled = false;
            }
            else {
                this.disabled = true;
            }

        },
        get: function () {
            return this.disabled ? 'true' : 'false'
        },
        remove: function () {
            this.disabled = false;
        }
    }
};


CheckBox.property = {};
CheckBox.property.text = {
    get: function () {
        return  this._text;
    },
    set: function (value) {
        value = value || '';
        if (value.length === 0){
            this.addClass('as-no-label');
        }
        else{
            this.removeClass('as-no-label');
        }
        this._text = value;
        this.$labels[0].firstChild.data = value;
        this.$labels[1].firstChild.data = value;
    }
};


CheckBox.property.disabled = {
    get: function (){
        return    this.$input.disabled;
    },
    set: function (value){
        value = !!value;
        this.$input.disabled = value;
        if (value){
            this.addClass('as-disabled');
        }
        else {
            this.removeClass('as-disabled');
        }
    }
};



/***
 *
 * @type {{}|CheckBox}
 */
CheckBox.eventHandler = {};

CheckBox.eventHandler.click = function (event){
    if (!EventEmitter["b" /* default */].hitElement(this.$input, event)){
        this.$input.click();
    }
};

ACore["d" /* default */].install(CheckBox);
/* harmony default export */ var js_CheckBox = (CheckBox);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/circlesectionlabel.css
var circlesectionlabel = __webpack_require__(136);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/Svg.js
var Svg = __webpack_require__(16);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/CircleSectionLabel.js






var CircleSectionLabel_ = ACore["d" /* default */]._;
var CircleSectionLabel_$ = ACore["d" /* default */].$;

var _g = Svg["a" /* default */].ShareInstance._;
var $g = Svg["a" /* default */].ShareInstance.$;


var Design = {
    circleHeight: 218 - 36,
    borderWidth: 36,
    textBoxHeight: 146,
    textHeight: 48,
    indexHeight: 54,
    textBoxPaddingLeft: 80,
    indexArrowRadius: (172 - 18) / 2,
    indexArrowStrokeWidth: 18,
    indexArrowStartAngle: -Math.PI / 6,
    indexArrowEndAngle: -7 * Math.PI / 12
};

var StyleSheet = {
    '.as-circle-section-label-text': {
        height: Design.textBoxHeight / Design.textHeight + 'em',
        'padding-left': Design.textBoxPaddingLeft / Design.textHeight + 'em',
        'line-height': Design.textBoxHeight / Design.textHeight + 'em'
    },
    '.as-circle-section-label-index': {
        'font-size': Design.indexHeight / Design.textHeight + 'em',
        height: (Design.circleHeight + Design.borderWidth) / Design.indexHeight + 'em',
        'line-height': (Design.circleHeight + Design.borderWidth) / Design.indexHeight + 'em',
        width: (Design.circleHeight + Design.borderWidth) / Design.indexHeight + 'em'
    },

};

CircleSectionLabel_({
    tag: 'style',
    id: 'circle-section-label-style',
    props: {
        innerHTML: Object.keys(StyleSheet).map(function (key) {
            var style = StyleSheet[key];
            return key + ' {\n'
                + Object.keys(style).map(function (propName) {
                    return propName + ': ' + style[propName] + ';';
                }).join('\n')
                + '}';
        }).join('\n')
    }
}).addTo(document.head);


/**
 * @extends AElement
 * @constructor
 */
function CircleSectionLabel() {
    this._ident = (Math.random() + '').replace(/[^0-9]/g, '_');
    this.$background = CircleSectionLabel_$('.as-circle-section-label-background', this);
    this.$index = CircleSectionLabel_$('.as-circle-section-label-index', this);
    this.$text = CircleSectionLabel_$('.as-circle-section-label-text', this);
    this.$attachhook = CircleSectionLabel_('attachhook').addTo(this).on('error', function () {
        Dom["b" /* default */].addToResizeSystem(this);
        this.requestUpdateSize();
    });

    this.$attachhook.requestUpdateSize = this.redrawBackground.bind(this);
    this.$svg = _g({
        tag: 'svg',
        attr: {
            width: '0',
            height: '0'
        },
        child: [
            {
                tag: 'defs',
                child: [
                    {
                        tag: 'marker',
                        id: 'marker_' + this._ident,
                        attr: {
                            markerWidth: "4",
                            markerHeight: "4",
                            refX: "0",
                            refY: "1",
                            orient: "auto",
                            markerUnits: "strokeWidth",
                            viewBox: "0 0 4 4"
                        },
                        child: {
                            tag: 'path',
                            class: 'as-circle-section-label-arrow-marker-path',
                            attr: {
                                d: 'M0,0 L0,2 L2,1 z'
                            }
                        }
                    }
                ]
            },
            'rect.as-circle-section-label-text-box',
            'circle.as-circle-section-label-index-box',
            'path.as-circle-section-label-arrow'
        ]
    }).addTo(this.$background);
    this.$indexBox = $g('circle.as-circle-section-label-index-box', this.$svg);
    this.$textBox = $g('rect.as-circle-section-label-text-box', this.$svg);
    // this.$marker = $g('defs marker', this.$svg);
    // this.$markerPath = $g(' path', this.$marker);
    this.$arrow = $g('path.as-circle-section-label-arrow', this.$svg)
        .attr({
            'marker-end': "url(" + '#marker_' + this._ident + ")"
        });
};

CircleSectionLabel.prototype.redrawBackground = function () {
    var indexBound = this.$index.getBoundingClientRect();
    var textBound = this.$text.getBoundingClientRect();
    var cHeight = indexBound.height;
    var cWidth = textBound.right - indexBound.left;
    this.$svg.attr({
        height: cHeight + '',
        width: cWidth + '',
        viewBox: [0, 0, cWidth, cHeight].join(' ')
    });

    var borderWidth = cHeight * Design.borderWidth / (Design.circleHeight + Design.borderWidth);
    var radius = cHeight * Design.circleHeight / (Design.circleHeight + Design.borderWidth) / 2;
    var x0 = indexBound.width / 2;
    var y0 = cHeight / 2;


    this.$indexBox.attr({
        r: radius + '',
        cx: x0,
        cy: y0
    })
        .addStyle({
            strokeWidth: borderWidth + ''
        });
    var textBoxHeight = textBound.height;
    this.$textBox.attr(
        {
            x: x0 / 2,
            y: (cHeight - textBoxHeight) / 2,
            width: cWidth - x0 - 1,
            height: textBoxHeight,
            rx: textBoxHeight / 2,
            ry: textBoxHeight / 2
        }
    );
    var arrowRadius = cHeight * Design.indexArrowRadius / (Design.circleHeight + Design.borderWidth);
    this.$arrow.attr({
        d: [
            'M', x0 + arrowRadius * Math.cos(Design.indexArrowStartAngle), y0 + arrowRadius * Math.sin(Design.indexArrowStartAngle),
            'A', arrowRadius, arrowRadius, 0, 1, 1, x0 + arrowRadius * Math.cos(Design.indexArrowEndAngle), y0 + arrowRadius * Math.sin(Design.indexArrowEndAngle)
        ].join(' ')
    }).addStyle('stroke-width', cHeight * Design.indexArrowStrokeWidth / (Design.circleHeight + Design.borderWidth))
};

CircleSectionLabel.tag = 'CircleSectionLabel'.toLowerCase();
CircleSectionLabel.render = function () {
    return CircleSectionLabel_({
        class: 'as-circle-section-label',
        child: [
            {
                class: 'as-circle-section-label-background'
            },
            '.as-circle-section-label-index',
            '.as-circle-section-label-text'
        ]
    });
};

CircleSectionLabel.property = {};
CircleSectionLabel.property.index = {
    set: function (value) {
        this._index = value;
        this.$index.clearChild().addChild(CircleSectionLabel_({ text: value + '' }))
    },
    get: function () {
        return this._index;
    }
};

CircleSectionLabel.property.text = {
    set: function (value) {
        this._text = value;
        this.$text.clearChild().addChild(CircleSectionLabel_({ text: value + '' }))
    },
    get: function () {
        return this._text;
    }
}


ACore["d" /* default */].install(CircleSectionLabel);
/* harmony default export */ var js_CircleSectionLabel = (CircleSectionLabel);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Scroller.js
var Scroller = __webpack_require__(53);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/ContextMenu.js
var ContextMenu = __webpack_require__(43);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Menu.js
var Menu = __webpack_require__(40);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/dateinput.css
var dateinput = __webpack_require__(89);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/DateInput.js








var DateInput_ = ACore["d" /* default */]._;
var DateInput_$ = ACore["d" /* default */].$;

/**
 * @extends AElement
 * @constructor
 */
function DateInput() {
    this._lastValue = null;
    this._value = null;
    this._format = 'dd/mm/yyyy';
    this.$input = DateInput_$('input', this)
        .on('mouseup', this.eventHandler.mouseup)
        .on('keydown', this.eventHandler.keydown)
        .on('paste', this.eventHandler.paste)
        .on('cut', this.eventHandler.cut)
        .on('focus', this.eventHandler.focus);
    this._minLimitDate = new Date(1890, 0, 1, 0, 0, 0, 0);
    this._maxLimitDate = new Date(2090, 0, 1, 0, 0, 0, 0);
    this.$calendarBtn = DateInput_$('.as-date-input-icon-ctn', this)
        .on('mousedown', this.eventHandler.mousedownCalendarBtn);
    this._calendarHolder = ChromeCalendar["a" /* default */].showWhenClick(this.$calendarBtn, {
        minLimitDate: this._minLimitDate,
        maxLimitDate: this._maxLimitDate,
        selectedDates: [new Date()],
    }, 'auto', this.eventHandler.calendarSelect);
    this._calendarHolder.element = this;
    this._formater = DateInput.formaters[this._format];
    OOP["a" /* default */].drillProperty(this, this._calendarHolder.calendarProps, ['minLimitDate', 'maxLimitDate']);
    this.value = null;
}

DateInput.formaters = {
    'dd/mm/yyyy': {
        separator: '/',
        nan: ['dd', 'mm', 'yyyy'],
        dayIdx: 0,
        monthIdx: 1,
        yearIdx: 2
    },
    'dd-mm-yyyy': {
        separator: '-',
        nan: ['dd', 'mm', 'yyyy'],
        dayIdx: 0,
        monthIdx: 1,
        yearIdx: 2
    },
    'dd.mm.yyyy': {
        separator: '.',
        nan: ['dd', 'mm', 'yyyy'],
        dayIdx: 0,
        monthIdx: 1,
        yearIdx: 2
    },
    'yyyy/mm/dd': {
        separator: '/',
        nan: ['yyyy', 'mm', 'dd'],
        dayIdx: 2,
        monthIdx: 1,
        yearIdx: 0
    },
    'yyyy-mm-dd': {
        separator: '-',
        nan: ['yyyy', 'mm', 'dd'],
        dayIdx: 2,
        monthIdx: 1,
        yearIdx: 0
    },
    'mm/dd/yyyy': {
        separator: '/',
        nan: ['mm', 'dd', 'yyyy'],
        dayIdx: 1,
        monthIdx: 0,
        yearIdx: 2
    },
};


DateInput.tag = 'dateinput';

DateInput.render = function () {
    //only support dd/mm/yyyy
    return DateInput_({
        class: 'as-date-input',
        extendEvent: ['change'],
        child: [{
            tag: 'input',
            props: {
                value: '__/__/____'
            }
        },
            {
                tag:'button',
                class: 'as-date-input-icon-ctn',
                child: 'span.mdi.mdi-calendar'
            }
        ]
    });
};

DateInput.prototype._autoSelect = function () {
    var slEnd = this.$input.selectionEnd;
    var slStart = this.$input.selectionStart;
    var texts = this.$input.value.split(this._formater.separator);
    var lTexts = texts.reduce(function (ac, cr) {
        ac.push(ac[ac.length - 1] + cr.length + 1);
        return ac;
    }, [0]);

    function indexOf(offset) {
        var l;
        for (var i = 0; i < lTexts.length; ++i) {
            l = lTexts[i];
            if (l > offset) return i;
        }
        return texts.length;
    }

    var i0 = indexOf(slStart);
    var i1 = indexOf(slEnd);

    if (i0 == i1) {
        this.$input.selectionStart = lTexts[i0 - 1];
        this.$input.selectionEnd = lTexts[i0] - 1;
    }
    else {
        this.$input.selectionStart = 0;
        this.$input.selectionEnd = lTexts[lTexts.length - 1];
    }
};

DateInput.prototype.notifyChange = function () {
    this.emit('change', { type: 'change', target: this, value: this._value }, this);
}

DateInput.prototype._countSeparator = function (text) {
    return text.replace(new RegExp('[^\\' + this._formater.separator + ']', 'g'), '').length
};

DateInput.prototype._cleanCharacter = function (text) {
    return text.replace(new RegExp('[^0-9\\' + this._formater.separator + ']', 'g'), '');
};

DateInput.prototype._splitBySeparator = function (text) {
    return text.split(this._formater.separator);
};

DateInput.prototype._onlySeparator = function (text) {
    return text.replace(new RegExp('[^\\' + this._formater.separator + ']', 'g'), '')
};

DateInput.prototype._isAcceptKey = function (key) {
    return !!key.match(new RegExp('[0-9\\' + this._formater.separator + ']', 'i'));
};

/**
 * @type {DateInput}
 */
DateInput.eventHandler = {};

DateInput.eventHandler.paste = function (event) {
    var paste = (event.clipboardData || window.clipboardData).getData('text');
    event.preventDefault();
    paste = this._cleanCharacter(paste);
    var slEnd = this.$input.selectionEnd;
    var slStart = this.$input.selectionStart;
    var sStart = Math.min(slStart, slEnd);
    var sEnd = Math.max(slEnd, slStart);
    var value = this.$input.value;
    var slashPasteCount = this._countSeparator(paste)
    var slashSelectedCount = this._countSeparator(value.substr(sStart, sEnd - sStart));

    if (slashPasteCount < 2) {
        if (slashPasteCount > slashSelectedCount) {
            paste = this._splitBySeparator(paste).slice(0, slashSelectedCount + 1).join(this._formater.separator);
        }
        else if (slashPasteCount < slashSelectedCount) {
            paste += this._formater.separator.repeat(slashSelectedCount - slashPasteCount);
        }
        slStart = (value.substr(0, sStart) + paste).length;
        slEnd = slStart;
        value = value.substr(0, sStart) + paste + value.substr(sEnd);
    }
    else {
        value = this._splitBySeparator(paste).slice(0, 3).join(this._formater.separator);
        slStart = value.length;
        slEnd = value.length;
    }
    this.$input.value = value;
    this.$input.selectionStart = slStart;
    this.$input.selectionEnd = slEnd;
};

DateInput.eventHandler.cut = function (event) {
    event.preventDefault();
    var slEnd = this.$input.selectionEnd;
    var slStart = this.$input.selectionStart;
    var sStart = Math.min(slStart, slEnd);
    var sEnd = Math.max(slEnd, slStart);
    var value = this.$input.value;
    this.$input.value = value.substr(0, sStart) + this._onlySeparator(value.substr(sStart, sEnd - sStart)) + value.substr(sEnd);
    this.$input.selectionStart = slStart;
    this.$input.selectionEnd = slStart;
};

DateInput.eventHandler.mouseup = function () {
    setTimeout(this._autoSelect.bind(this), 1);
};

DateInput.eventHandler.focus = function () {
    this.$input.on('blur', this.eventHandler.blur);
};

DateInput.eventHandler.blur = function () {
    var thisIp = this;
    this.$input.off('blur', this.eventHandler.blur);
    var value = this.$input.value;
    var slashValueCount = this._countSeparator(value).length;
    for (var i = slashValueCount; i < 2; ++i) value += this._formater.separator;
    var texts = value.split(this._formater.separator).slice(0, 3);
    var day = parseInt(texts[this._formater.dayIdx]);
    var month = parseInt(texts[this._formater.monthIdx]);
    var year = parseInt(texts[this._formater.yearIdx]);
    if (!isNaN(year)) year = Math.min(2090, Math.max(year, 1890));
    if (!isNaN(month)) month = Math.max(1, Math.min(12, month));
    if (!isNaN(day)) {
        day = Math.max(1, Math.min(31, day));
        if (!isNaN(month)) {
            day = Math.min(Object(datetime["daysInMonth"])(2000, month), day);
            if (!isNaN(year)) day = Math.min(Object(datetime["daysInMonth"])(year, month), day);
        }
    }
    if (!isNaN(year) && !isNaN(month) && !isNaN(day)) {
        var dateValue = new Date(year, month - 1, day, 0, 0, 0, 0);
        if (this._lastValue == null || Object(datetime["compareDate"])(dateValue, this._lastValue) != 0) {
            this.value = dateValue;
            this.notifyChange();
        }
    }
    else {
        var values = this._formater.nan.slice();
        values[this._formater.dayIdx] = day;
        values[this._formater.monthIdx] = month;
        values[this._formater.yearIdx] = year;

        this.$input.value = values.map(function (e, i) {
            if (isNaN(e)) return thisIp._formater.nan[i];
            e = e + '';
            while (e.length < thisIp._formater.nan[i].length) e = '0' + e;
            return e;
        }).join(this._formater.separator);
        if (this._lastValue != null) {
            this._value = null;
            this.notifyChange();
        }
    }
};


DateInput.eventHandler.calendarSelect = function (value) {
    this.value = value;
    this.notifyChange();
};

DateInput.eventHandler.keydown = function (event) {
    var slEnd = this.$input.selectionEnd;
    var slStart = this.$input.selectionStart;
    var value = this.$input.value;
    var sStart = Math.min(slStart, slEnd);
    var sEnd = Math.max(slEnd, slStart);
    var selectedValue = value.substr(sStart, sEnd - sStart);
    var slashValueCount = this._countSeparator(value);
    var slashSelectedCount = this._countSeparator(selectedValue);

    var texts = this._splitBySeparator(value);
    var lTexts = texts.reduce(function (ac, cr) {
        ac.push(ac[ac.length - 1] + cr.length + 1);
        return ac;
    }, [0]);

    function indexOf(offset) {
        var l;
        for (var i = 0; i < lTexts.length; ++i) {
            l = lTexts[i];
            if (l > offset) return i;
        }
        return texts.length;
    }

    var i0 = indexOf(slStart);
    var i1 = indexOf(slEnd);
    if (event.key == 'Enter') {
        event.preventDefault();
        this.$input.blur();
    }
    else if (event.key == 'Meta') {
        event.preventDefault();
    }
    else if (event.key == 'Backspace') {
        if (slStart == slEnd) {
            if (slStart > 0) {
                if (value.charAt(slStart - 1) == this._formater.separator) {
                    event.preventDefault();
                    this.$input.value = value;
                    this.$input.selectionStart = slStart - 1;
                    this.$input.selectionEnd = slStart - 1;
                }
            }
        }
        else if (i0 != i1) {
            event.preventDefault();
            this.$input.value = value.substr(0, sStart) + this._onlySeparator(selectedValue) + value.substr(sEnd);
            this.$input.selectionStart = slStart;
            this.$input.selectionEnd = slStart;
        }
    }
    else if (event.key == 'Delete') {
        if (slStart == slEnd) {
            if (slStart < value.length) {
                if (value.charAt(slStart) == this._formater.separator) {
                    event.preventDefault();
                    this.$input.value = value;
                    this.$input.selectionStart = slStart + 1;
                    this.$input.selectionEnd = slStart + 1;
                }
            }
        }
        else if (i0 != i1) {
            event.preventDefault();
            this.$input.value = value.substr(0, sStart) + this._onlySeparator(selectedValue) + value.substr(sEnd);
            this.$input.selectionStart = slStart;
            this.$input.selectionEnd = slStart;
        }
    }
    else if (!event.ctrlKey && !event.altKey && event.key && event.key.length == 1) {
        if (this._isAcceptKey(event.key)) {
            if (event.key == this._formater.separator) {
                if (slashSelectedCount == 0 && slashValueCount >= 2 && value.charAt(slEnd) != this._formater.separator) {
                    event.preventDefault();
                }
                else if (value.charAt(slEnd) == this._formater.separator) {
                    event.preventDefault();
                    this.$input.selectionStart = lTexts[i1];
                    this.$input.selectionEnd = lTexts[i1 + 1] - 1;
                }
            }
        }
        else {
            event.preventDefault();
        }
    }
    else if (!event.ctrlKey && !event.altKey && event.key == "Tab") {
        if (event.shiftKey) {
            if (i0 > 1) {
                event.preventDefault();
                this.$input.selectionStart = lTexts[i1 - 2];
                this.$input.selectionEnd = lTexts[i1 - 1] - 1;
            }
        }
        else {
            if (i1 < texts.length) {
                event.preventDefault();
                this.$input.selectionStart = lTexts[i1];
                this.$input.selectionEnd = lTexts[i1 + 1] - 1;
            }
        }
    }
};


DateInput.property = {};

DateInput.property.value = {
    set: function (value) {
        if (value === false || value === null || value === undefined) {
            this.$input.value = this._format;
            this._value = null;
        }
        else if ((typeof value == 'string') || (typeof value == 'number')) {
            this._value = Object(datetime["beginOfDay"])(new Date(value));
            this.$input.value = Object(datetime["formatDateString"])(this._value, this._format);
        }
        else if (value.getTime) {
            this._value = Object(datetime["beginOfDay"])(value);
            this.$input.value = Object(datetime["formatDateString"])(this._value, this._format);
        }
        this._lastValue = this._value;
        this._calendarHolder.calendarProps.selectedDates = [this._value || new Date()];
    },
    get: function () {
        return this._value;
    }
};

DateInput.property.format = {
    set: function (value) {
        value = value || 'dd/mm/yyyy';
        if (value == this._format) return;
        if (DateInput.formaters[value]) {
            this._formater = DateInput.formaters[value];
            this._format = value;
            this.value = this.value;
        }
        else {
            throw new Error("Not support format " + value);
        }
    },
    get: function () {
        return this._format;
    }
};

DateInput.property.disabled = {
    set: function (value) {
        value = !!value;
        this.$input.disabled = value;
        if (value) this.addClass('as-disabled');
        else this.removeClass('as-disabled');
    },
    get: function () {
        return this.$input.disabled;
    }
};

ACore["d" /* default */].install(DateInput);

/* harmony default export */ var js_DateInput = (DateInput);
// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/DomSignal.js
var DomSignal = __webpack_require__(20);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/datetimeinput.css
var datetimeinput = __webpack_require__(145);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/utils.js
var utils = __webpack_require__(4);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/chrometimepicker.css
var chrometimepicker = __webpack_require__(90);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/ChromeTimePicker.js






/***
 * @extends AElement
 * @constructor
 */
function ChromeTimePicker() {
    this._hour = null;
    this._minute = null;
    this.$lists = Object(ACore["b" /* $$ */])('.as-chrome-time-picker-list', this);
    this.$hourList = this.$lists[0];
    this.$hourList.on('scroll', this.eventHandler.hourScroll)
        .on('click', this.eventHandler.clickHourList);

    this.$hour24List = this.$lists[1];
    this.$hour24List.on('scroll', this.eventHandler.hour24Scroll)
        .on('click', this.eventHandler.clickHour24List);


    this.$minList = this.$lists[2];
    this.$minList.on('scroll', this.eventHandler.minScroll)
        .on('click', this.eventHandler.clickMinList);
    this.$attachhook = Object(ACore["c" /* _ */])('attachhook').addTo(this);
    this.domSignal = new DomSignal["a" /* default */](this.$attachhook)
        .on('request_scroll_into_selected', this._scrollIntoSelected.bind(this));
    this.$amBtn = Object(ACore["a" /* $ */])('.as-chrome-time-picker-btn[data-value="AM"]', this)
        .on('click', this.eventHandler.clickAM);
    this.$pmBtn = Object(ACore["a" /* $ */])('.as-chrome-time-picker-btn[data-value="PM"]', this)
        .on('click', this.eventHandler.clickPM);
    this.scrollIntoSelected();
    this.hour = null;
    this.minute = null;
    this.s24 = false;
    Object(ACore["b" /* $$ */])('.as-chrome-time-picker-scroller', this).forEach(this._makeScroller.bind(this));
}

ChromeTimePicker.tag = 'ChromeTimePicker'.toLowerCase();

ChromeTimePicker.render = function () {
    return Object(ACore["c" /* _ */])({
        class: 'as-chrome-time-picker',
        extendEvent: ['change'],
        child: [
            {
                class: ['as-chrome-time-picker-scroller', 'as-chrome-time-picker-scroller-h12'],
                child: [
                    {tag: 'button', class: 'as-chrome-time-picker-scroller-up', child: 'span.mdi.mdi-chevron-up'},
                    {tag: 'button', class: 'as-chrome-time-picker-scroller-down', child: 'span.mdi.mdi-chevron-down'},
                    {
                        class: ['as-chrome-time-picker-viewport', 'as-chrome-time-picker-h12'],
                        child: {
                            class: 'as-chrome-time-picker-list',
                            child: Array(36).fill(0).map(function (u, i) {
                                return {
                                    tag: 'button',
                                    class: 'as-chrome-time-picker-btn',

                                    child: {
                                        tag: 'span',
                                        child: {text: (i % 12) + 1 + ''}
                                    },
                                    props: {
                                        __hour__: (i % 12) + 1
                                    }
                                }
                            })
                        }
                    }]
            },
            {
                class: ['as-chrome-time-picker-scroller', 'as-chrome-time-picker-scroller-h24'],
                child: [
                    {tag: 'button', class: 'as-chrome-time-picker-scroller-up', child: 'span.mdi.mdi-chevron-up'},
                    {tag: 'button', class: 'as-chrome-time-picker-scroller-down', child: 'span.mdi.mdi-chevron-down'},
                    {
                        class: ['as-chrome-time-picker-viewport', 'as-chrome-time-picker-h24'],
                        child: {
                            class: 'as-chrome-time-picker-list',
                            child: Array(24 * 3).fill(0).map(function (u, i) {
                                return {
                                    tag: 'button',
                                    class: 'as-chrome-time-picker-btn',

                                    child: {
                                        tag: 'span',
                                        child: {text: (i % 24) + ''}
                                    },
                                    props: {
                                        __hour__: (i % 24)
                                    }
                                }
                            })
                        }
                    }]
            }, {
                class: 'as-chrome-time-picker-scroller',
                child: [
                    {tag: 'button', class: 'as-chrome-time-picker-scroller-up', child: 'span.mdi.mdi-chevron-up'},
                    {tag: 'button', class: 'as-chrome-time-picker-scroller-down', child: 'span.mdi.mdi-chevron-down'},
                    {
                        class: 'as-chrome-time-picker-viewport',
                        child: {
                            class: 'as-chrome-time-picker-list',
                            child: Array(180).fill(0).map(function (u, i) {
                                return {
                                    tag: 'button',
                                    class: 'as-chrome-time-picker-btn',

                                    child: {
                                        tag: 'span',

                                        child: {text: (i % 60) + ''}
                                    },
                                    props: {
                                        __min__: (i % 60)
                                    }
                                }
                            })
                        }
                    }]
            },
            {
                class: ['as-chrome-time-picker-viewport', 'as-chrome-time-picker-period'],
                child: ['AM', 'PM'].map(function (u,) {
                    return {
                        tag: 'button',
                        class: 'as-chrome-time-picker-btn',
                        attr: {
                            'data-value': u
                        },
                        child: {
                            tag: 'span',
                            child: {text: u}
                        },
                        props: {
                            __APM__: u
                        }
                    }
                })
            }
        ]
    });
};

ChromeTimePicker.prototype._makeScroller = function (rootElt) {
    var upBtn = Object(ACore["a" /* $ */])('.as-chrome-time-picker-scroller-up', rootElt);
    var downBtn = Object(ACore["a" /* $ */])('.as-chrome-time-picker-scroller-down', rootElt);
    var listElt = Object(ACore["a" /* $ */])('.as-chrome-time-picker-list', rootElt);
    var delta = 0;

    function tick() {
        if (delta === 0) return;
        listElt.scrollTop -= delta;
        requestAnimationFrame(tick);
    }

    function cancel() {
        delta = 0;
        document.body.removeEventListener('mouseup', cancel);
        document.body.removeEventListener('mouseleave', cancel);
    }

    upBtn.on('mousedown', function () {
        delta = 5;
        document.body.addEventListener('mouseup', cancel);
        document.body.addEventListener('mouseleave', cancel);
        tick();

    });

    downBtn.on('mousedown', function () {
        delta = -5;
        document.body.addEventListener('mouseup', cancel);
        document.body.addEventListener('mouseleave', cancel);
        tick();
    });


};


ChromeTimePicker.prototype.scrollIntoSelected = function () {
    this.domSignal.emit('request_scroll_into_selected');
};

ChromeTimePicker.prototype._scrollIntoSelected = function () {
    var hour = this._hour;
    this.$hour24List.scrollTop = (hour + 24) * 28;
    hour = this._hour % 12;
    if (hour === 0) hour = 12;
    this.$hourList.scrollTop = (hour + 11) * 28;
    this.$minList.scrollTop = (this._minute + 60) * 28;
};


ChromeTimePicker.prototype.notifyChange = function (event) {
    this.emit('change', {
        type: 'change',
        originEvent: event,
        dayOffset: this.dayOffset,
        hour: this.hour,
        minute: this.minute,
        target: this
    }, this);
}

ChromeTimePicker.property = {};


ChromeTimePicker.property.hour = {
    set: function (value) {
        if (Object(utils["isRealNumber"])(value)) {
            value = Math.min(23, Math.max(0, Math.floor(value) % 24));
        } else {
            value = null;
        }
        var prevVal = this._hour;
        if (prevVal !== null) {
            this.$hour24List.childNodes[prevVal].removeClass('as-selected');
            this.$hour24List.childNodes[prevVal + 24].removeClass('as-selected');
            this.$hour24List.childNodes[prevVal + 48].removeClass('as-selected');
            prevVal = this._hour % 12;
            if (prevVal === 0) prevVal = 12;
            this.$hourList.childNodes[prevVal - 1].removeClass('as-selected');
            this.$hourList.childNodes[prevVal - 1 + 12].removeClass('as-selected');
            this.$hourList.childNodes[prevVal - 1 + 24].removeClass('as-selected');
        }
        this._hour = value;
        prevVal = this._hour;
        if (prevVal !== null) {
            this.$hour24List.childNodes[prevVal].addClass('as-selected');
            this.$hour24List.childNodes[prevVal + 24].addClass('as-selected');
            this.$hour24List.childNodes[prevVal + 48].addClass('as-selected');
            prevVal = this._hour % 12;
            if (prevVal === 0) prevVal = 12;
            this.$hourList.childNodes[prevVal - 1].addClass('as-selected');
            this.$hourList.childNodes[prevVal - 1 + 12].addClass('as-selected');
            this.$hourList.childNodes[prevVal - 1 + 24].addClass('as-selected');
            if (this._hour >= 12) {
                this.$pmBtn.addClass('as-selected');
                this.$amBtn.removeClass('as-selected');
            } else {
                this.$amBtn.addClass('as-selected');
                this.$pmBtn.removeClass('as-selected');
            }
        } else {
            this.$pmBtn.removeClass('as-selected');
            this.$amBtn.removeClass('as-selected');
        }
    },
    get: function () {
        return this._hour;
    }
};


ChromeTimePicker.property.minute = {
    set: function (value) {
        if (Object(utils["isRealNumber"])(value)) {
            value = Math.min(59, Math.max(0, Math.floor(value) % 60));
        } else {
            value = null;
        }
        var prevVal = this._minute;
        if (prevVal !== null) {
            this.$minList.childNodes[prevVal].removeClass('as-selected');
            this.$minList.childNodes[prevVal + 60].removeClass('as-selected');
            this.$minList.childNodes[prevVal + 120].removeClass('as-selected');
        }
        this._minute = value;
        prevVal = this._minute;
        if (prevVal !== null) {
            this.$minList.childNodes[prevVal].addClass('as-selected');
            this.$minList.childNodes[prevVal + 60].addClass('as-selected');
            this.$minList.childNodes[prevVal + 120].addClass('as-selected');
        }
    },
    get: function () {
        return this._minute;
    }
};


ChromeTimePicker.property.dayOffset = {
    set: function (value) {
        if (!Object(utils["isRealNumber"])(value) && !(value instanceof Date)) {
            value = null;
        }
        if (value && value.getTime) {
            value = value.getTime() - Object(datetime["beginOfDay"])(value).getTime();
            if (!Object(utils["isRealNumber"])(value)) value = null;
        } else if (Object(utils["isRealNumber"])(value)) {
            value = Math.min(datetime["MILLIS_PER_DAY"] - 1, Math.max(0, value % datetime["MILLIS_PER_DAY"]));
        }

        if (Object(utils["isRealNumber"])(value)) {
            this.hour = Math.floor(value / datetime["MILLIS_PER_HOUR"]);
            this.minute = Math.floor((value % datetime["MILLIS_PER_HOUR"]) / datetime["MILLIS_PER_MINUTE"]);
        } else {
            this.hour = null;
            this.minute = null;
        }
        this.domSignal.emit('request_scroll_into_selected');
    },
    get: function () {
        var res = this._hour * datetime["MILLIS_PER_HOUR"] + this._minute * datetime["MILLIS_PER_MINUTE"];
        return Object(utils["isRealNumber"])(res) ? res : null;
    }
};

ChromeTimePicker.property.s24 = {
    set: function (value) {
        if (value) {
            this.addClass('as-24h-clock');
        } else {
            this.removeClass('as-24h-clock');
        }
    },
    get: function () {
        return this.containsClass('as-24h-clock');
    }
}

ChromeTimePicker.eventHandler = {};

ChromeTimePicker.eventHandler.hourScroll = function () {
    var y = this.$hourList.scrollTop;
    var dy = 0;
    if (y < 28 * 12) dy = 28 * 12;
    else if (y > 28 * 24) {
        dy = -28 * 12;
    }
    if (dy !== 0) {
        this.$hourList.scrollTop += dy;
    }
};

ChromeTimePicker.eventHandler.hour24Scroll = function () {
    var y = this.$hour24List.scrollTop;
    var dy = 0;
    if (y < 28 * 24) dy = 28 * 24;
    else if (y > 28 * 48) {
        dy = -28 * 24;
    }
    if (dy !== 0) {
        this.$hour24List.scrollTop += dy;
    }
};

ChromeTimePicker.eventHandler.minScroll = function () {
    var y = this.$minList.scrollTop;
    var dy = 0;
    if (y < 28 * 60) dy = 28 * 60;
    else if (y > 28 * 120) {
        dy = -28 * 60;
    }
    if (dy !== 0) {
        this.$minList.scrollTop += dy;
    }
};

ChromeTimePicker.eventHandler.clickHourList = function (event) {
    var hour;
    if ('__hour__' in event.target) hour = event.target.__hour__;
    if ('__hour__' in event.target.parentElement) hour = event.target.parentElement.__hour__;
    if (hour !== undefined) {
        if (this.hour >= 12) {
            this.hour = hour === 12 ? hour : hour + 12;
        } else {
            this.hour = hour === 12 ? 0 : hour;
        }

        if ((hour - 1 + 12) * 28 < this.$hourList.scrollTop) {
            this.$hourList.scrollTop = (hour - 1 + 12) * 28;
        } else if (((hour - 1 + 13) * 28) > this.$hourList.scrollTop + this.$hourList.clientHeight) {
            this.$hourList.scrollTop = (hour - 1 + 13) * 28 - this.$hourList.clientHeight;
        }
        this.notifyChange(event);
    }
};


ChromeTimePicker.eventHandler.clickHour24List = function (event) {
    var hour;
    if ('__hour__' in event.target) hour = event.target.__hour__;
    if ('__hour__' in event.target.parentElement) hour = event.target.parentElement.__hour__;
    if (hour !== undefined) {
        this.hour = hour;
        if ((hour + 24) * 28 < this.$hourList.scrollTop) {
            this.$hourList.scrollTop = (hour + 24) * 28;
        } else if (((hour + 24) * 28) > this.$hourList.scrollTop + this.$hourList.clientHeight) {
            this.$hourList.scrollTop = (hour + 24) * 28 - this.$hourList.clientHeight;
        }
        this.notifyChange(event);
    }
};

ChromeTimePicker.eventHandler.clickMinList = function (event) {
    var min;
    if ('__min__' in event.target) min = event.target.__min__;
    if ('__min__' in event.target.parentElement) min = event.target.parentElement.__min__;
    if (min !== undefined) {
        this.minute = min;
        if ((min + 60) * 28 < this.$minList.scrollTop) {
            this.$minList.scrollTop = (min + 60) * 28;
        } else if (((min + 61) * 28) > this.$minList.scrollTop + this.$minList.clientHeight) {
            this.$minList.scrollTop = (min + 61) * 28 - this.$minList.clientHeight;
        }
        this.notifyChange(event);
    }
};

ChromeTimePicker.eventHandler.clickPM = function (event) {
    if (Object(utils["isRealNumber"])(this.hour)) {
        if (this.hour < 12)
            this.hour += 12;
    } else {
        this.hour = 12;
    }
    this.notifyChange(event);

};

ChromeTimePicker.eventHandler.clickAM = function (event) {
    if (Object(utils["isRealNumber"])(this.hour)) {
        if (this.hour >= 12)
            this.hour -= 12;
    } else {
        this.hour = 0;
    }
    this.notifyChange(event);
};


ACore["d" /* default */].install(ChromeTimePicker);

/* harmony default export */ var js_ChromeTimePicker = (ChromeTimePicker);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Follower.js
var Follower = __webpack_require__(25);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/DateTimeInput.js











var STATE_NEW = 1;
var STATE_EDITED = 2;
var STATE_NONE = 0;

/***
 * @extends AElement
 * @constructor
 */
function DateTimeInput() {
    this._editingData = {};
    this._value = null;
    this._min = new Date(1890, 0, 1);
    this._max = new Date(new Date(2090, 0, 1).getTime() - 1);
    this._format = 'dd/MM/yyyy hh:mm a';
    this.$attachhook = Object(ACore["c" /* _ */])('attachhook').addTo(this);
    this.domSignal = new DomSignal["a" /* default */](this.$attachhook);
    this.domSignal.on('request_auto_select', this._autoSelect.bind(this));
    /***
     *
     * @type {HTMLInputElement | AElement}
     */
    this.$text = Object(ACore["a" /* $ */])('.as-date-time-input-text', this)
        .on('mousedown', this.eventHandler.mouseDownInput)
        .on('mouseup', this.eventHandler.mouseUpInput)
        .on('dblclick', this.eventHandler.dblclickInput)
        .on('keydown', this.eventHandler.keydown)
        .on('blur', this.eventHandler.inputBlur)
        .on('contextmenu', function (event) {
            event.preventDefault();
        });
    this.$pickerBtn = Object(ACore["a" /* $ */])('.as-date-time-input-icon-btn', this)
        .on('click', this.eventHandler.clickPickerBtn);
    this.$clearBtn = Object(ACore["a" /* $ */])('button.as-time-input-clear-btn', this)
        .on('click', this.clear.bind(this));
    this.notNull = false;
    this.min = this._min;
    this.max = this._max;
}

DateTimeInput.tag = 'DateTimeInput'.toLowerCase();

//calendar-clock
DateTimeInput.render = function () {
    return Object(ACore["c" /* _ */])({
        extendEvent: ['change'],
        class: 'as-date-time-input',
        child: [
            {
                tag: 'input',
                class: 'as-date-time-input-text',
                attr: {
                    ondrop: "return false;"
                },
                props: {
                    value: 'dd/MM/yyyy hh:mm a'
                }
            },
            {
                tag: 'button',
                class: 'as-time-input-clear-btn',
                child: 'span.mdi.mdi-close-circle'
            },
            {
                tag: 'button',
                class: 'as-date-time-input-icon-btn',
                child: 'span.mdi.mdi-calendar-clock'
            }
        ]
    });
};

DateTimeInput.prototype.tokenRegex = /([^.\/:\-,\\\s]+)|([.\/:\-,\\]+)/i;


/***
 *
 * @param start
 * @returns {null|{ident: string, length: number, sourceText: string, replace: function(s: string, selecting:boolean):void, text: string, idx: number, elt: (HTMLInputElement|absol.AElement)}}
 */
DateTimeInput.prototype._tokenAt = function (start) {
    var rgx = new RegExp(this.tokenRegex.source, 'g');
    var rgxFormat = new RegExp(this.tokenRegex.source, 'g');
    var s = this.$text.value;
    var format = this._format;
    var tokenMatched = rgx.exec(s);
    var formatToken = rgxFormat.exec(format);
    var tokenMatchedList = [];
    var formatTokenList = [];
    var text, ident;
    var idx;
    while (tokenMatched && formatToken) {
        text = tokenMatched[1];
        ident = formatToken[1];
        if (text && Object(utils["isDateTimeFormatToken"])(ident)) {
            tokenMatchedList.push(tokenMatched);
            formatTokenList.push(formatToken);
        }

        tokenMatched = rgx.exec(s);
        formatToken = rgxFormat.exec(format);
    }
    var bestI = -1;
    var bestD = Infinity;
    var d;
    for (var i = 0; i < tokenMatchedList.length; ++i) {
        tokenMatched = tokenMatchedList[i];
        formatToken = formatTokenList[i];
        text = tokenMatched[1];
        idx = tokenMatched.index;
        d = Math.min(Math.abs(start - idx), Math.abs(start - (idx + text.length)));
        if (d < bestD) {
            bestD = d;
            bestI = i;
        }

    }

    if (bestI >= 0) {
        tokenMatched = tokenMatchedList[bestI];
        formatToken = formatTokenList[bestI];
        text = tokenMatched[1];
        ident = formatToken[1];
        idx = tokenMatched.index;
        return {
            idx: idx,
            text: text,
            length: text.length,
            ident: ident,
            elt: this.$text,
            sourceText: s,
            replace: function (newText, selecting) {
                var left = this.sourceText.substr(0, this.idx);
                var right = this.sourceText.substr(this.idx + this.length);
                this.text = newText;
                this.length = newText.length;
                this.sourceText = left + this.text + right;
                this.elt.value = this.sourceText;
                if (selecting) {
                    this.elt.setSelectionRange(this.idx, this.idx + this.length);
                }
            }
        }
    }
    return null;
};

DateTimeInput.prototype._autoSelect = function () {
    var token = this._tokenAt(this.$text.selectionStart);
    var tokenEnd = this._tokenAt(this.$text.selectionEnd);
    if (token) {
        if (tokenEnd.idx === token.idx) {
            this.$text.setSelectionRange(token.idx, token.idx + token.length);
            this._editingData.state = STATE_NEW;
        } else {
            this.$text.select();
            this._editingData.state = STATE_NONE;
        }
    }
};

DateTimeInput.prototype._editNextToken = function () {
    var token = this._tokenAt(this.$text.selectionStart);
    if (!token) return false;
    var cIdx = token.idx;
    var l = this.$text.value.length;
    for (var i = token.idx + token.length; i < l; ++i) {
        token = this._tokenAt(i);
        if (token && token.idx !== cIdx) {
            this.$text.setSelectionRange(token.idx, token.idx + token.length);
            this._editingData.state = STATE_NEW;
            break;
        }
    }
};

DateTimeInput.prototype._editPrevToken = function () {
    var token = this._tokenAt(this.$text.selectionStart);
    if (!token) return false;
    var cIdx = token.idx;
    var l = this.$text.value.length;
    for (var i = token.idx - 1; i >= 0; --i) {
        token = this._tokenAt(i);
        if (token && token.idx !== cIdx) {
            this.$text.setSelectionRange(token.idx, token.idx + token.length);
            this._editingData.state = STATE_NEW;
            break;
        }
    }
};

DateTimeInput.prototype.tokenMap = {
    d: 'd',
    dd: 'd',
    M: 'M',
    MM: 'M',
    y: 'y',
    yyyy: 'y',
    hh: 'h',
    h: 'h',
    mm: 'm',
    m: 'm',
    a: 'a',
};

/***
 *
 * @param {string} s
 * @returns {{}}
 * @private
 */
DateTimeInput.prototype._makeTokenDict = function (s) {
    var rgx = new RegExp(this.tokenRegex.source, 'g');
    var rgxFormat = new RegExp(this.tokenRegex.source, 'g');
    var format = this._format;
    var tokenMap = this.tokenMap;
    var tokenMatched = rgx.exec(s);
    var formatToken = rgxFormat.exec(format);
    var text, ident;
    var idx;
    var res = {};
    while (tokenMatched && formatToken) {
        text = tokenMatched[1];
        ident = formatToken[1];
        if (text) {
            if (tokenMap[ident]) {
                idx = tokenMatched.index;
                res[tokenMap[ident]] = {
                    text: text,
                    idx: idx,
                    length: text.length,
                    sourceText: s,
                    value: ident === 'a' ? text : parseInt(text)
                }
            }
        }
        tokenMatched = rgx.exec(s);
        formatToken = rgxFormat.exec(format);
    }
    return res;
};


/***
 *
 * @param {Date} date
 * @private
 */
DateTimeInput.prototype._makeValueDict = function (date) {
    var res = {};
    res.d = {value: date.getDate()};
    res.y = {value: date.getFullYear()};
    res.M = {value: date.getMonth() + 1};
    res.m = {value: date.getMinutes()};
    res.h = {value: date.getHours()};
    if (res.h.value < 12) {
        if (res.h.value === 0) res.h.value = 12;
        res.a = {value: "AM"};
    } else {
        if (res.h.value > 12) res.h.value -= 12;
        res.a = {value: "PM"};
    }
    return res;
};


DateTimeInput.prototype._applyTokenDict = function (format, dict, debug) {
    var rgx = new RegExp(this.tokenRegex.source, 'g');
    var tokenMap = this.tokenMap;
    return format.replace(rgx, function (full, g1, g2, sourceText) {
        if (g1 && tokenMap[g1]) {
            var ident = tokenMap[g1];
            if (ident === 'a') {
                return (dict.a && dict.a.value) || 'a';
            } else {
                if (dict[ident] && !isNaN(dict[ident].value)) {
                    var numberText = dict[ident].value + '';
                    while (numberText.length < g1.length) numberText = '0' + numberText;
                    return numberText;
                } else {
                    return full;
                }
            }
        } else
            return full;
    });

};

DateTimeInput.prototype._loadValueFromInput = function () {
    var tkDict = this._makeTokenDict(this.$text.value);
    var H = NaN;
    if (tkDict.a.value === 'AM') {
        H = tkDict.h.value % 12;
    } else if (tkDict.a.value === 'PM') {
        H = tkDict.h.value + (tkDict.h.value === 12 ? 0 : 12);
    }
    var date = new Date(tkDict.y.value, tkDict.M.value - 1, tkDict.d.value, H, tkDict.m.value);
    if (isNaN(date.getTime())) {
        this._value = null;
    } else {
        this._value = date;
    }
};

DateTimeInput.prototype.clear = function () {
    var lev = this._lastEmitValue;
    if (this.notNull) {
        this.value = Object(datetime["formatDateTime"])(
            new Date(Math.max(this.min.getTime(), Math.min(this.max.getTime(), new Date().getTime()))),
            this.format);
    } else {
        this.value = null;
    }

    this._lastEmitValue = lev;
    this._notifyIfChange();
};

DateTimeInput.prototype._notifyIfChange = function (event) {
    if (!this._lastEmitValue && !this._value) return;
    if (this._lastEmitValue && this._value && this._lastEmitValue.getTime() === this._value.getTime()) return;
    this.emit('change', {
        type: 'change',
        target: this,
        value: this._value,
        originEvent: event
    }, this);

    this._lastEmitValue = this._value;
};

DateTimeInput.prototype._correctingInput = function () {
    var tkDict = this._makeTokenDict(this.$text.value);
    var equalMin = true;
    var equalMax = true;
    if (!isNaN(tkDict.y.value)) {
        tkDict.y.value = Math.max(this._min.getFullYear(), Math.min(this._max.getFullYear(), tkDict.y.value));
        equalMin = tkDict.y.value === this._min.getFullYear();
        equalMax = tkDict.y.value === this._max.getFullYear();
    } else {
        equalMin = false;
        equalMax = false;
    }

    if (!isNaN(tkDict.M.value)) {
        tkDict.M.value = Math.max(1, Math.min(12, tkDict.M.value));
        if (equalMin) {
            tkDict.M.value = Math.max(this._min.getMonth() + 1, tkDict.M.value);
            equalMin = tkDict.M.value === this._min.getMonth() + 1;
        }

        if (equalMax) {
            tkDict.M.value = Math.min(this._max.getMonth() + 1, tkDict.M.value);
            equalMax = this._max.getMonth() + 1;
        }
    } else {
        equalMin = false;
        equalMax = false;
    }

    if (!isNaN(tkDict.d.value)) {
        tkDict.d.value = Math.max(1, Math.min(31, tkDict.d.value));
        if (!isNaN(tkDict.M.value)) {
            tkDict.d.value = Math.min(tkDict.d.value,
                Object(datetime["daysInMonth"])(isNaN(tkDict.y.value) ? 2020 : tkDict.y.value, tkDict.M.value - 1));
        }

        if (equalMin) {
            tkDict.d.value = Math.max(this._min.getDate(), tkDict.d.value);
            equalMin = tkDict.d.value === this._min.getDate();
        }

        if (equalMax) {
            tkDict.d.value = Math.min(this._max.getDate(), tkDict.d.value);
            equalMax = tkDict.d.value === this._max.getDate();
        }
    } else {
        equalMin = false;
        equalMax = false;
    }
//todo: min max
    if (tkDict.a.value === 'AM' || tkDict.a.value === 'PM') {

        if (equalMin) {

        }
    } else {
        equalMin = false;
        equalMax = false;
    }

    var text = this._applyTokenDict(this._format, tkDict);
    this.$text.value = text;
};

DateTimeInput.prototype._correctingCurrentToken = function () {
    var token = this._tokenAt(this.$text.selectionStart);
    if (!token) return;
    var value;
    if (token.ident === 'a') {
        if (token.text !== 'a' && token.text !== 'AM' && token.text !== 'PM') {
            token.replace('a', false);
        }
    } else {
        value = parseInt(token.text);
        var rqMin = {
            d: 1, dd: 1,
            M: 1, MM: 1,
            y: 1890, yyyy: 1890,
            h: 1, hh: 1,
            m: 0, mm: 0
        }[token.ident];
        var rqMax = {
            d: 31, dd: 31,
            M: 12, MM: 12,
            y: 2089, yyyy: 2089,
            h: 12, hh: 12,
            m: 59, mm: 59
        }[token.ident];
        if (rqMin !== undefined) {
            if (!isNaN(value)) {
                if ((value < rqMin || value > rqMin)) {
                    value = Math.max(rqMin, Math.min(rqMax, value));
                    token.replace(Object(utils["zeroPadding"])(value, token.ident.length), false);
                    this._editingData.d = value;
                }
            } else if (token.text !== token.ident) {
                token.replace(token.ident, false);
            }
        }
    }

};

DateTimeInput.prototype._dateFrom = function (value) {
    var typeV = typeof value;
    if (typeV === 'string' || typeV === 'number') {
        value = new Date(value);
    }
    if (!value || !value.getTime) value = null;
    if (value) {
        value = new Date(value.getTime());
        value.setSeconds(0, 0);
    }
    return value || null;
}


DateTimeInput.property = {};

DateTimeInput.property.disabled = {
    set: function (value) {
        this.$text.disabled = !!value;
        if (value) {
            this.addClass('as-disabled');
        } else {
            this.removeClass('as-disabled');
        }
    },
    get: function () {
        return this.containsClass('as-disabled');
    }
};

DateTimeInput.property.format = {
    set: function (value) {
        var dict;
        if (this._value) {
            dict = this._makeValueDict(this._value);
        } else {
            dict = this._makeTokenDict(this.$text.value);
        }
        this._format = value;
        this.$text.value = this._applyTokenDict(value, dict);

    },
    get: function () {
        return this._format;
    }
};

DateTimeInput.property.value = {
    set: function (value) {
        this._value = this._dateFrom(value);
        var dict;
        if (this._value) {
            dict = this._makeValueDict(this._value);
        } else {
            dict = this._makeTokenDict(this.$text.value);
        }
        if (value) {
            this.$text.value = this._applyTokenDict(this._format, dict, true);
        } else {
            this.$text.value = this.format;
        }
        this._lastEmitValue = this._value;
    },
    get: function () {
        return this._value;
    }
};

DateTimeInput.property.min = {
    set: function (value) {
        this._min = this._dateFrom(value) || new Date(1890, 0, 1);
    },
    get: function () {
        return this._min;
    }
};


DateTimeInput.property.max = {
    set: function (value) {
        this._max = this._dateFrom(value) || new Date(new Date(2090, 0, 1).getTime() - 1);
    },
    get: function () {
        return this._max;
    }
};


DateTimeInput.eventHandler = {};

DateTimeInput.eventHandler.mouseUpInput = function () {
    this.domSignal.emit('request_auto_select');
};

DateTimeInput.eventHandler.mouseDownInput = function () {
    if (document.activeElement === this.$text) {
        this._correctingCurrentToken();
    }
}

DateTimeInput.eventHandler.dblclickInput = function (event) {
    event.preventDefault();
};

/***
 *
 * @param {KeyboardEvent} event
 */
DateTimeInput.eventHandler.keydown = function (event) {
    var token = this._tokenAt(this.$text.selectionStart);
    var endToken = this._tokenAt(this.$text.selectionEnd);
    if (!token) {
        if (event.key === 'Enter') {
            this._correctingInput();
            this._loadValueFromInput();
            this._notifyIfChange(event);
        }
        return;
    }
    var newTokenText;
    var value;
    if (event.key.startsWith('Arrow') || [' ', ':', '/', '-'].indexOf(event.key) >= 0) {
        event.preventDefault();

        switch (event.key) {
            case 'ArrowLeft':
                this._editPrevToken();
                break;
            case 'ArrowRight':
            case ' ':
            case ':':
            case '/':
            case '-':
                this._editNextToken();
                break;
            case 'ArrowUp':
            case 'ArrowDown':
                switch (token.ident) {
                    case 'dd':
                    case 'd':
                        value = parseInt(token.text);
                        if (isNaN(value)) {
                            this._editingData.d = event.key === 'ArrowUp' ? 1 : 31;
                        } else {
                            this._editingData.d = 1 + (value + (event.key === 'ArrowUp' ? 0 : 29)) % 31;
                        }
                        newTokenText = '' + this._editingData.d;
                        while (newTokenText.length < token.ident.length) newTokenText = '0' + newTokenText;
                        token.replace(newTokenText, true);
                        break;
                    case 'MM':
                    case 'M':
                        value = parseInt(token.text) - 1;
                        if (isNaN(value)) {
                            this._editingData.M = event.key === 'ArrowUp' ? 0 : 11;
                        } else {
                            this._editingData.M = (value + (event.key === 'ArrowUp' ? 1 : 11)) % 12;
                        }
                        newTokenText = '' + (this._editingData.M + 1);
                        while (newTokenText.length < token.ident.length) newTokenText = '0' + newTokenText;
                        token.replace(newTokenText, true);
                        break;
                    case 'yyyy':
                        value = parseInt(token.text);
                        if (isNaN(value)) {
                            this._editingData.y = new Date().getFullYear();
                        } else {
                            this._editingData.y = Math.max(1890, Math.min(2089, value + (event.key === 'ArrowUp' ? 1 : -1)));
                        }

                        newTokenText = this._editingData.y + '';
                        while (newTokenText.length < token.ident.length) newTokenText = '0' + newTokenText;
                        token.replace(newTokenText, true);
                        break;
                    case "hh":
                    case 'h':
                        value = parseInt(token.text);
                        if (isNaN(value)) {
                            this._editingData.h = event.key === 'ArrowUp' ? 1 : 12;
                        } else {
                            this._editingData.h = 1 + (value + (event.key === 'ArrowUp' ? 0 : 10)) % 12;
                        }
                        newTokenText = this._editingData.h + '';
                        while (newTokenText.length < token.ident.length) newTokenText = '0' + newTokenText;
                        token.replace(newTokenText, true);
                        break;
                    case "mm":
                    case 'm':
                        value = parseInt(token.text);
                        if (isNaN(value)) {
                            this._editingData.m = event.key === 'ArrowUp' ? 0 : 59;
                        } else {
                            this._editingData.m = (value + (event.key === 'ArrowUp' ? 1 : 59)) % 60;
                        }
                        newTokenText = this._editingData.m + '';
                        while (newTokenText.length < token.ident.length) newTokenText = '0' + newTokenText;
                        token.replace(newTokenText, true);
                        break;
                    case 'a':
                        value = token.text;
                        this._editingData.a = value === 'PM' ? "AM" : "PM";
                        newTokenText = this._editingData.a;
                        token.replace(newTokenText, true);
                        break;
                }
                break;
        }
    } else if (event.key === "Delete" || event.key === 'Backspace') {
        event.preventDefault();
        if (endToken.idx !== token.idx) {
            if (this.notNull) {
                this.$text.value = Object(datetime["formatDateTime"])(
                    new Date(Math.max(this.min.getTime(), Math.min(this.max.getTime(), new Date().getTime()))),
                    this.format);
            } else {
                this.$text.value = this._format;
            }
            this.$text.select();
        } else {
            if (this.notNull) {
                switch (token.ident) {
                    case 'HH':
                    case 'mm':
                    case 'H':
                    case 'm':
                        token.replace(Object(utils["zeroPadding"])(0, token.ident.length), true);
                        break;
                    case 'h':
                    case 'hh':
                        token.replace('12', true);
                        break;
                    case 'M':
                    case 'MM':
                    case 'dd':
                    case 'd':
                        token.replace(Object(utils["zeroPadding"])(1, token.ident.length), true);
                        break;
                    case 'y':
                    case 'yyyy':
                        token.replace(
                            Object(utils["zeroPadding"])(Math.max(this.min.getFullYear(), Math.min(this.max.getFullYear(), new Date().getFullYear())),
                                token.ident.length),
                            true);
                        break;
                    case 'a':
                        token.replace('AM', true);
                        break;

                }
            } else {
                token.replace(token.ident, true);
            }
            if (event.key === "Delete") this._editNextToken();
            else this._editPrevToken();
        }
    } else if (event.key === "Enter" || event.key === 'Tab') {
        this._correctingInput();
        this._loadValueFromInput();
        this._notifyIfChange(event);
    } else if (event.ctrlKey) {
        switch (event.key) {
            case 'a':
            case 'A':
                break;
            case 'c':
            case 'C':
                break;
            case 'x':
            case 'X':
                this.domSignal.once('clear_value', function () {
                    this.$text.value = this._format;
                    this.$text.select();
                }.bind(this));
                this.domSignal.emit('clear_value');
                break;
            default:
                event.preventDefault();
        }
    } else if (event.key.match(/^[0-9]$/g)) {
        event.preventDefault();
        var dVal = parseInt(event.key);
        if (this._editingData.state === STATE_NEW) {
            switch (token.ident) {
                case 'dd':
                case 'd':
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editingData.state = STATE_EDITED;
                    this._editingData.d = dVal;
                    if (dVal > 3) {
                        this._editNextToken();
                    }
                    break;
                case 'MM':
                case 'M':
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editingData.state = STATE_EDITED;
                    this._editingData.M = dVal;
                    if (dVal > 1) {
                        this._editNextToken();
                    }
                    break;
                case 'yyyy':
                case 'y':
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editingData.state = STATE_EDITED;
                    this._editingData.state_num = 1;
                    break;
                case 'm':
                case 'mm':
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editingData.state = STATE_EDITED;
                    if (dVal > 5) {
                        this._editNextToken();
                    }
                    break;
                case 'h':
                case 'hh':
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editingData.state = STATE_EDITED;
                    if (dVal > 1) {
                        this._editNextToken();
                    }
                    break;

            }
        } else {
            switch (token.ident) {
                case 'dd':
                case 'd':
                    dVal = (parseInt(token.text.split('').pop()) || 0) * 10 + dVal;
                    dVal = Math.max(1, Math.min(31, dVal));
                    this._editingData.d = dVal;
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editNextToken();
                    break;
                case 'MM':
                case 'M':
                    dVal = (parseInt(token.text.split('').pop()) || 0) * 10 + dVal;
                    dVal = Math.max(1, Math.min(12, dVal));
                    this._editingData.M = dVal - 1;
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editNextToken();
                    break;
                case 'yyyy':
                case 'y':
                    dVal = (parseInt(token.text.replace(/^./, '')) || 0) * 10 + dVal;
                    this._editingData.state_num++;
                    if (this._editingData.state_num >= 4) {
                        // dVal = Math.max(1890, Math.min(2089, dVal));
                        token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                        this._editNextToken();
                    } else {
                        token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    }
                    break;
                case 'm':
                case 'mm':
                    dVal = (parseInt(token.text.split('').pop()) || 0) * 10 + dVal;
                    dVal = Math.max(0, Math.min(59, dVal));
                    this._editingData.m = dVal;
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editNextToken();
                    break;
                case 'h':
                case 'hh':
                    dVal = (parseInt(token.text.split('').pop()) || 0) * 10 + dVal;
                    dVal = Math.max(1, Math.min(12, dVal));
                    this._editingData.h = dVal;
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editNextToken();
                    break;
            }
        }
    } else if (event.key.match(/^[aApPSCsc]$/) && token.ident === 'a') {
        event.preventDefault();
        if (event.key.match(/^[aAsS]$/)) {
            token.replace('AM', true);
            this._editingData.a = "AM";
        } else {
            token.replace('PM', true);
            this._editingData.a = "PM";
        }
        this._editNextToken();
    } else {
        event.preventDefault();
    }

}

DateTimeInput.eventHandler.inputBlur = function () {
    this._correctingInput();
    this._loadValueFromInput();
    this._notifyIfChange();
};


DateTimeInput.eventHandler.clickPickerBtn = function () {
    this._attachPicker();
};

DateTimeInput.eventHandler.clickOut = function (event) {
    if (Object(EventEmitter["d" /* hitElement */])(this.share.$follower, event)) return;
    this._releasePicker();
};

DateTimeInput.eventHandler.clickCancelBtn = function () {
    this._releasePicker();
};


DateTimeInput.eventHandler.calendarPick = function (event) {
    var value = event.value;
    var tkDict = this._makeTokenDict(this.share.pickedValeText);
    if (tkDict.y) {
        tkDict.y.value = value.getFullYear();
    }
    if (tkDict.M) {
        tkDict.M.value = value.getMonth() + 1;
    }
    if (tkDict.d) {
        tkDict.d.value = value.getDate();
    }

    this.share.pickedValeText = this._applyTokenDict(this._format, tkDict);
};

DateTimeInput.eventHandler.clickOKBtn = function (event) {
    this.$text.value = this.share.pickedValeText;
    this._correctingInput();
    this._loadValueFromInput();
    this._notifyIfChange(event);
    this._releasePicker();
};

DateTimeInput.eventHandler.timePick = function (event) {
    var hour = event.hour;
    var minute = event.minute;
    var tkDict = this._makeTokenDict(this.share.pickedValeText);
    if (tkDict.h) {
        tkDict.h.value = 1 + ((hour + 11) % 12);
        if (tkDict.a) {
            tkDict.a.value = hour >= 12 ? "PM" : 'AM';
        }
    }
    if (tkDict.m) {
        tkDict.m.value = minute;
    }

    this.share.pickedValeText = this._applyTokenDict(this._format, tkDict);
};

DateTimeInput.prototype.share = {
    $follower: null,
    $calendar: null,
    $timePicker: null,
    $holdingInput: null
};


DateTimeInput.prototype._preparePicker = function () {
    if (!this.share.$follower) {
        this.share.$timePicker = Object(ACore["c" /* _ */])({
            tag: js_ChromeTimePicker.tag,
            class: 'as-date-time-input-time-picker'
        });
        this.share.$calendar = Object(ACore["c" /* _ */])({
            tag: ChromeCalendar["a" /* default */].tag,
            class: 'as-date-time-input-date-picker'
        });
        this.share.$closeBtn = Object(ACore["c" /* _ */])({
            tag: 'button',
            class: 'as-date-time-input-picker-btn',
            child: 'span.mdi.mdi-close'
        });
        this.share.$cancelBtn = Object(ACore["c" /* _ */])({
            tag: 'button',
            class: 'as-date-time-input-picker-btn',
            child: {text: 'CANCEL'}
        });
        this.share.$okBtn = Object(ACore["c" /* _ */])({
            tag: 'button',
            class: 'as-date-time-input-picker-btn',
            child: {text: 'OK'}
        });
        this.share.$follower = Object(ACore["c" /* _ */])({
            tag: Follower["a" /* default */].tag,
            class: 'as-date-time-input-follower',
            child: [
                {
                    class: 'as-date-time-input-picker-header',
                    child: this.share.$closeBtn
                },
                {
                    class: 'as-date-time-input-picker-ctn',
                    child: [
                        this.share.$calendar,
                        this.share.$timePicker
                    ]
                }, {
                    class: 'as-date-time-input-picker-footer',
                    child: [
                        this.share.$okBtn,
                        this.share.$cancelBtn
                    ]
                }

            ]
        });
    }
};

DateTimeInput.prototype._attachPicker = function () {
    this._preparePicker();
    if (this.share.$holdingInput) this.share.$holdingInput._releasePicker();
    this.share.pickedValeText = this.$text.value;
    this.share.$holdingInput = this;
    this.share.$follower.addStyle('visibility', 'hidden');
    this.share.$follower.addTo(document.body);
    this.share.$follower.followTarget = this;
    this.$pickerBtn.off('click', this.eventHandler.clickPickerBtn);
    this.share.$calendar.on('pick', this.eventHandler.calendarPick);
    this.share.$timePicker.on('change', this.eventHandler.timePick);
    this.share.$okBtn.on('click', this.eventHandler.clickOKBtn);
    this.share.$cancelBtn.on('click', this.eventHandler.clickCancelBtn);
    this.share.$closeBtn.on('click', this.eventHandler.clickCancelBtn);

    var tkDict = this._makeTokenDict(this.$text.value);
    if (tkDict.h && !isNaN(tkDict.h.value)) {
        if (tkDict.a && tkDict.a.value === 'PM') {
            this.share.$timePicker.hour = 12 + tkDict.h.value % 12;
        } else {
            this.share.$timePicker.hour = tkDict.h.value % 12;
        }
    } else {
        this.share.$timePicker.hour = null;
    }

    if (tkDict.m && !isNaN(tkDict.m.value)) {
        this.share.$timePicker.minute = tkDict.m.value;
    } else {
        this.share.$timePicker.minute = null;
    }
    this.share.$timePicker.scrollIntoSelected();

    var date = null;
    if (tkDict.d && !isNaN(tkDict.d.value)
        && tkDict.M && !isNaN(tkDict.M.value)
        && tkDict.y && !isNaN(tkDict.y.value)) {
        date = new Date(tkDict.y.value, tkDict.M.value - 1, tkDict.d.value);
        if (isNaN(date.getTime())) date = null;
    }
    if (date) {
        this.share.$calendar.selectedDates = [date];
        this.share.$calendar.viewDate = date;
    } else {
        this.share.$calendar.selectedDates = [];
        var viewDate = null;
        if (tkDict.y && !isNaN(tkDict.y.value)) {
            if (tkDict.M && !isNaN(tkDict.M.value)) {
                if (tkDict.d && !isNaN(tkDict.d.value)) {
                    viewDate = new Date(tkDict.y.value, tkDict.M.value - 1, tkDict.d.value);
                } else {
                    viewDate = new Date(tkDict.y.value, tkDict.M.value - 1, 1);

                }
            } else {
                viewDate = new Date(tkDict.y.value, 0, 1);
            }
        } else {
            viewDate = new Date();
        }
        if (viewDate && !isNaN(viewDate.getTime())) {
            this.share.$calendar.viewDate = viewDate;
        } else {
            this.share.$calendar.viewDate = new Date();
        }
    }


    setTimeout(function () {
        this.share.$follower.removeStyle('visibility');
        document.body.addEventListener('click', this.eventHandler.clickOut);
    }.bind(this), 5);
};

DateTimeInput.prototype._releasePicker = function () {
    if (this.share.$holdingInput !== this) return;
    this.share.$follower.remove();
    this.share.$holdingInput = null;
    this.share.$calendar.off('pick', this.eventHandler.calendarPick);
    this.share.$timePicker.off('change', this.eventHandler.timePick);
    this.share.$okBtn.off('click', this.eventHandler.clickOKBtn);
    this.share.$cancelBtn.off('click', this.eventHandler.clickCancelBtn);
    this.share.$closeBtn.off('click', this.eventHandler.clickCancelBtn);
    document.body.removeEventListener('click', this.eventHandler.clickOut);
    setTimeout(function () {
        this.$pickerBtn.on('click', this.eventHandler.clickPickerBtn);
    }.bind(this));
};


ACore["d" /* default */].install(DateTimeInput);

/* harmony default export */ var js_DateTimeInput = (DateTimeInput);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/DateInput2.js












var DateInput2_STATE_NEW = 1;
var DateInput2_STATE_EDITED = 2;
var DateInput2_STATE_NONE = 0;


var DateInput2_ = ACore["d" /* default */]._;
var DateInput2_$ = ACore["d" /* default */].$;

/**
 * @extends AElement
 * @constructor
 */
function DateInput2() {
    this._lastValue = null;
    this._value = null;
    this._format = 'dd/MM/yyyy';
    this.$input = DateInput2_$('input', this);
    this._editingData = {};
    this.startDayOfWeek = 1;
    this.$text = this.$input;
    this.$text.on('mousedown', this.eventHandler.mouseDownInput)
        .on('mouseup', this.eventHandler.mouseUpInput)
        .on('dblclick', this.eventHandler.dblclickInput)
        .on('keydown', this.eventHandler.keydown)
        .on('blur', this.eventHandler.inputBlur)
        .on('contextmenu', function (event) {
            event.preventDefault();
        });

    this.$domSignal = DateInput2_('attachhook').addTo(this);
    this.domSignal = new DomSignal["a" /* default */](this.$domSignal);
    this.domSignal.on('request_auto_select', this._autoSelect.bind(this));

    this._min = new Date(1890, 0, 1, 0, 0, 0, 0);
    this._max = new Date(2090, 0, 1, 0, 0, 0, 0);
    this.$calendarBtn = DateInput2_$('.as-date-input-icon-ctn', this)
        .on('click', this.eventHandler.clickCalendarBtn);
    this.$clearBtn = DateInput2_$('button.as-date-input-clear-btn', this)
        .on('click', this.clear.bind(this));

    this.value = this._value;
    this.format = this._format;
    this.notNull = false;
    OOP["a" /* default */].drillProperty(this, this, 'minLimitDate', 'min');
    OOP["a" /* default */].drillProperty(this, this, 'minDateLimit', 'min');
    OOP["a" /* default */].drillProperty(this, this, 'maxLimitDate', 'max');
    OOP["a" /* default */].drillProperty(this, this, 'maxDateLimit', 'max');
}

DateInput2.tag = 'dateinput';
DateInput2.render = function () {
    //only support dd/mm/yyyy
    return DateInput2_({
        class: 'as-date-input',
        extendEvent: ['change'],
        child: [{
            tag: 'input',
            class: 'as-date-input-text',
            props: {
                value: '__/__/____'
            }
        }, {
            tag: 'button',
            class: 'as-date-input-clear-btn',
            child: 'span.mdi.mdi-close-circle'
        }, {
            tag:'button',
            class: 'as-date-input-icon-ctn',
            child: 'span.mdi.mdi-calendar'
        }]
    });
};


/**
 * @param {String} text
 */
DateInput2.prototype._verifyFormat = function (text) {
    var regex = /([,.\-\/])|([a-zA-Z0-9]+)/g;
    var tokens = text.match(regex);
    var count = [['dd', 'd'], ['M', 'MM'], ['yy', 'yyyy']].map(function (list) {
        return list.reduce(function (ac, cr) {
            if (tokens.indexOf(cr) >= 0) return ac + 1;
            return ac;
        }, 0);
    });
    return count[0] <= count[1] && count[1] <= count[2] && count[2] === 1;
};

DateInput2.prototype._notifyIfChange = function (event) {
    if (!this._lastValue !== !this._value || (this._lastValue && Object(datetime["compareDate"])(this._lastValue, this._value)) !== 0) {
        this._lastValue = this._value;
        this.emit('change', {type: 'change', target: this, value: this._value, originEvent: event}, this);
    }
};

DateInput2.prototype.notifyChange = function () {
    this._lastValue = this._value;
    this.emit('change', {type: 'change', target: this, value: this._value}, this);
};

DateInput2.prototype.focus = function () {
    this.$input.focus();
};

DateInput2.prototype.blur = function () {
    this.$input.blur();
};

DateInput2.prototype.clear = function () {
    this._applyValue(null);
    this._notifyIfChange();
};

/***
 *
 * @param {Date|null} value
 */
DateInput2.prototype._applyValue = function (value) {
    this._value = value;
    if (!value) {
        this.$input.value = this.format;
    } else {
        this.$input.value = Object(datetime["formatDateTime"])(this._value, this._format);
    }
    this._updateNullClass();
};

DateInput2.prototype._updateNullClass = function () {
    var value = this._value;
    if (!value) {
        this.addClass('as-value-null');
    } else {
        this.removeClass('as-value-null');
    }
};


DateInput2.prototype.tokenRegex = js_DateTimeInput.prototype.tokenRegex;

DateInput2.prototype._autoSelect = js_DateTimeInput.prototype._autoSelect;
DateInput2.prototype._tokenAt = js_DateTimeInput.prototype._tokenAt;
DateInput2.prototype._editNextToken = js_DateTimeInput.prototype._editNextToken;
DateInput2.prototype._editPrevToken = js_DateTimeInput.prototype._editPrevToken;
DateInput2.prototype._makeTokenDict = js_DateTimeInput.prototype._makeTokenDict;

DateInput2.prototype._correctingInput = function () {
    var tkDict = this._makeTokenDict(this.$text.value);
    var min = this._min;
    var max = this._max;
    var equalMin;
    var equalMax;
    if (!isNaN(tkDict.y.value)) {
        tkDict.y.value = Math.max(min.getFullYear(), Math.min(max.getFullYear(), tkDict.y.value));
        equalMin = tkDict.y.value === min.getFullYear();
        equalMax = tkDict.y.value === max.getFullYear();
    } else {
        equalMin = false;
        equalMax = false;
    }

    if (tkDict.M && !isNaN(tkDict.M.value)) {
        tkDict.M.value = Math.max(1, Math.min(12, tkDict.M.value));
        if (equalMin) {
            tkDict.M.value = Math.max(min.getMonth() + 1, tkDict.M.value);
            equalMin = tkDict.M.value === min.getMonth() + 1;
        }

        if (equalMax) {
            tkDict.M.value = Math.min(max.getMonth() + 1, tkDict.M.value);
            equalMax = max.getMonth() + 1;
        }
    } else {
        equalMin = false;
        equalMax = false;
    }

    if (tkDict.d && !isNaN(tkDict.d.value)) {
        tkDict.d.value = Math.max(1, Math.min(31, tkDict.d.value));
        if (!isNaN(tkDict.M.value)) {
            tkDict.d.value = Math.min(tkDict.d.value,
                Object(datetime["daysInMonth"])(isNaN(tkDict.y.value) ? 2020 : tkDict.y.value, tkDict.M.value - 1));
        }

        if (equalMin) {
            tkDict.d.value = Math.max(min.getDate(), tkDict.d.value);
        }

        if (equalMax) {
            tkDict.d.value = Math.min(max.getDate(), tkDict.d.value);
        }
    }

    if (tkDict.w && !isNaN(tkDict.w.value)) {
        if (!isNaN(tkDict.y.value)) {
            tkDict.w.value = Math.max(1, Math.min(tkDict.w.value, 1
                + Object(datetime["weekIndexOf"])(Object(datetime["prevDate"])(new Date(tkDict.y.value + 1, 0, 1)), false, this._startDayOfWeek)));
        }
    }

    this.$text.value = this._applyTokenDict(this._format, tkDict);
}

DateInput2.prototype._correctingCurrentToken = function () {
    var token = this._tokenAt(this.$text.selectionStart);
    if (!token) return;
    var value;

    value = parseInt(token.text);
    var rqMin = {
        d: 1, dd: 1,
        M: 1, MM: 1,
        y: 1890, yyyy: 1890,
        w: 1, ww: 1
    }[token.ident];
    var rqMax = {
        d: 31, dd: 31,
        M: 12, MM: 12,
        y: 2089, yyyy: 2089,
        w: 54, ww: 54
    }[token.ident];
    if (rqMin !== undefined) {
        if (!isNaN(value)) {
            if ((value < rqMin || value > rqMin)) {
                value = Math.max(rqMin, Math.min(rqMax, value));
                token.replace(Object(utils["zeroPadding"])(value, token.ident.length), false);
            }
        } else if (this.notNull) {
            if (token.ident.startsWith('y')) {
                value = new Date().getFullYear();
            } else {
                value = rqMin;
            }
            token.replace(Object(utils["zeroPadding"])(value, token.ident.length), false);
        } else if (token.text !== token.ident) {
            token.replace(token.ident, false);
        }
    }
};

/***
 *
 * @param {Date|string|null}date
 * @return {Date|null}
 */
DateInput2.prototype._normalizeValue = function (date) {
    var temp;
    if (date === null || date === undefined || date === false) {
        return null;
    }

    if (typeof date === 'string') {
        temp = new Date(date);
        if (isNaN(temp.getTime())) {
            temp = Object(datetime["parseDateTime"])(date, this._format);
        }
        date = temp;
    } else if (typeof date === 'number') {
        date = new Date(date);
    }
    if (date.getTime && date.getHours) {
        if (isNaN(date.getTime())) {
            return null;
        } else {
            return Object(datetime["beginOfDay"])(date);
        }
    } else {
        return null;
    }
};

DateInput2.prototype._loadValueFromInput = function () {
    var tkDict = this._makeTokenDict(this.$text.value);
    var y = tkDict.y ? tkDict.y.value : new Date().getFullYear();
    var m = tkDict.M ? tkDict.M.value - 1 : 0;
    var d = tkDict.d ? tkDict.d.value : 1;
    var date = new Date(y, m, d);
    if (isNaN(date.getTime())) {
        this._value = null;
    } else {
        this._value = date;
    }
    this._updateNullClass();
};

DateInput2.prototype._applyTokenDict = function (format, dict, debug) {
    var rgx = new RegExp(this.tokenRegex.source, 'g');
    var tokenMap = this.tokenMap;
    var res = format.replace(rgx, function (full, g1, g2, sourceText) {
        if (g1 && tokenMap[g1]) {
            var ident = tokenMap[g1];
            if (dict[ident] && !isNaN(dict[ident].value)) {
                return Object(utils["zeroPadding"])(dict[ident].value, g1.length);
            } else {
                return full;
            }
        } else
            return full;
    });
    return res;
};

DateInput2.prototype.focus = function () {
    this.$text.focus();
    this.$text.select();
};


DateInput2.prototype.tokenMap = {
    d: 'd',
    dd: 'd',
    M: 'M',
    MM: 'M',
    y: 'y',
    yyyy: 'y',
    ww: 'w'
}

/**
 * @type {DateInput2}
 */
DateInput2.eventHandler = {};


DateInput2.eventHandler.keydown = function (event) {
    var token = this._tokenAt(this.$text.selectionStart);
    var endToken = this._tokenAt(this.$text.selectionEnd);
    if (!token) {
        if (event.key === 'Enter') {
            this._correctingInput();
            this._loadValueFromInput();
            this._notifyIfChange(event);
        }
        return;
    }
    var newTokenText;
    var value;
    if (event.key.startsWith('Arrow') || event.key.match(/^[\-/,\s]$/)) {
        event.preventDefault();
        switch (event.key) {
            case 'ArrowLeft':
                this._editPrevToken();
                break;
            case 'ArrowRight':
            case '-':
            case ',':
            case '/':
            case ' ':
                this._editNextToken();
                break;
            case 'ArrowUp':
            case 'ArrowDown':
                switch (token.ident) {
                    case 'dd':
                    case 'd':
                        value = parseInt(token.text);
                        if (isNaN(value)) {
                            this._editingData.d = event.key === 'ArrowUp' ? 1 : 31;
                        } else {
                            this._editingData.d = 1 + (value + (event.key === 'ArrowUp' ? 0 : 29)) % 31;
                        }
                        newTokenText = '' + this._editingData.d;
                        while (newTokenText.length < token.ident.length) newTokenText = '0' + newTokenText;
                        token.replace(newTokenText, true);
                        break;
                    case 'w':
                    case 'ww':
                        value = parseInt(token.text);
                        if (isNaN(value)) {
                            this._editingData.w = event.key === 'ArrowUp' ? 1 : 54;
                        } else {
                            this._editingData.w = 1 + (value + (event.key === 'ArrowUp' ? 0 : 52)) % 54;
                        }
                        newTokenText = Object(utils["zeroPadding"])(this._editingData.w, token.ident.length);
                        token.replace(newTokenText, true);
                        break;
                    case 'MM':
                    case 'M':
                        value = parseInt(token.text) - 1;
                        if (isNaN(value)) {
                            this._editingData.M = event.key === 'ArrowUp' ? 0 : 11;
                        } else {
                            this._editingData.M = (value + (event.key === 'ArrowUp' ? 1 : 11)) % 12;
                        }
                        newTokenText = '' + (this._editingData.M + 1);
                        while (newTokenText.length < token.ident.length) newTokenText = '0' + newTokenText;
                        token.replace(newTokenText, true);
                        break;
                    case 'yyyy':
                        value = parseInt(token.text);
                        if (isNaN(value)) {
                            this._editingData.y = new Date().getFullYear();
                        } else {
                            this._editingData.y = Math.max(1890, Math.min(2089, value + (event.key === 'ArrowUp' ? 1 : -1)));
                        }

                        newTokenText = this._editingData.y + '';
                        while (newTokenText.length < token.ident.length) newTokenText = '0' + newTokenText;
                        token.replace(newTokenText, true);
                        break;

                }
        }
    } else if (event.key === "Delete" || event.key === 'Backspace') {
        event.preventDefault();
        if (endToken.idx !== token.idx) {
            if (this.notNull) {
                this.$text.value = Object(datetime["formatDateTime"])(new Date(Math.min(this.max.getTime(), Math.max(this.min.getTime(), new Date().getTime()))), this._format);
            } else {
                this.$text.value = this._format;
            }
            this.$text.select();
        } else {
            if (this.notNull) {
                switch (token.ident) {
                    case 'y':
                    case 'yyyy':
                        token.replace(Object(utils["zeroPadding"])(new Date().getFullYear(), token.ident.length), true);
                        break;
                    case 'w':
                    case 'ww':
                        token.replace(Object(utils["zeroPadding"])(1, token.ident.length), true);
                        break;
                    case 'M':
                    case 'MM':
                    case 'd':
                    case 'dd':
                        token.replace(Object(utils["zeroPadding"])(1, token.ident.length), true);
                        break;
                    default:
                        token.replace(token.ident, true);
                }
            } else {
                token.replace(token.ident, true);
            }
            if (event.key === "Delete") this._editNextToken();
            else this._editPrevToken();
        }
    } else if (event.key === "Enter" || event.key === 'Tab') {
        this._correctingInput();
        this._loadValueFromInput();
        this._notifyIfChange(event);
    } else if (event.ctrlKey) {
        switch (event.key) {
            case 'a':
            case 'A':
                break;
            case 'c':
            case 'C':
                break;
            case 'x':
            case 'X':
                this.domSignal.once('clear_value', function () {
                    this.$text.value = this._format;
                    this.$text.select();
                }.bind(this));
                this.domSignal.emit('clear_value');
                break;
            default:
                event.preventDefault();
        }
    } else if (event.key.match(/^[0-9]$/g)) {
        event.preventDefault();
        var dVal = parseInt(event.key);
        if (this._editingData.state === DateInput2_STATE_NEW) {
            switch (token.ident) {
                case 'dd':
                case 'd':
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editingData.state = DateInput2_STATE_EDITED;
                    this._editingData.d = dVal;
                    if (dVal > 3) {
                        this._editNextToken();
                    }
                    break;
                case 'w':
                case 'ww':
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editingData.state = DateInput2_STATE_EDITED;
                    this._editingData.d = dVal;
                    if (dVal > 6) {
                        this._editNextToken();
                    }
                    break;
                case 'MM':
                case 'M':
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editingData.state = DateInput2_STATE_EDITED;
                    this._editingData.M = dVal;
                    if (dVal > 1) {
                        this._editNextToken();
                    }
                    break;
                case 'yyyy':
                case 'y':
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editingData.state = DateInput2_STATE_EDITED;
                    this._editingData.state_num = 1;
                    break;
            }
        } else {
            switch (token.ident) {
                case 'dd':
                case 'd':
                    dVal = (parseInt(token.text.split('').pop()) || 0) * 10 + dVal;
                    dVal = Math.max(1, Math.min(31, dVal));
                    this._editingData.d = dVal;
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editNextToken();
                    break;
                case 'ww':
                case 'w':
                    dVal = (parseInt(token.text.split('').pop()) || 0) * 10 + dVal;
                    dVal = Math.max(1, Math.min(54, dVal));
                    this._editingData.d = dVal;
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editNextToken();
                    break;
                case 'MM':
                case 'M':
                    dVal = (parseInt(token.text.split('').pop()) || 0) * 10 + dVal;
                    dVal = Math.max(1, Math.min(12, dVal));
                    this._editingData.M = dVal - 1;
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editNextToken();
                    break;
                case 'yyyy':
                case 'y':
                    dVal = (parseInt(token.text.replace(/^./, '')) || 0) * 10 + dVal;
                    this._editingData.state_num++;
                    if (this._editingData.state_num >= 4) {
                        // dVal = Math.max(1890, Math.min(2089, dVal));
                        token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                        this._editNextToken();
                    } else {
                        token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    }
                    break;
            }
        }
    } else {
        event.preventDefault();
    }
};

DateInput2.eventHandler.mouseUpInput = js_DateTimeInput.eventHandler.mouseUpInput;

DateInput2.eventHandler.mouseDownInput = js_DateTimeInput.eventHandler.mouseDownInput;

DateInput2.eventHandler.dblclickInput = js_DateTimeInput.eventHandler.dblclickInput;
DateInput2.eventHandler.inputBlur = js_DateTimeInput.eventHandler.inputBlur;

DateInput2.eventHandler.calendarSelect = function (value) {
    this.value = value;
    this.notifyChange();
};

DateInput2.eventHandler.clickCalendarBtn = function () {
    this._attachCalendar();
};

DateInput2.eventHandler.clickOut = function (event) {
    if (Object(EventEmitter["d" /* hitElement */])(this.share.$calendar, event)) return;
    this._releaseCalendar();
};

DateInput2.eventHandler.calendarPick = function (event) {
    this._applyValue(event.value);
    this._notifyIfChange(event.originEvent || event);
    this._releaseCalendar();
};


DateInput2.property = {};

DateInput2.property.value = {
    set: function (value) {
        value = this._normalizeValue(value);
        if (!value && this.notNull) value = Object(datetime["beginOfDay"])(new Date());
        this._lastValue = value;
        this._applyValue(value);
    },
    get: function () {
        return this._value;
    }
};

/**
 * not support MMM, MMMM, support number only
 * @type {DateInput2}
 */
DateInput2.property.format = {
    set: function (value) {
        value = value || 'dd/MM/yyyy';
        value = value.replace(/m/g, 'M');
        value = value.replace(/MM([M]+)/, 'MM');
        if (!this._verifyFormat(value)) {
            value = 'dd/MM/yyyy';
            console.error("Invalid date format: " + value);
        }
        this._format = value;
        this._formatTokens = this._format.match(new RegExp(datetime["DATE_TIME_TOKEN_RGX"].source, 'g')) || [];
        this.value = this.value;//update
    },
    get: function () {
        return this._format;
    }
};

DateInput2.property.disabled = {
    set: function (value) {
        value = !!value;
        this.$input.disabled = value;
        if (value) this.addClass('as-disabled');
        else this.removeClass('as-disabled');
        this.$text.disabled = value;
    },
    get: function () {
        return this.$input.disabled;
    }
};

/***
 * @memberOf DateInput2
 * @name calendarLevel
 * @type {number}
 */
DateInput2.property.calendarLevel = {
    get: function () {
        if (this._formatTokens.indexOf('d') >= 0 || this._formatTokens.indexOf('dd') >= 0) return 'day';
        if (this._formatTokens.indexOf('w') >= 0 || this._formatTokens.indexOf('ww') >= 0) return 'week';
        if (this._formatTokens.indexOf('M') >= 0 || this._formatTokens.indexOf('MM') >= 0) return 'month';
        return 'year';
    }
};


DateInput2.property.min = {
    set: function (value) {
        this._min = this._normalizeValue(value) || new Date(1890, 0, 1);
    },
    get: function () {
        return this._min;
    }
};

DateInput2.property.max = {
    set: function (value) {
        this._max = this._normalizeValue(value) || new Date(2090, 0, 1);
    },
    get: function () {
        return this._max;
    }
};


DateInput2.property.notNull = {
    set: function (value) {
        if (value) {
            this.addClass('as-must-not-null');
            if (!this.value) this.value = new Date();
        } else {
            this.removeClass('as-must-not-null');
        }
    },
    get: function () {
        return this.containsClass('as-must-not-null');
    }
};


DateInput2.prototype.share = {
    /***
     * @type {ChromeCalendar}
     */
    $calendar: null,
    /***
     * @type {Follower}
     */
    $follower: null,
    /***
     * @type {DateInput2}
     */
    $holdingInput: null
};

DateInput2.prototype._prepareCalendar = function () {
    if (this.share.$calendar) return;

    this.share.$calendar = DateInput2_({
        tag: 'chromecalendar',
        class: 'as-date-input-calendar'
    });
    this.share.$follower = DateInput2_({
        tag: 'follower',
        class: 'as-date-input-follower',
        child: this.share.$calendar
    });
};

DateInput2.prototype._attachCalendar = function () {
    this._prepareCalendar();
    if (this.share.$holdingInput) this.share.$holdingInput._releaseCalendar();
    this.share.$follower.addTo(document.body);
    this.share.$follower.addStyle('visibility', 'hidden');
    this.share.$holdingInput = this;
    this.share.$follower.followTarget = this;
    this.share.$calendar.level = this.calendarLevel;
    this.share.$calendar.startDayOfWeek = this.startDayOfWeek || 0;
    this.share.$calendar.min = this._min;
    this.share.$calendar.max = this._max;
    this.share.$calendar.on('pick', this.eventHandler.calendarPick);
    this.share.$calendar.selectedDates = this.value ? [this.value] : [];
    this.share.$calendar.viewDate = this.value ? this.value
        : new Date(Math.max(this._min.getTime(), Math.min(this._max.getTime(), new Date().getTime())));
    setTimeout(function () {
        document.body.addEventListener('click', this.eventHandler.clickOut);
        this.share.$follower.removeStyle('visibility');
    }.bind(this), 5);
    this.$calendarBtn.off('click', this.eventHandler.clickCalendarBtn);
};

DateInput2.prototype._releaseCalendar = function () {
    if (this.share.$holdingInput !== this) return;
    this.share.$calendar.off('pick', this.eventHandler.calendarPick);
    this.share.$follower.remove();
    document.body.removeEventListener('click', this.eventHandler.clickOut);
    setTimeout(function () {
        this.$calendarBtn.on('click', this.eventHandler.clickCalendarBtn);
    }.bind(this), 5)
    this.share.$holdingInput = null;
};


ACore["d" /* default */].install(DateInput2);

/* harmony default export */ var js_DateInput2 = (DateInput2);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/draggablestack.css
var draggablestack = __webpack_require__(91);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Hanger.js
var Hanger = __webpack_require__(29);

// EXTERNAL MODULE: ./node_modules/absol/src/String/stringGenerate.js + 1 modules
var stringGenerate = __webpack_require__(12);

// EXTERNAL MODULE: ./node_modules/absol/src/Math/Vec2.js
var Vec2 = __webpack_require__(9);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/PositionTracker.js
var PositionTracker = __webpack_require__(50);

// EXTERNAL MODULE: ./node_modules/absol/src/Math/Rectangle.js
var Rectangle = __webpack_require__(18);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/DraggableVStack.js










var DraggableVStack_ = ACore["d" /* default */]._;
var DraggableVStack_$ = ACore["d" /* default */].$;


/***
 * @augments Hanger
 * @augments PositionTracker
 * @constructor
 */
function DraggableVStack() {
    DraggableVStack_({ tag: 'PositionTracker'.toLowerCase(), elt: this });
    this.$cloneContainer = DraggableVStack_('.absol-draggable-stack-clone-container');
    this.on('predrag', this.eventHandler.predrag)
        .on('dragstart', this.eventHandler.dragstart)
        .on('drag', this.eventHandler.drag)
        .on('dragend', this.eventHandler.dragend);
    this._state = 0;
    this.friends = [];
    this.$friends = [];
    this._privateDraggableVStackIdent = Object(stringGenerate["randomIdent"])(35);
    this._dragData = null;
    this.on('positionchange', this.eventHandler.scroll);
}


DraggableVStack.tag = 'DraggableVStack'.toLowerCase();

DraggableVStack.render = function () {
    return DraggableVStack_({
        tag: 'hanger',
        extendEvent: ['change', 'orderchange', 'itemleave', 'itementer'],
        class: ['absol-draggable-stack', 'absol-draggable-vstack']
    });
};

DraggableVStack.prototype._updateFriends = function () {
    var dict = {};
    dict[this._privateDraggableVStackIdent] = this;
    this.$friends = this.friends.reduce(function (ac, cr) {
        if (Dom["b" /* default */].isDomNode(cr)) {
            if (cr._privateDraggableVStackIdent) {
                ac.result.push(cr);
                ac.dict[cr._privateDraggableVStackIdent] = cr;
            }
        }
        else if (typeof cr === 'string') {
            DraggableVStack_$(cr, false, function (elt) {
                if (elt._privateDraggableVStackIdent) {
                    if (!ac.dict[elt._privateDraggableVStackIdent]) {
                        ac.result.push(elt);
                        ac.dict[elt._privateDraggableVStackIdent] = elt;
                    }
                }
            })
        }
        return ac;
    }, { dict: dict, result: [] }).result;
};

DraggableVStack.prototype._findIndex = function (clientY) {
    var childBounds = Array.prototype.map.call(this.childNodes, function (elt) {
        return elt.getBoundingClientRect()
    });
    var childTops = childBounds.map(function (b) {
        return b.top;
    });
    childTops.push((childBounds[childBounds.length - 1] || this.getBoundingClientRect()).bottom);
    var nearestIdx = 0;
    var nearestVal = 10000000;
    var val;
    for (var i = 0; i < childTops.length; ++i) {
        val = Math.abs(clientY - childTops[i]);
        if (val < nearestVal) {
            nearestVal = val;
            nearestIdx = i;
        }
    }
    return nearestIdx;
};

/***
 *
 * @type {DraggableVStack|{}}
 */
DraggableVStack.eventHandler = {};
DraggableVStack.eventHandler.predrag = function (event) {
    var dragzone = this._findDragzone(event.target);
    if (!dragzone) {
        event.cancel();
    }
};

DraggableVStack.eventHandler.dragstart = function (event) {
    this.startTrackPosition();
    event.preventDefault();
    this._updateFriends();
    this._state = 1;
    this.addClass('as-state-drag');

    this._dragData = {
        mouseStartPos: new Vec2["a" /* default */](event.clientX, event.clientY),
        elt: this._findDirectChild(event.target),
        rootBound: this.getBoundingClientRect(),
        dest: this
    };
    this._dragData.mouseCurrentPos = this._dragData.mouseStartPos;
    this._updateDestChildrenBound();
    this._dragData.idx = Array.prototype.indexOf.call(this.childNodes, this._dragData.elt);

    this._dragData.eltBound = this._dragData.destChildBounds[this._dragData.idx];
    this._dragData.offsetPos = this._dragData.mouseStartPos.sub(new Vec2["a" /* default */](this._dragData.eltBound.left, this._dragData.eltBound.top));
    this._dragData.eltRelative = new Vec2["a" /* default */](this._dragData.eltBound.left, this._dragData.eltBound.top).sub(new Vec2["a" /* default */](this._dragData.rootBound.left, this._dragData.rootBound.top));

    this.$cloneContainer.addTo(document.body);
    this.$cloneContainer.clearChild().addChild(DraggableVStack_$(this._dragData.elt.cloneNode(true)).addStyle({
        boxSizing: 'border-box',
        width: this._dragData.eltBound.width + 'px',
        height: this._dragData.eltBound.height + 'px'
    }));
    this.$cloneContainer.addStyle({
        left: this._dragData.eltBound.left + 'px',
        top: this._dragData.eltBound.top + 'px',
    });
    this._dragData.elt.addClass('dragging');
};


DraggableVStack.eventHandler.drag = function (event) {
    event.preventDefault();
    this._dragData.mouseCurrentPos = new Vec2["a" /* default */](event.clientX, event.clientY);
    this._updateHoverDest();
    this._updateDraggingPosition();
    this.eventHandler.dragOverflow(event);
};

DraggableVStack.prototype.getClientY = function () {
    var top = 1000000;
    var bottom = -10000000;
    var child;
    var childBound;
    for (var i = 0; i < this.childNodes.length; ++i) {
        child = this.childNodes[i];
        if (child === this.$cloneContainer) continue;
        if (child.getBoundingClientRect) {
            childBound = child.getBoundingClientRect();
            top = Math.min(top, childBound.top);
            bottom = Math.max(bottom, childBound.bottom);
        }
    }
    return { top: top, bottom: bottom };
};

DraggableVStack.eventHandler.dragOverflow = function (event) {
    var scroller = this;
    while (scroller) {
        var overflowStyle = window.getComputedStyle(scroller)['overflow'];
        if ((overflowStyle === 'auto' || overflowStyle === 'scroll' || scroller.tagName === 'HTML') && (scroller.clientHeight < scroller.scrollHeight)) break;
        scroller = scroller.parentElement;
    }
    if (!scroller) return;
    var outBound = scroller.getBoundingClientRect();
    var bBound = this.$cloneContainer.getBoundingClientRect();
    var screenSize = Dom["b" /* default */].getScreenSize();
    if (scroller.tagName !== "HTML") {
        outBound = {
            top: Math.max(outBound.top, 0),
            bottom: Math.min(outBound.bottom, screenSize.height)
        }
    }
    else {
        outBound = {
            top: 0,
            bottom: screenSize.height
        }
    }
    var vy = 0;
    if (bBound.top < outBound.top) {
        vy = bBound.top - outBound.top;
    }
    else if (bBound.bottom > outBound.bottom) {
        vy = bBound.bottom - outBound.bottom;
    }

    var dt = 1 / 30;
    if (vy !== 0) {
        var copyEvent = {
            type: event.type,
            preventDefault: function () {/* noop */
            },
            target: event.target
        };

        copyEvent.clientX = event.clientX;
        copyEvent.clientY = event.clientY

        var thisBT = this;

        setTimeout(function () {
            if (scroller.scrollHeight > scroller.clientHeight) {
                scroller.scrollTop += Object(utils["absCeil"])(vy * dt);
            }

            if (thisBT._state === 1) {
                thisBT.eventHandler.dragOverflow(copyEvent);
            }
        }, dt * 1000);
    }
};


DraggableVStack.eventHandler.scroll = function (event) {
    this._updateDraggingPosition();
};

DraggableVStack.eventHandler.dragend = function (event) {
    this.stopTrackPosition();
    event.preventDefault();
    this._dragData.dest.removeClass('as-state-drag');
    this.$cloneContainer.remove();
    this._dragData.elt.removeClass('dragging');
    this.removeClass('as-state-no-change');
    this._state = 0;
    var beforeElt;
    if (this._dragData.dest === this) {
        if (this._dragData.idx === this._dragData.destIdx || (this._dragData.idx + 1 === this._dragData.destIdx)) {
            //todo
        }
        else {
            if (this._dragData.destIdx === this.childNodes.length) {
                this._dragData.elt.remove();
                this.addChild(this._dragData.elt);
                this.emit('change', {
                    type: 'change',
                    fromStack: this,
                    toStack: this,
                    elt: this._dragData.elt,
                    sourceIndex: this._dragData.idx,
                    destIndex: this.childNodes.length,
                    oldIdx: this._dragData.idx,
                    newIdx: this.childNodes.length - 1,
                    desc: "Move element to end of stack."
                }, this);
                this.emit('orderchange', {
                    type: 'orderchange',
                    fromStack: this,
                    toStack: this,
                    elt: this._dragData.elt,
                    oldIdx: this._dragData.idx,
                    newIdx: this.childNodes.length - 1,
                    desc: "Move element to end of stack."
                }, this);
            }
            else {
                beforeElt = this.childNodes[this._dragData.destIdx];
                this._dragData.elt.remove();
                this.addChildBefore(this._dragData.elt, beforeElt);
                this.emit('change', {
                    type: 'change',
                    fromStack: this,
                    toStack: this,
                    elt: this._dragData.elt,
                    sourceIndex: this._dragData.idx,
                    destIndex: this._dragData.destIdx,
                    oldIdx: this._dragData.idx,
                    newIdx: this._dragData.destIdx > this._dragData.idx ? this._dragData.destIdx - 1 : this._dragData.destIdx,
                    desc: "Move element to before  this.childNodes[" + this._dragData.destIdx + "]"
                }, this);
                this.emit('orderchange', {
                    type: 'orderchange',
                    fromStack: this,
                    toStack: this,
                    elt: this._dragData.elt,
                    oldIdx: this._dragData.idx,
                    newIdx: this._dragData.destIdx > this._dragData.idx ? this._dragData.destIdx - 1 : this._dragData.destIdx,
                    desc: "Move element to before  this.childNodes[" + this._dragData.destIdx + "]"
                }, this);
            }
        }
    }
    else {
        if (this._dragData.destIdx === this._dragData.dest.childNodes.length) {
            this.emit('orderchange', {
                type: 'itemleave',
                fromStack: this,
                toStack: this._dragData.dest,
                oldIdx: this._dragData.idx,
                newIdx: this.childNodes.length - 1,
                desc: "Move element to end of friend stack."
            }, this);
            this._dragData.elt.remove();
            this._dragData.dest.addChild(this._dragData.elt);
            this._dragData.dest.emit('orderchange', {
                type: 'itementer',
                fromStack: this,
                toStack: this._dragData.dest,
                oldIdx: this._dragData.idx,
                newIdx: this.childNodes.length - 1,
                desc: "Move element to end of friend stack."
            }, this._dragData.dest);
            this.emit('change', {
                type: 'change',
                fromStack: this,
                toStack: this._dragData.dest,
                elt: this._dragData.elt,
                sourceIndex: this._dragData.idx,
                destIndex: this.childNodes.length,
                oldIdx: this._dragData.idx,
                newIdx: this.childNodes.length - 1,
                desc: "Move element to end of friend stack."
            });
        }
        else {
            beforeElt = this._dragData.dest.childNodes[this._dragData.destIdx];
            this._dragData.elt.remove();
            this.emit('itemleave', {
                type: 'itemleave',
                fromStack: this,
                toStack: this._dragData.dest,
                elt: this._dragData.elt,
                oldIdx: this._dragData.idx,
                newIdx: this._dragData.destIdx,
                desc: "Move element to before friend.childNodes[" + this._dragData.destIdx + "]"
            }, this);
            this._dragData.dest.addChildBefore(this._dragData.elt, beforeElt);
            this._dragData.dest.emit('itementer', {
                type: 'itementer',
                fromStack: this,
                toStack: this._dragData.dest,
                elt: this._dragData.elt,
                oldIdx: this._dragData.idx,
                newIdx: this._dragData.destIdx,
                desc: "Move element to before friend.childNodes[" + this._dragData.destIdx + "]"
            }, this._dragData.dest);
            this.emit('change', {
                type: 'change',
                fromStack: this,
                toStack: this._dragData.dest,
                elt: this._dragData.elt,
                sourceIndex: this._dragData.idx,
                destIndex: this._dragData.destIdx,
                oldIdx: this._dragData.idx,
                newIdx: this._dragData.destIdx,
                desc: "Move element to before friend.childNodes[" + this._dragData.destIdx + "]"
            }, this);
        }
    }
};


DraggableVStack.prototype._updateDestChildrenBound = function () {

    var top0 = this._dragData.dest.getBoundingClientRect().top;
    this._dragData.destChildBounds = Array.prototype.map.call(this._dragData.dest.childNodes, function (elt) {
        return elt.getBoundingClientRect()
    });
    this._dragData.destChildTops = this._dragData.destChildBounds.map(function (bound) {
        return bound.top - top0;
    }).concat([(this._dragData.destChildBounds[this._dragData.destChildBounds.length - 1] || this.getBoundingClientRect()).bottom - top0]);
}



DraggableVStack.prototype._updateHoverDest = function () {
    var bound;
    var newDest;
    var friendElt;
    var friendList = this.$friends.concat([this]);
    var top0;
    for (var i = 0; i < friendList.length; ++i) {
        friendElt = friendList[i];
        bound = Rectangle["a" /* default */].fromClientRect(friendElt.getBoundingClientRect());
        if (bound.containsPoint(this._dragData.mouseCurrentPos)) {
            top0 = bound.y;
            newDest = friendElt;
            break;
        }
    }

    if (newDest && this._dragData.dest !== newDest) {
        this._dragData.dest.removeClass('as-state-drag');
        this._dragData.dest = newDest;
        this._dragData.dest.addClass('as-state-drag');
        this._dragData.dest.addStyle('--dest-y', 'unset');
        this._updateDestChildrenBound();
    }
};

DraggableVStack.prototype._updateDraggingPosition = function () {
    var bound = this.getBoundingClientRect();
    var clonePos = this._dragData.mouseCurrentPos.sub(this._dragData.offsetPos);

    this.$cloneContainer.addStyle({
        top: clonePos.y + 'px',
        left: bound.left + 'px'
    });

    this._dragData.destIdx = this._dragData.dest._findIndex(clonePos.y + this._dragData.eltBound.height / 2);
    this._dragData.dest.addStyle('--dest-y', this._dragData.destChildTops[this._dragData.destIdx] + 'px');
    if (this._dragData.dest === this) {
        if (this._dragData.idx === this._dragData.destIdx || (this._dragData.idx + 1 === this._dragData.destIdx)) {
            this.addClass('as-state-no-change');
        }
        else {
            this.removeClass('as-state-no-change');
        }
    }
};


DraggableVStack.prototype._autoScrollParentIfNeed = function (delta) {
    //todo: choose which element should be scroll
    if (!(delta > 0)) delta = 10000;
    var bound = this.getBoundingClientRect();
    var cloneBound = this.$cloneContainer.getBoundingClientRect();
    var outBound = Dom["b" /* default */].traceOutBoundingClientRect(this.$cloneContainer);
    if (outBound.bottom >= cloneBound.bottom && outBound.top <= cloneBound.top) return;
    var scrollables = [];
    var current = this;

    while (current) {
        var oy = window.getComputedStyle(current);
        oy = oy['overflow-y'] || oy['overflowY'];

        if (oy == 'auto' || oy == 'scroll') {
            scrollables.push(current);
        }
        current = current.parentElement;
    }
    scrollables.push(document.body.parentElement);

};

DraggableVStack.prototype._findDragzone = function (elt) {
    var result = null;
    while (elt && elt != this) {
        if (elt.classList && elt.classList.contains('drag-zone')) {
            result = elt;
            break;
        }
        elt = elt.parentNode;
    }

    if (result) {
        elt = result;
        while (elt && elt != this) {
            if (elt.classList && (elt.classList.contains('absol-draggable-stack'))) {
                result = null;
                break;
            }
            elt = elt.parentNode;
        }
    }

    return result;
};

DraggableVStack.prototype._findDirectChild = function (elt) {
    while (elt && elt != this) {
        if (elt.parentNode == this) return elt;
        elt = elt.parentNode;
    }
    return undefined;
};

DraggableVStack.property = {};

DraggableVStack.property.friends = {
    set: function (value) {
        if (!(value instanceof Array)) value = [value];
        this._friends = value;
    },
    get: function () {
        return this._friends;
    }
};

ACore["d" /* default */].install(DraggableVStack);

/* harmony default export */ var js_DraggableVStack = (DraggableVStack);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/DraggableHStack.js







var DraggableHStack_ = ACore["d" /* default */]._;
var DraggableHStack_$ = ACore["d" /* default */].$;

/***
 * @augments DraggableVStack
 * @augments PositionTracker
 * @constructor
 */
function DraggableHStack() {
    this._dragData = null;
    this.$cloneContainer = DraggableHStack_('.absol-draggable-stack-clone-container');
    this.on('predrag', this.eventHandler.predrag)
        .on('dragstart', this.eventHandler.dragstart)
        .on('drag', this.eventHandler.drag)
        .on('dragend', this.eventHandler.dragend);
    DraggableHStack_({ elt: this, tag: PositionTracker["a" /* default */] })
        .on('positionchange', this._updateDraggingPosition.bind(this));
}


DraggableHStack.tag = "DraggableHStack".toLowerCase();
DraggableHStack.render = function () {
    return DraggableHStack_({
        tag: 'hanger',
        extendEvent: 'change',
        class: ['absol-draggable-stack', 'absol-draggable-hstack']
    });
};

/***
 *
 * @param {Rectangle} rect
 * @returns {number}
 * @private
 */
DraggableHStack.prototype._findDropIdx = function (rect) {
    if (!this._dragData) return -1;
    var centerX = rect.x + rect.width / 2;
    var currentBound = Rectangle["a" /* default */].fromClientRect(this.getBoundingClientRect());
    var nearestDistance = Math.abs(centerX - currentBound.width);//end of stack
    var cDist;
    var nearestIndex = this._dragData.childBounds.length;
    var childX;
    for (var i = 0; i < this._dragData.childBounds.length; ++i) {
        childX = this._dragData.childBounds[i].x + currentBound.x - this._dragData.bound.x;
        cDist = Math.abs(centerX - childX);
        if (cDist < nearestDistance) {
            nearestDistance = cDist;
            nearestIndex = i;
        }
    }
    return nearestIndex;
};

/***
 *
 * @type {DraggableHStack|{}}
 */
DraggableHStack.eventHandler = {};

DraggableHStack.eventHandler.predrag = js_DraggableVStack.eventHandler.predrag;

DraggableHStack.eventHandler.dragstart = function (event) {
    this.addClass('as-has-dragging');
    this.startTrackPosition();
    var mousePos = new Vec2["a" /* default */](event.clientX, event.clientY);
    var elt = this._findDirectChild(event.target);
    var childBounds = Array.prototype.map.call(this.childNodes, function (e) {
        return Rectangle["a" /* default */].fromClientRect(e.getBoundingClientRect());
    });
    var eltIdx = Array.prototype.indexOf.call(this.childNodes, elt);
    var eltBound = childBounds[eltIdx];
    var eltMouseOffset = mousePos.sub(new Vec2["a" /* default */](eltBound.x, eltBound.y));


    this._dragData = {
        mouseStartPos: mousePos,
        mousePos: mousePos,
        bound: Rectangle["a" /* default */].fromClientRect(this.getBoundingClientRect()),
        childBounds: childBounds,
        elt: elt,
        eltIdx: eltIdx,
        eltBound: eltBound,
        eltMouseOffset: eltMouseOffset
    };

    this.$cloneContainer.addStyle({
        left: eltBound.x + 'px',
        top: eltBound.y + 'px',
        width: eltBound.width + 'px',
        height: eltBound.height + 'px',
    }).clearChild()
        .addChild(DraggableHStack_$(elt.cloneNode(true)))
        .addTo(document.body);
    elt.addClass('as-dragging');
    this._updateDraggingPosition();
};


DraggableHStack.eventHandler.drag = function (event) {
    event.preventDefault();
    this._dragData.mousePos = new Vec2["a" /* default */](event.clientX, event.clientY);
    this._updateDraggingPosition();
};


DraggableHStack.eventHandler.dragend = function (event) {
    var thisS = this;
    this.stopTrackPosition();
    this.removeClass('as-has-dragging');
    this._dragData.elt.removeClass('as-dragging');
    if (this._dragData.destIdx == this._dragData.eltIdx || this._dragData.destIdx == this._dragData.eltIdx + 1) {
        this.$cloneContainer.addClass('as-home-going');
        this._updateDraggingPosition();
        setTimeout(function () {
            thisS.$cloneContainer.selfRemove()
                .removeClass('as-home-going');
        }, 100);
    }
    else {
        if (this._dragData.destIdx === this._dragData.childBounds.length) {
            this._dragData.elt.remove();
            this.addChild(this._dragData.elt);
            this.emit('change', {
                type: 'change',
                elt: this._dragData.elt,
                sourceIndex: this._dragData.eltIdx,
                destIndex: this._dragData.childBounds.length,
                oldIdx: this._dragData.eltIdx,
                newIdx: this._dragData.childBounds.length - 1,
                desc: "Move element to end of stack."
            }, this);
        }
        else {
            var beforeElt = this.childNodes[this._dragData.destIdx];
            this._dragData.elt.remove();
            this.addChildBefore(this._dragData.elt, beforeElt);
            this.emit('change', {
                type: 'change',
                elt: this._dragData.elt,
                sourceIndex: this._dragData.eltIdx,
                destIndex: this._dragData.destIdx,
                oldIdx: this._dragData.eltIdx,
                newIdx: this._dragData.destIdx > this._dragData.eltIdx ? this._dragData.destIdx - 1 : this._dragData.destIdx,
                desc: "Move element to before  this.childNodes[" + this._dragData.destIdx + "]"
            }, this);
        }
        this.$cloneContainer.selfRemove()
            .removeClass('as-home-going');
    }

    this.removeClass('as-no-change');
};


DraggableHStack.prototype._findDragzone = js_DraggableVStack.prototype._findDragzone;
DraggableHStack.prototype._findDirectChild = js_DraggableVStack.prototype._findDirectChild;


DraggableHStack.prototype._updateDraggingPosition = function () {
    var bound = this.getBoundingClientRect();
    var x, y;
    if (this.$cloneContainer.containsClass('as-home-going')) {
        x = this._dragData.eltBound.x - this._dragData.bound.x + bound.left;
        y = this._dragData.eltBound.y - this._dragData.bound.y + bound.top;
    }
    else {
        y = bound.top + (this._dragData.eltBound.y - this._dragData.bound.y);
        var newPos = this._dragData.mousePos.sub(this._dragData.eltMouseOffset);
        x = newPos.x;
    }
    this.$cloneContainer.addStyle({
        left: x + 'px',
        top: y + 'px'
    });
    var cBound = this._dragData.eltBound.clone();
    cBound.x = x;
    cBound.y = y;
    var destIdx = this._findDropIdx(cBound);
    this._dragData.destIdx = destIdx;
    var destX;
    if (destIdx >= this._dragData.childBounds.length) {
        var lastRect = this._dragData.childBounds[this._dragData.childBounds.length - 1];
        destX = lastRect.x + lastRect.width - this._dragData.bound.x;
    }
    else {
        destX = this._dragData.childBounds[destIdx].x - this._dragData.bound.x;
    }
    this.addStyle('--dest-x', destX + 'px');
    if (destIdx == this._dragData.eltIdx || destIdx == this._dragData.eltIdx + 1) {
        this.addClass('as-no-change');
    }
    else {
        this.removeClass('as-no-change');
    }
};


ACore["d" /* default */].install(DraggableHStack);
/* harmony default export */ var js_DraggableHStack = (DraggableHStack);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/droppanel.css
var droppanel = __webpack_require__(92);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/ExpTree.js
var ExpTree = __webpack_require__(22);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/DropPanel.js








var DropPanel_ = ACore["d" /* default */]._;
var DropPanel_$ = ACore["d" /* default */].$;

/**
 * @extends AElement
 * @constructor
 */
function DropPanel() {
    var thisDP = this;
    /***
     *
     * @type {ExpGroup}
     */
    this.$body = DropPanel_$('.absol-drop-panel-body', this);
    this.$head = DropPanel_$('.absol-drop-panel-head', this)
        .on('click', thisDP.eventHandler.clickHead);

    this.$name = DropPanel_$('.absol-drop-panel-name', thisDP);
    OOP["a" /* default */].drillProperty(this, this.$name, 'name', 'innerHTML');
    return thisDP;
}

DropPanel.tag = 'DropPanel'.toLowerCase();

DropPanel.render = function () {
    return DropPanel_({
        class: 'absol-drop-panel',
        extendEvent: ['toggle'],
        child: [
            {
                class: 'absol-drop-panel-head',
                child: [
                    'toggler-ico',
                    {
                        tag: 'span',
                        class: "absol-drop-panel-name"
                    }
                ]

            },
            {
                tag:'expgroup',
                class: ['absol-drop-panel-body', 'absol-bscroller']
            }
        ]
    });
};


DropPanel.eventHandler = {};
DropPanel.eventHandler.clickHead = function (event) {
    if (!this._childOfButton(event.target)) {
        var event = {
            target: this, isShowed: this.show, preventDefault: function () {
                this.prevented = true;
            }
        };
        this.emit('toggle', event, this);
        if (!event.prevented) {
            this.toggle();
        }
    }
};

['findChildBefore', 'findChildAfter', 'removeChild', 'clearChild', 'addChild']
    .forEach(function (key) {
        DropPanel.prototype[key] = function () {
            this.$body[key].apply(this.$body, arguments);
        }
    });

DropPanel.prototype._childOfButton = function (elt) {
    while (elt && elt != this) {
        if (elt.tagName == "BUTTON") {
            return true;
        }
        elt = elt.parentElement
    }
    return false;
};

DropPanel.prototype.toggle = function () {
    this.show = !this.show;
};

DropPanel.property = {};

DropPanel.property.show = {
    set: function (value) {
        if (value) {
            var maxHeight = parseFloat(this.getComputedStyleValue('max-height').replace('px', ''));
            var headBound = this.$head.getBoundingClientRect();
            if (maxHeight != 'none' && maxHeight != 'auto') {
                this.$body.addStyle('max-height', maxHeight - headBound.height + 'px');
            }
            this.$body.addStyle('height', this.$body.scrollHeight + 'px');
            setTimeout(function () {
                this.$body.removeStyle('height');
                window.dispatchEvent(new Event('resize'));
            }.bind(this), 200);

            this.addClass('show');
        }
        else {
            this.$body.addStyle('height', this.$body.scrollHeight + 'px');
            setTimeout(function () {
                this.$body.addStyle('height', '0');
            }.bind(this), 0);
            setTimeout(function () {
                this.$body.removeStyle('height');
                window.dispatchEvent(new Event('resize'));
            }.bind(this), 200);
            this.removeClass('show');
        }
    },
    get: function () {
        return this.containsClass('show');
    }
};


ACore["d" /* default */].install(DropPanel);

/* harmony default export */ var js_DropPanel = (DropPanel);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/DropPanelStack.js





var DropPanelStack_ = ACore["d" /* default */]._;
var DropPanelStack_$ = ACore["d" /* default */].$;

/**
 * @extends AElement
 * @constructor
 */
function DropPanelStack() {
    var res = this;
    this.$attachHook = DropPanelStack_('attachhook').on('error', function () {
        Dom["b" /* default */].addToResizeSystem(this);
        this.updateSize = res.updateSize.bind(res);
    });
    this.sync = new Promise(function (rs) {
        res.$attachHook.once('error', rs);
    });
}

DropPanelStack.tag = 'DropPanelStack'.toLowerCase();

DropPanelStack.render = function () {
    return DropPanelStack_({
        class: 'absol-drop-panel-stack',
        child: ['attachhook']
    });
};

DropPanelStack.prototype.updateSize = function () {
};

DropPanelStack.prototype.getFreeHeight = function () {
    var childNodes = this.childNodes;
    var sumHeight = 0;
    var bound = this.getBoundingClientRect();
    var childBound;
    for (var i = 0; i < childNodes.length; ++i) {
        var child = childNodes[i];
        if (child.containsClass && child.containsClass('absol-drop-panel')) {
            childBound = child.getBoundingClientRect();
            sumHeight += childBound.height;
        }
    }
    return bound.height - sumHeight;
};


DropPanelStack.prototype.addChild = function (child) {
    var self = this;
    if (child.containsClass('absol-drop-panel')) {
        //remove last event listener off other parent
        if (child.__drop_panel_toggle_listener__) {
            child.off('toggle', child.__drop_panel_toggle_listener__);
        }
        child.__drop_panel_toggle_listener__ = function (event) {
            event.preventDefault();
            self.sync = self.sync.then(function () {
                if (event.isShowed) {
                    setTimeout(function () {
                        child.removeStyle('max-height');
                    }, 200);
                    child.toggle();
                }
                else {
                    var headBound = child.$head.getBoundingClientRect();
                    var vailableHeight = self.getFreeHeight();
                    if (vailableHeight > 3) {
                        child.addStyle('max-height', self.getFreeHeight() + headBound.height + 'px');
                        child.toggle();
                    }
                }

                return new Promise(function (rs) {
                    setTimeout(rs, 200);
                });
            })
        };
        child.on('toggle', child.__drop_panel_toggle_listener__);
        this.super(child);
    }
    else {
        throw new Error('Child element must be a DropPanel');
    }
};

ACore["d" /* default */].install('droppanelstack', DropPanelStack);

/* harmony default export */ var js_DropPanelStack = (DropPanelStack);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/editabletext.css
var editabletext = __webpack_require__(152);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/EditableText.js






var EditableText_ = ACore["d" /* default */]._;
var EditableText_$ = ACore["d" /* default */].$;

/***
 * @extends AElement
 * @constructor
 */
function EditableText() {
    var thisET = this;
    this.$span = EditableText_$('span', this);
    this.$text = document.createTextNode('');
    this.$span.addChild(this.$text);

    this.$higne = EditableText_$('.absol-editabe-text-higne', this);
    this.$input = EditableText_$('input', this);

    OOP["a" /* default */].drillProperty(this, this.$input, ['selectionStart', 'selectionEnd']);
    this.sync = new Promise(function (rs) {
        EditableText_('attachhook').addTo(thisET).once('error', rs);
    });

    this.$input.on('keydown', this.eventHandler.inputKeyDown, true);
    this.$input.on('change', this.eventHandler.inputChange);
    this.$input.on('blur', this.eventHandler.inputBlur);
};

EditableText.tag = 'EditableText'.toLowerCase();

EditableText.render = function () {
    return EditableText_({
        class: 'absol-editabe-text',
        extendEvent: ['blur', 'focus', 'change', 'modify'],
        child: [
            {
                class: 'absol-editabe-text-higne',
                child: '<input type="text">'
            },
            'span'
        ]
    });
};


EditableText.prototype.focus = function () {
    this.$input.focus();
};
EditableText.prototype.blur = function () {
    this.$input.blur();
};

EditableText.prototype.select = function () {
    this.$input.select();
};

EditableText.prototype.edit = function (flag, select) {
    this.editing = !!flag;
    this.sync = this.sync.then(function () {
        if (flag) {
            this.focus();
            if (select) this.select();
        }
        else
            this.blur();
    }.bind(this));
    return this.sync;
}

EditableText.prototype._update = function () {
    this.sync = this.sync.then(function () {
        return new Promise(function (rs) {
            // setTimeout(function () {
            var bound = this.getBoundingClientRect();
            var higneBound = this.$higne.getBoundingClientRect();
            var fsize = this.getFontSize();
            this.$input.addStyle('width', bound.width + 4 + fsize * 0 + 'px');
            this.$input.addStyle('height', bound.height + 4 + 'px');
            this.$input.addStyle('left', bound.left - higneBound.left - 2 + 'px');
            this.$input.addStyle('top', bound.top - higneBound.top + 'px');
            rs();
        }.bind(this));
    }.bind(this));
}

EditableText.property = {};

EditableText.property.text = {
    set: function (value) {
        this.$text.textContent = value;
        this.$input.value = value;
    },

    get: function () {
        return this.$text.textContent;
    }
}


EditableText.property.editing = {
    set: function (value) {
        if (this._editting === value) return;
        this._editting = !!value;
        if (value) {
            this.$input.value = this.text;
            this._update();
            this.sync = this.sync.then(function () {
                this.addClass('editing');
                this.$input.value = this.text;
                this.$input.addStyle('font', this.$span.getComputedStyleValue('font'));
                this.$input.addStyle('font-style', this.$span.getComputedStyleValue('font-style'));
                this.$input.addStyle('color', this.$span.getComputedStyleValue('color'));
            }.bind(this));

        }
        else {
            this.removeClass('editing');
        }
    },
    get: function () {
        return !!this._editting;
    }
};


EditableText.eventHandler = {};

EditableText.eventHandler.inputKeyDown = function (event) {
    requestAnimationFrame(function () {
        this.text = this.$input.value;
        this._update();
        event.text = this.text;
        this.emit('modify', event);
    }.bind(this));
};


EditableText.eventHandler.inputChange = function (event) {
    this.editing = false;
    this.emit('change', event);
};

EditableText.eventHandler.inputBlur = function (event) {
    this.editing = false;
    this.emit('blur', event);
};

ACore["d" /* default */].install(EditableText);

/* harmony default export */ var js_EditableText = (EditableText);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/EmojiPicker.js
var EmojiPicker = __webpack_require__(38);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Sprite.js
var Sprite = __webpack_require__(86);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/flexiconbutton.css
var flexiconbutton = __webpack_require__(156);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/FlexiconButton.js




var FlexiconButton_ = ACore["d" /* default */]._;
var FlexiconButton_$ = ACore["d" /* default */].$;

/**
 * @extends AElement
 * @constructor
 */
function FlexiconButton() {
    this._icon = null;
    this.$content = FlexiconButton_$('.as-flexicon-button-content', this);
    this.$iconCtn = FlexiconButton_$('.as-flexicon-button-icon-container', this);
    this.$textCtn = FlexiconButton_$('.as-flexicon-button-text-container', this);
}

FlexiconButton.tag = 'FlexiconButton'.toLowerCase();

FlexiconButton.render = function () {
    return FlexiconButton_({
        tag: 'button',
        class: 'as-flexicon-button',
        child: {
            class: 'as-icon-button-table-box',
            child: {
                class: 'as-flexicon-button-content',
                child: [
                    '.as-flexicon-button-icon-container',
                    '.as-flexicon-button-text-container',
                ]
            }
        }
    });
};

FlexiconButton.property = {};

FlexiconButton.property.icon = {
    set: function (value) {
        value = value || null;
        this._icon = value;
        this.$iconCtn.clearChild();
        if (value !== null) {
            this.$iconCtn.addChild(FlexiconButton_(value));
        }
    },
    get: function () {
        return this._icon;
    }
};

FlexiconButton.property.text = {
    set: function (value) {
        value = value || null;
        this._text = value;
        this.$textCtn.clearChild();
        if (value !== null) {
            this.$textCtn.addChild(FlexiconButton_({ text: value }));
        }
    },
    get: function () {
        return this._text;
    }
};


ACore["d" /* default */].install(FlexiconButton);


/* harmony default export */ var js_FlexiconButton = (FlexiconButton);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/flexiconinput.css
var flexiconinput = __webpack_require__(158);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/FlexiconInput.js





var FlexiconInput_ = ACore["d" /* default */]._;
var FlexiconInput_$ = ACore["d" /* default */].$;


/***
 * @extends AElement
 * @constructor
 */
function FlexiconInput() {
    this.$input = FlexiconInput_$('.as-flexicon-input-text-input', this);
    this.$iconCtn = FlexiconInput_$('.as-flexicon-input-icon-ctn', this);
    this.$unitCtn = FlexiconInput_$('.as-flexicon-input-unit-ctn', this);
    OOP["a" /* default */].drillProperty(this, this.$input, ['value', 'readonly']);
    this.on('click', function (event) {
        if (event.target != this.$input)
            this.$input.focus();
    }.bind(this));
}

FlexiconInput.prototype.on = function () {
    return this.$input.on.apply(this.$input, arguments);
};

FlexiconInput.prototype.once = function () {
    return this.$input.once.apply(this.$input, arguments);
};

FlexiconInput.prototype.off = function () {
    return this.$input.off.apply(this.$input, arguments);
};

FlexiconInput.tag = 'FlexiconInput'.toLowerCase();
FlexiconInput.render = function () {
    return FlexiconInput_({
        class: 'as-flexicon-input',
        child: [
            {
                class: 'as-flexicon-input-icon-ctn'
            },
            {
                tag: 'input',
                class: 'as-flexicon-input-text-input',
                attr: { type: 'text' },

            },
            {
                class: 'as-flexicon-input-unit-ctn'
            }
        ]
    });
};


FlexiconInput.property = {};

FlexiconInput.property.icon = {
    set: function (value) {
        value = value || null;
        this._icon = value;
        this.$iconCtn.clearChild();
        if (value == null) {
            this.removeClass('as-flexicon-input-has-icon');
        }
        else {
            this.addClass('as-flexicon-input-has-icon');
            this.$iconCtn.addChild(FlexiconInput_(value));
        }
    },
    get: function () {
        return this._icon;
    }
};

FlexiconInput.property.unit = {
    set: function (value) {
        this._unit = value;
        if (this._unit) {
            this.addClass('as-flexicon-input-has-unit');
            this.$unitCtn.clearChild().addChild(FlexiconInput_({ text: value + '' }));
        }
        else {
            this.removeClass('as-flexicon-input-has-unit');
            this.$unitCtn.clearChild();
        }
    },
    get: function () {
        return this._unit;
    }
};

FlexiconInput.property.disabled = {
    set: function (value) {
        value = !!value;
        this.$input.disabled = value;
        if (value) {
            this.addClass('as-disabled');
        }
        else {
            this.removeClass('as-disabled');
        }
    },
    get: function () {
        return this.$input.disabled;
    }
};

ACore["d" /* default */].install(FlexiconInput);

/* harmony default export */ var js_FlexiconInput = (FlexiconInput);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/frame.css
var css_frame = __webpack_require__(160);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/Frame.js





var Frame_ = ACore["d" /* default */]._;
var Frame_$ = ACore["d" /* default */].$;

/***
 * @extends AElement
 * @constructor
 */
function Frame() {
    this.$parent = null;// FrameView or TabView
}

Frame.tag = 'frame';

Frame.render = function () {
    return Frame_({
        class: 'absol-frame',
        attr: {
            id: Object(stringGenerate["randomIdent"])(12),
        },
        extendEvent: ['attached', 'detached', 'deactive', 'active']// deactive and active event will be send by parent
    });
};


Frame.prototype.notifyAttached = function (parentElt) {
    this.$parent = parentElt;
    this.emit('attached', { type: 'attached', target: this, parentElt: parentElt }, this);
};

Frame.prototype.notifyDetached = function () {
    this.emit('detached', { type: 'detached', target: this, parentElt: this.$parent }, this);
    this.$parent = undefined;
};


Frame.prototype.selfRemove = function () {
    if (this.$parent)
        this.$parent.removeChild(this);
    else
        this.super();// normal remove
};

Frame.prototype.getParent = function () {
    return this.$parent;
};


Frame.prototype.requestActive = function () {
    if (this.$parent) {
        this.$parent.activeFrame(this);
    }
};

ACore["d" /* default */].install(Frame);

/* harmony default export */ var js_Frame = (Frame);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/frameview.css
var frameview = __webpack_require__(162);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/FrameView.js






var FrameView_ = ACore["d" /* default */]._;
var FrameView_$ = ACore["d" /* default */].$;


/***
 * @extends AElement
 * @constructor
 */
function FrameView() {
    this.$containers = [];
}

FrameView.tag = 'frameview';

FrameView.render = function () {
    return FrameView_({
        class: 'absol-frame-view',
        extendEvent: ['activeframe', 'deactiveframe']

    });
};

FrameView.prototype.addChild = function (elt) {
    if (elt.containsClass && elt.containsClass('absol-frame')) {
        elt.selfRemove();
        var containerElt = FrameView_({
            class: 'absol-frame-view-frame-container',
            child: elt,
            props: {
                __elt__: elt
            }
        });
        this.$containers.push(containerElt);
        this.appendChild(containerElt);
        elt.notifyAttached(this);
    }
    else {
        throw new Error('Children must be a frame');
    }
};


FrameView.prototype.addLast = function (elt) {
    this.addChild(elt);
    this.activeFrame(elt);
};


FrameView.prototype.removeLast = function () {
    if (this.$containers.length > 0) {
        this.removeChild(this.$containers[this.$containers.length - 1].__elt__);
    }

    if (this.$containers.length > 0) {
        this.activeFrame(this.$containers[this.$containers.length - 1].__elt__);
    }
};


FrameView.prototype.getLength = function () {
    return this.$containers.length;
};


FrameView.prototype.getAllChild = function () {
    return this.$containers.map(function (ctn) {
        return ctn.__elt__;
    });
};


FrameView.prototype.getLast = function () {
    if (this.$containers.length > 0) {
        return (this.$containers[this.$containers.length - 1].__elt__);
    }

    return null;
};

FrameView.prototype.addChildBefore = function (elt, at) {
    if (elt.containsClass && elt.containsClass('absol-frame')) {
        elt.selfRemove();
        var index = this.childIndexOf(at);
        if (index < 0) {
            throw new Error('Second param is not a child');
        }
        var index = this.childIndexOf(at);
        var atCtnElt = this.$containers[index];
        var containerElt = FrameView_({
            class: 'absol-frame-view-frame-container',
            child: elt,
            props: {
                __elt__: elt
            }
        });
        this.$containers.splice(index, 0, containerElt);
        this.super(containerElt, atCtnElt);
        elt.notifyAttached(this);
    }
    else {
        throw new Error('Children must be a frame');
    }
};


FrameView.prototype.addChildAfter = function (elt, at) {
    if (elt.containsClass && elt.containsClass('absol-frame')) {
        elt.selfRemove();
        var index = this.childIndexOf(at);
        if (index < 0) {
            throw new Error('Second param is not a child');
        }
        var index = this.childIndexOf(at);
        var atCtnElt = this.$containers[index];
        var containerElt = FrameView_({
            class: 'absol-frame-view-frame-container',
            child: elt,
            props: {
                __elt__: elt
            }
        });
        this.$containers.splice(index + 1, 0, containerElt);
        this.super(containerElt, atCtnElt);
        elt.notifyAttached(this);
    }
    else {
        throw new Error('Children must be a frame');
    }
};

FrameView.prototype.removeChild = function (elt) {
    var ctnEltIndex = this.childIndexOf(elt)
    if (ctnEltIndex >= 0) {
        var ctnElt = this.$containers[ctnEltIndex];
        this.$containers.splice(ctnEltIndex, 1);
        this.super(ctnElt);
    }
    else {
        throw new Error('Removed element is not a child!');
    }
};


FrameView.prototype.childIndexOf = function (elt) {
    for (var i = 0; i < this.$containers.length; ++i) {
        if (this.$containers[i].__elt__ == elt) return i;
    }
    return -1;
};


FrameView.prototype.findChildBefore = function (elt) {
    var eltIndex = this.childIndexOf(elt);
    if (eltIndex < 0) return -1;
    return this.$containers[eltIndex - 1];
};


FrameView.prototype.findChildAfter = function (elt) {
    var eltIndex = this.childIndexOf(elt);
    if (eltIndex < 0) return -1;
    return this.$containers[eltIndex + 1];
};


FrameView.prototype.clearChild = function () {
    while (this.$containers.length > 0) {
        this.removeChild(this.$containers[0].__elt__);
    }
    return this;
};


FrameView.prototype.findChildById = function (id) {
    var elt;
    for (var i = 0; i < this.$containers.length; ++i) {
        elt = this.$containers[i].__elt__;
        if (elt.getAttribute('id') == id) return elt;
    }
    return undefined;
};

FrameView.prototype.getAllChild = function () {
    return this.$containers.map(function (ctnElt) {
        return ctnElt.__elt__;
    });
};

FrameView.prototype.activeFrame = function (frameElt) {
    var ctnElt, elt;
    for (var i = 0; i < this.$containers.length; ++i) {
        ctnElt = this.$containers[i];
        elt = ctnElt.__elt__;
        if (frameElt == elt) {
            if (!ctnElt.containsClass('absol-active')) {
                ctnElt.addClass('absol-active');
                this.notifyActiveFrame(elt);
            }
            // else do nothing
        }
        else {
            if (ctnElt.containsClass('absol-active')) {
                ctnElt.removeClass('absol-active');
                this.notifyDeactiveFrame(elt);
            }
            // else do nonthing
        }
    }
    return this;
};


FrameView.prototype.notifyActiveFrame = function (frameElt, originEvent) {
    frameElt.emit('active', { target: frameElt, type: 'active', originEvent: originEvent });
    this.emit('activeframe', { type: 'activeframe', target: this, frameElt: frameElt, originEvent: originEvent }, this);
};

FrameView.prototype.notifyDeactiveFrame = function (frameElt, originEvent) {
    this.emit('deactiveframe', {
        type: 'deactiveframe',
        target: this,
        frameElt: frameElt,
        originEvent: originEvent
    }, this);
};

FrameView.prototype.activeFrameById = function (id) {
    var frameElt = this.findChildById(id);
    if (frameElt)
        this.activeFrame(frameElt);
    return this;
};


ACore["d" /* default */].install('frameview', FrameView);

/* harmony default export */ var js_FrameView = (FrameView);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TabFrame.js


var TabFrame_$ = ACore["d" /* default */].$;
var TabFrame_ = ACore["d" /* default */]._;

function TabFrame() {

}

TabFrame.tag = 'tabframe';
TabFrame.render = function () {
    return TabFrame_({
        tag: 'frame',
        class: 'absol-tab-frame',
        extendEvent: ['requestremove', 'remove']
    }, true);
}

TabFrame.property = {};

TabFrame.property.name = {
    set: function (value) {

        if (typeof name == "undefined") {
            this._name = undefined;
        }
        else {
            this._name = value + '';
        }
        if (this.$parent) {
            if (this.$parent.notifyUpdateName)
                this.$parent.notifyUpdateName(this);
        }
    },
    get: function () {
        return this._name;
    }
};


TabFrame.property.modified = {
    set: function (value) {
        this._modified = !!value;
        if (this.$parent) {
            if (this.$parent.notifyUpdateModified)
                this.$parent.notifyUpdateModified(this);
        }
    },
    get: function () {
        return !!this._modified;
    }
};


TabFrame.property.desc = {
    set: function (value) {
        if (typeof value == "undefined") {
            this._desc = undefined;
        }
        else {
            this._desc = value + '';
        }
        if (this.$parent) {
            if (this.$parent.notifyUpdateDesc)
                this.$parent.notifyUpdateDesc(this);
        }

    },
    get: function () {
        return this._desc;
    }
}

TabFrame.attribute = {};

TabFrame.attribute.name = {
    set: function (value) {
        this.name = value;
    },
    get: function () {
        return this.name;
    },
    remove: function () {
        this.name = undefined;
    }
};


TabFrame.attribute.desc = {
    set: function (value) {
        this.desc = value;
    },
    get: function () {
        return this.desc;
    },
    remove: function () {
        this.desc = undefined;
    }
};

TabFrame.attribute.modified = {
    set: function (value) {
        this.modified = value == 'true' || value == '1' || value === true;
    },
    get: function () {
        return this.modified ? 'true' : undefined;
    },
    remove: function () {
        this.desc = false;
    }
};


TabFrame.prototype.requestRemove = function () {
    if (this.$parent && this.$parent.removeTab) {
        this.$parent.removeTab(this.id, false);
    }
    else {
        this.selfRemove();
    }
};

ACore["d" /* default */].install(TabFrame);
/* harmony default export */ var js_TabFrame = (TabFrame);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/TabView.js + 2 modules
var TabView = __webpack_require__(82);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/singlepage.css
var singlepage = __webpack_require__(165);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/ResizeSystem.js
var ResizeSystem = __webpack_require__(11);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/SinglePage.js






var SinglePage_ = ACore["d" /* default */]._;
var SinglePage_$ = ACore["d" /* default */].$;

var warned = false;

/***
 * @extends AElement
 * @constructor
 */
function SinglePage() {
    var thisSP = this;
    this._updateIntv = -1;
    this._tick = function () {
        if (this.isDescendantOf(document.body)) {
            if (this.$header) {
                var headerHeight = this.$header.getBoundingClientRect().height;
                if (this._prevHeaderHeight !== headerHeight) {
                    ResizeSystem["a" /* default */].update();
                }
            }
        }
        else {
            clearInterval(this._updateIntv);
            this._updateIntv = -1;
        }
    }.bind(this);
    this.$attachhook = SinglePage_$('attachhook', this)
        .on('attached', function () {
            this.updateSize();
            setTimeout(this.updateSize, 20);
            Dom["b" /* default */].addToResizeSystem(this);
            if (thisSP._updateIntv < 0) {
                thisSP._updateIntv = setInterval(thisSP._tick, 200);
            }

        });
    this.$attachhook.updateSize = this.updateSize.bind(this);
    this.$header = null;
    this.$footer = null;
    this.$viewport = SinglePage_$('.absol-single-page-scroller-viewport', this);
    this.$scroller = SinglePage_$('.absol-single-page-scroller', this);
}

SinglePage.tag = 'SinglePage'.toLowerCase();

SinglePage.render = function () {
    return SinglePage_({
        tag: 'tabframe',
        extendEvent: ['sizechange'],
        class: 'absol-single-page',
        child: [{
            class: 'absol-single-page-scroller',
            child: { class: 'absol-single-page-scroller-viewport' }
        },
            'attachhook']
    });
};


SinglePage.prototype.updateSize = function () {
    if (!this.isDescendantOf(document.body)) return;
    var paddingTop = parseFloat(this.getComputedStyleValue('padding-top').replace('px', '')) || 0;

    if (this.$header) {
        var headerBound = this.$header.getBoundingClientRect();
        var headerMarginTop = parseFloat(this.$header.getComputedStyleValue('margin-top').replace('px', '')) || 0;
        var headerMarginBottom = parseFloat(this.$header.getComputedStyleValue('margin-bottom').replace('px', '')) || 0;
        this.$scroller.addStyle('top', (headerBound.height + headerMarginTop + headerMarginBottom + paddingTop) + 'px');
        this._prevHeaderHeight = headerBound.height;
    }
    if (this.$footer) {
        var footerBound = this.$footer.getBoundingClientRect();
        this.$viewport.addStyle('padding-bottom', footerBound.height + 'px');
    }
    if (this.isSupportedEvent('sizechange'))
        this.emit('sizechange', { type: 'sizechange', target: this }, this);
    this.addStyle('--single-page-scroller-height', this.$scroller.clientHeight + 'px');
};

SinglePage.prototype.addChild = function (elt) {
    if (elt.classList.contains('absol-single-page-header')) {
        if (this.firstChild) {
            this.addChildBefore(elt, this.firstChild);
        }
        else {
            this.appendChild(elt);
        }
        this.$header = SinglePage_$(elt);
        this.updateSize();
    }
    else if (elt.classList.contains('absol-single-page-footer')) {
        this.$viewport.addChild(elt);
        this.$footer = SinglePage_$(elt);
        this.updateSize();
    }
    else {
        this.$viewport.addChild(elt);
    }
};

SinglePage.prototype.removeChild = function (elt) {
    if (elt == this.$footer) {
        this.$viewport.removeChild(elt);
        this.$footer = undefined;
        this.updateSize();
    }
    else if (elt == this.$header) {
        this.super(elt);
        this.$header = undefined;
        this.updateSize();
    }
    else {
        this.$viewport.removeChild(elt);
    }
};


ACore["d" /* default */].install(SinglePage);

/* harmony default export */ var js_SinglePage = (SinglePage);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/hexasectionlabel.css
var hexasectionlabel = __webpack_require__(167);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/HexaSectionLabel.js






var HexaSectionLabel_ = ACore["d" /* default */]._;
var HexaSectionLabel_$ = ACore["d" /* default */].$;

var HexaSectionLabel_g = Svg["a" /* default */].ShareInstance._;
var HexaSectionLabel_$g = Svg["a" /* default */].ShareInstance.$;


var HexaSectionLabel_Design = {
    hexaHeight: 425,
    textBoxHeight: 286,
    textHeight: 96,
    indexHeight: 110,
    textBoxPaddingLeft: 127,
    borderWidth: 38
};

var HexaSectionLabel_StyleSheet = {
    '.as-hexa-section-label-text': {
        height: HexaSectionLabel_Design.textBoxHeight / HexaSectionLabel_Design.textHeight + 'em',
        'padding-left': HexaSectionLabel_Design.textBoxPaddingLeft / HexaSectionLabel_Design.textHeight + 'em',
        'line-height': HexaSectionLabel_Design.textBoxHeight / HexaSectionLabel_Design.textHeight + 'em'
    },
    '.as-hexa-section-label-index': {
        'font-size': HexaSectionLabel_Design.indexHeight / HexaSectionLabel_Design.textHeight + 'em',
        height: HexaSectionLabel_Design.hexaHeight / HexaSectionLabel_Design.indexHeight + 'em',
        'line-height': HexaSectionLabel_Design.hexaHeight / HexaSectionLabel_Design.indexHeight + 'em',
        width: ((HexaSectionLabel_Design.hexaHeight + HexaSectionLabel_Design.borderWidth) / Math.cos(Math.PI / 6)) / HexaSectionLabel_Design.indexHeight + 'em'
    },

};

HexaSectionLabel_({
    tag: 'style',
    id: 'hexa-section-label-style',
    props: {
        innerHTML: Object.keys(HexaSectionLabel_StyleSheet).map(function (key) {
            var style = HexaSectionLabel_StyleSheet[key];
            return key + ' {\n'
                + Object.keys(style).map(function (propName) {
                    return propName + ': ' + style[propName] + ';';
                }).join('\n')
                + '}';
        }).join('\n')
    }
}).addTo(document.head);

/***
 * @extends AElement
 * @constructor
 */
function HexaSectionLabel() {
    this.$background = HexaSectionLabel_$('.as-hexa-section-label-background', this);
    this.$index = HexaSectionLabel_$('.as-hexa-section-label-index', this);
    this.$text = HexaSectionLabel_$('.as-hexa-section-label-text', this);
    this.$attachhook = HexaSectionLabel_('attachhook').addTo(this).on('error', function () {
        Dom["b" /* default */].addToResizeSystem(this);
        this.requestUpdateSize();
    });

    this.$attachhook.requestUpdateSize = this.redrawBackground.bind(this);
    this.$svg = HexaSectionLabel_g({
        tag: 'svg',
        attr: {
            width: '0',
            height: '0'
        },
        child: [
            'path.as-hexa-section-label-text-box',
            'path.as-hexa-section-label-index-box'
        ]
    }).addTo(this.$background);
    this.$indexBox = HexaSectionLabel_$g('path.as-hexa-section-label-index-box', this.$svg);
    this.$textBox = HexaSectionLabel_$g('path.as-hexa-section-label-text-box', this.$svg);
}

HexaSectionLabel.prototype.redrawBackground = function () {
    var indexBound = this.$index.getBoundingClientRect();
    var textBound = this.$text.getBoundingClientRect();
    var cHeight = indexBound.height;
    var cWidth = textBound.right - indexBound.left;
    this.$svg.attr({
        height: cHeight + '',
        width: cWidth + '',
        viewBox: [0, 0, cWidth, cHeight].join(' ')
    });

    var borderWidth = cHeight * HexaSectionLabel_Design.borderWidth / HexaSectionLabel_Design.hexaHeight;
    var radius = (cHeight / Math.cos(Math.PI / 6) / 2) - borderWidth / 2;
    var x0 = indexBound.width / 2;
    var y0 = cHeight / 2;


    this.$indexBox.attr('d', Array(6).fill(0).map(function (u, i) {
        var angle = Math.PI / 3 + i * Math.PI / 3;
        var x = radius * Math.cos(angle) + x0;
        var y = radius * Math.sin(angle) + y0;
        return (i == 0 ? 'M' : 'L') + x + ' ' + y;
    }).join(' ') + 'Z')
        .addStyle({
            strokeWidth: borderWidth + ''
        });
    var skewX = 18 / 45;
    var textBoxHeight = textBound.height;
    this.$textBox.attr('d', [
        [x0, (cHeight - textBoxHeight) / 2],
        [cWidth - 1, (cHeight - textBoxHeight) / 2],
        [cWidth - 1 - textBoxHeight * skewX, (cHeight - textBoxHeight) / 2 + textBoxHeight],
        [x0, (cHeight - textBoxHeight) / 2 + textBoxHeight],
    ].map(function (point, i) {
        return (i == 0 ? 'M' : 'L') + point.join(' ')
    }).join(' ') + 'Z')
};

HexaSectionLabel.tag = 'HexaSectionLabel'.toLowerCase();

HexaSectionLabel.render = function () {
    return HexaSectionLabel_({
        class: 'as-hexa-section-label',
        child: [
            {
                class: 'as-hexa-section-label-background'
            },
            '.as-hexa-section-label-index',
            '.as-hexa-section-label-text'
        ]
    });
};

HexaSectionLabel.property = {};
HexaSectionLabel.property.index = {
    set: function (value) {
        this._index = value;
        this.$index.clearChild().addChild(HexaSectionLabel_({ text: value + '' }))
    },
    get: function () {
        return this._index;
    }
};

HexaSectionLabel.property.text = {
    set: function (value) {
        this._text = value;
        this.$text.clearChild().addChild(HexaSectionLabel_({ text: value + '' }))
    },
    get: function () {
        return this._text;
    }
};


ACore["d" /* default */].install(HexaSectionLabel);
/* harmony default export */ var js_HexaSectionLabel = (HexaSectionLabel);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/vruler.css
var vruler = __webpack_require__(169);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/VRuler.js





var VRuler_ = ACore["d" /* default */]._;
var VRuler_$ = ACore["d" /* default */].$;


function VRuler() {
    var self = this;
    this.$attachHook = VRuler_('attachhook').on('error', function () {
        this.updateSize = self.update.bind(self);
        Dom["b" /* default */].addToResizeSystem(this);
        this.updateSize();
    }).addTo(this);

    this.$lines = [];
    this.$numbers = [];
    this.$measureTarget = undefined;
    this._viewingNumberCount = 0;
    this._viewingLineCount = 0;
    this._spacing = 10;
    this._major = 10;
    this._valueFloat = 'top';
}

VRuler.tag = 'vruler';

VRuler.render = function () {
    return VRuler_({
        class: 'as-vruler'
    });
};

VRuler.prototype.measureElement = function (elt) {
    if (typeof elt == "string") elt = VRuler_$(elt);
    this.$measureTarget = elt;
    this.update();
};


VRuler.prototype.update = function () {
    var fontSize = this.getFontSize();
    var measureBound;
    var bound = this.getBoundingClientRect();
    var contentBound = {
        left: bound.left + 1,
        right: bound.right - 1,
        top: bound.top + 1,
        bottom: bound.bottom - 1,
        width: bound.width - 2,
        height: bound.height - 2
    };
    if (this.$measureTarget) {
        measureBound = this.$measureTarget.getBoundingClientRect();
    }
    else {
        measureBound = contentBound;
    }

    var startOfset = (measureBound[this._valueFloat] - contentBound[this._valueFloat]) * (this.inverse ? -1 : 1) % this._spacing;
    if (startOfset < 0) startOfset += this._spacing;


    var lineIndexOfset = Math.round(((contentBound[this._valueFloat] - measureBound[this._valueFloat]) * (this.inverse ? -1 : 1) + startOfset) / this._spacing);

    var lineCount = Math.floor((contentBound.height - startOfset) / this._spacing) + 1;

    while (this.$lines.length < lineCount) {
        this.$lines.push(VRuler_('.as-vruler-line'));
    }
    var i;
    var lineElt;
    for (i = 0; i < lineCount; ++i) {
        lineElt = this.$lines[i];
        if ((i + lineIndexOfset) % this._major == 0) {
            lineElt.addClass('major');
        }
        else {
            lineElt.removeClass('major');
        }
        lineElt.addStyle(this._valueFloat, startOfset + this._spacing * i - 0.5 + 'px');
    }

    while (this._viewingLineCount < lineCount) {
        this.$lines[this._viewingLineCount++].addTo(this);
    }

    while (this._viewingLineCount > lineCount) {
        this.$lines[--this._viewingLineCount].remove();
    }

    var numberCount = Math.floor((lineCount + lineIndexOfset - 1) / this._major) - Math.ceil(lineIndexOfset / this._major) + 1;

    while (this.$numbers.length < numberCount) {
        this.$numbers.push(VRuler_('.as-vruler-major-number'));
    }
    var numberElt;
    var number;
    var majorStartOfset = startOfset;
    if (lineIndexOfset > 0) {
        majorStartOfset += (this._major - lineIndexOfset % this._spacing) * this._spacing;
    }
    else {
        majorStartOfset += (this._major - (this._spacing + lineIndexOfset % this._spacing)) * this._spacing;
    }

    for (i = 0; i < numberCount; ++i) {
        number = (Math.ceil(lineIndexOfset / this._major) + i) * this._spacing * this._major;
        numberElt = this.$numbers[i];
        if (numberElt.__cacheNumber__ != number) {
            numberElt.__cacheNumber__ = number;
            numberElt.innerHTML = number + '';
        }
        numberElt.addStyle(this._valueFloat, majorStartOfset + this._major * i * this._spacing - 0.7 * 0.5 * fontSize + 'px')
    }

    while (this._viewingNumberCount < numberCount) {
        this.$numbers[this._viewingNumberCount++].addTo(this);
    }

    while (this._viewingNumberCount > numberCount) {
        this.$numbers[--this._viewingNumberCount].remove();
    }
};


VRuler.property = {};
VRuler.property.major = {
    set: function (value) {
        if (value > 0) {
            this._major = value;
            this.update();
        }
    },
    get: function () {
        return this._major;
    }
};

VRuler.property.spacing = {
    set: function (value) {
        if (value > 0) {
            this._spacing = value;
            this.update();
        }
    },
    get: function () {
        return this._spacing;
    }
};


VRuler.property.inverse = {
    set: function (value) {
        this._valueFloat = value ? 'bottom' : 'top';
        this.update();
    },
    get: function () {
        return this._valueFloat == 'bottom';
    }
};

ACore["d" /* default */].install('vruler', VRuler);

/* harmony default export */ var js_VRuler = (VRuler);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/hruler.css
var hruler = __webpack_require__(171);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/HRuler.js





var HRuler_ = ACore["d" /* default */]._;
var HRuler_$ = ACore["d" /* default */].$;

/***
 * @extends AElement
 * @constructor
 */
function HRuler() {
    var self = this;
    this.$attachHook = HRuler_('attachhook').on('error', function () {
        this.updateSize = self.update.bind(self);
        Dom["b" /* default */].addToResizeSystem(this);
        this.updateSize();
    }).addTo(self);

    this.$lines = [];
    this.$numbers = [];
    this._viewingNumberCount = 0;
    this._viewingLineCount = 0;
    this._spacing = 10;
    this._major = 10;
    this.$measureTarget = null;
    this._valueFloat = 'left';
}

HRuler.tag = 'hruler';

HRuler.render = function () {
    return HRuler_({
        class: 'as-hruler'
    });
};


HRuler.prototype.measureElement = function (elt) {
    if (typeof elt == "string") elt = HRuler_$(elt);
    this.$measureTarget = elt;
    this.update();
};


HRuler.prototype.update = function () {
    var fontSize = this.getFontSize();
    var measureBound;
    var bound = this.getBoundingClientRect();

    var contentBound = {
        left: bound.left + 1,
        right: bound.right - 1,
        top: bound.top + 1,
        bottom: bound.bottom - 1,
        width: bound.width - 2,
        height: bound.height - 2
    };
    if (this.$measureTarget) {
        measureBound = this.$measureTarget.getBoundingClientRect();
    }
    else {
        measureBound = contentBound;
    }


    var startOfset = (measureBound[this._valueFloat] - contentBound[this._valueFloat]) * (this.inverse ? -1 : 1) % this._spacing;
    if (startOfset < 0) startOfset += this._spacing;


    var lineIndexOfset = Math.round(((contentBound[this._valueFloat] - measureBound[this._valueFloat]) * (this.inverse ? -1 : 1) + startOfset) / this._spacing);

    var lineCount = Math.floor((contentBound.width - startOfset) / this._spacing) + 1;

    while (this.$lines.length < lineCount) {
        this.$lines.push(HRuler_('.as-hruler-line'));
    }

    var i;
    var lineElt;
    for (i = 0; i < lineCount; ++i) {
        lineElt = this.$lines[i];
        if ((i + lineIndexOfset) % this._major == 0) {
            lineElt.addClass('major');
        }
        else {
            lineElt.removeClass('major');
        }
        lineElt.addStyle(this._valueFloat, startOfset + this._spacing * i - 0.5 + 'px');
    }

    while (this._viewingLineCount < lineCount) {
        this.$lines[this._viewingLineCount++].addTo(this);
    }

    while (this._viewingLineCount > lineCount) {
        this.$lines[--this._viewingLineCount].remove();
    }

    var numberCount = Math.floor((lineCount + lineIndexOfset - 1) / this._major) - Math.ceil(lineIndexOfset / this._major) + 1;

    while (this.$numbers.length < numberCount) {
        this.$numbers.push(HRuler_('.as-hruler-major-number'));
    }
    var numberElt;
    var number;
    var majorStartOfset = startOfset;
    if (lineIndexOfset > 0) {
        majorStartOfset += (this._major - lineIndexOfset % this._spacing) * this._spacing;
    }
    else {
        majorStartOfset += (this._major - (this._spacing + lineIndexOfset % this._spacing)) * this._spacing;

    }


    for (i = 0; i < numberCount; ++i) {
        number = (Math.ceil(lineIndexOfset / this._major) + i) * this._spacing * this._major;
        numberElt = this.$numbers[i];
        if (numberElt.__cacheNumber__ != number) {
            numberElt.__cacheNumber__ = number;
            numberElt.innerHTML = number + '';
        }
        numberElt.addStyle(this._valueFloat, majorStartOfset + this._major * i * this._spacing - 0.7 * 2.5 * fontSize + 'px')
    }

    while (this._viewingNumberCount < numberCount) {
        this.$numbers[this._viewingNumberCount++].addTo(this);
    }

    while (this._viewingNumberCount > numberCount) {
        this.$numbers[--this._viewingNumberCount].remove();
    }
};


HRuler.property = {};
HRuler.property.major = {
    set: function (value) {
        if (value > 0) {
            this._major = value;
            this.update();
        }
    },
    get: function () {
        return this._major;
    }
};

HRuler.property.spacing = {
    set: function (value) {
        if (value > 0) {
            this._spacing = value;
            this.update();
        }
    },
    get: function () {
        return this._spacing;
    }
};

HRuler.property.inverse = {
    set: function (value) {
        this._valueFloat = value ? 'right' : 'left';
        this.update();
    },
    get: function () {
        return this._valueFloat == 'right';
    }
};

ACore["d" /* default */].install(HRuler);

/* harmony default export */ var js_HRuler = (HRuler);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/IconSprite.js



var IconSprite_ = ACore["d" /* default */]._;
var IconSprite_$ = ACore["d" /* default */].$;


function IconSprite() {
    this.$attachhook = IconSprite_('attachhook').addTo(this).on('error', this.eventHandler.attached);
    this.on('frame', this.eventHandler.frame);
    this._checkRootTimeout = 30;
    this.loop = true;
}

IconSprite.tag = 'iconsprite';


IconSprite.render = function () {
    return IconSprite_('sprite', true);
};


/**
 * @type {IconSprite}
 */
IconSprite.eventHandler = {};

IconSprite.eventHandler.attached = function () {
    var thisAS = this;
    this._checkRootTimeout = 30;
    this.afterReady().then(function () {
        thisAS.width = thisAS.texture.naturalWidth;
        thisAS.height = thisAS.width;
        thisAS.frames = {
            type: 'grid',
            col: 1,
            row: thisAS.texture.naturalHeight / thisAS.texture.naturalWidth
        }
        thisAS.drawFrame(0);
        thisAS.play();
    });
};

IconSprite.eventHandler.frame = function () {
    this._checkRootTimeout--;
    if (this._checkRootTimeout == 0){
        if (this.isDescendantOf(document.body)){
            this._checkRootTimeout = 30;
        }
        else{
            this.stop();
            this.remove();
        }
    }
};

ACore["d" /* default */].install(IconSprite);

/* harmony default export */ var js_IconSprite = (IconSprite);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/linearcolorbar.css
var linearcolorbar = __webpack_require__(173);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/LinearColorBar.js






var LinearColorBar_ = ACore["d" /* default */]._;
var LinearColorBar_$ = ACore["d" /* default */].$;


var LinearColorBar_g = Svg["a" /* default */].ShareInstance._;
var LinearColorBar_$g = Svg["a" /* default */].ShareInstance.$;

var LinearColorBar_Design = {
    textHeight: 56,
    barHeight: 97,
    barBlockWidth: 79,
    barBlockMargin: 19,
    valueTextHeight: 70,
    valueStrokeWidth: 5,
    valueHeight: 99,
    valueWidth: 52,
    valueTripHeight: 32,
    height: 430,
    barY: 201
};

var SyleSheet = {
    '.as-linear-color-bar': {
        height: LinearColorBar_Design.height / LinearColorBar_Design.textHeight + 'em'
    },
    '.as-linear-color-value-text': {
        'font-size': LinearColorBar_Design.valueTextHeight / LinearColorBar_Design.textHeight + 'em'
    }
};


Object(utils["buildCss"])(SyleSheet);

function LinearColorBar() {
    this._indent = (Math.random() + '').replace(/[^0-9]/g, '_');
    this._extendValue = 0;
    this._value = 0;
    this._valueText = '';
    this.$valueText = LinearColorBar_$('.as-linear-color-value-text', this);
    this.$minValueText = LinearColorBar_$('.as-linear-color-min-value-text', this);
    this.$maxValueText = LinearColorBar_$('.as-linear-color-max-value-text', this);
    this.$background = LinearColorBar_$('svg.as-linear-color-background', this);
    this._attached = false;
    var thisBar = this;
    this.$attachhook = LinearColorBar_('attachhook').addTo(this).on('error', function () {
        thisBar._attached = true;
        Dom["b" /* default */].addToResizeSystem(this);
        this.requestUpdateSize();
    });

    this.$background.attr({
        height: 0,
        width: 0,
    });
    this.$attachhook.requestUpdateSize = this.redraw.bind(this);
    this.$defs = LinearColorBar_g('defs').addTo(this.$background);

    this.$gradient = LinearColorBar_g('linearGradient#gradient_' + this._indent)
        .attr({
            x1: "0%",
            y1: "0%",
            x2: "100%",
            y2: "0%"
        }).addTo(this.$defs);
    this.$rect = LinearColorBar_g('rect.as-linear-color-bar-rect')
        .attr({
            fill: 'url(#gradient_' + this._indent + ')'
        })
        .addTo(this.$background);
    this.$splitLine = LinearColorBar_g('path.as-linear-color-split-line').addTo(this.$background)
    this.$valueArrow = LinearColorBar_g('path.as-linear-color-value-arrow').addTo(this.$background);

    this.colorMapping = 'rainbow';
}

LinearColorBar.prototype.redraw = function () {
    var bBound = this.getBoundingClientRect();
    var cWidth = bBound.width;
    var cHeight = bBound.height;
    var maxTextBound = this.$maxValueText.getBoundingClientRect();
    var minTextBound = this.$minValueText.getBoundingClientRect();
    var valueTextBound = this.$valueText.getBoundingClientRect();

    var valueWidth = LinearColorBar_Design.valueWidth / LinearColorBar_Design.height * cHeight;
    var minValueX = valueWidth / 1.5;
    this.$minValueText.addStyle('left', Math.max((minValueX - minTextBound.width) / 2, 0) + 'px');

    var maxValueX = (cWidth - LinearColorBar_Design.valueWidth) / (1 + this._extendValue);
    var extendX = cWidth - valueWidth / 1.5;
    var valueX = minValueX + this._value * (maxValueX - minValueX);
    this.$valueText.addStyle('left', valueX - valueTextBound.width / 2 + 'px');
    this.$maxValueText.addStyle('left', maxValueX - maxTextBound.width / 2 + 'px');
    var barY = LinearColorBar_Design.barY / LinearColorBar_Design.height * cHeight;
    var barHeight = LinearColorBar_Design.barHeight / LinearColorBar_Design.height * cHeight;
    this.$rect.attr({
        x: '' + minValueX,
        y: '' + barY,
        width: extendX - minValueX + '',
        height: barHeight
    });

    this.$background.attr({
        height: cHeight + '',
        width: cWidth + '',
        viewBox: [0, 0, cWidth, cHeight].join(' ')
    });

    var valueTripHeight = LinearColorBar_Design.valueTripHeight / LinearColorBar_Design.height * cHeight;
    var valueHeight = LinearColorBar_Design.valueHeight / LinearColorBar_Design.height * cHeight;
    this.$valueArrow
        .addStyle('stroke-width', LinearColorBar_Design.valueStrokeWidth / LinearColorBar_Design.height * cHeight + '')
        .attr('d', [
            [
                [valueX, barY],
                [valueX - valueWidth / 2, barY - valueTripHeight],
                [valueX - valueWidth / 2, barY - valueHeight],
                [valueX + valueWidth / 2, barY - valueHeight],
                [valueX + valueWidth / 2, barY - valueTripHeight]

            ]
        ].map(function (point, i) {
            return (i == 0 ? 'M' : 'L') + point.join(' ')
        }).join(' ') + 'Z');

    var splitDistMin = (LinearColorBar_Design.barBlockWidth + LinearColorBar_Design.barBlockMargin) / LinearColorBar_Design.height * cHeight;
    var splitCounts = [100, 50, 20, 10, 5, 2, 1];
    var splitDist = maxValueX - minValueX;
    var splitCount = 1;
    for (var i = 0; i < splitCounts.length; ++i) {
        splitDist = (maxValueX - minValueX) / splitCounts[i];
        if (splitDist >= splitDistMin) {
            splitCount = splitCounts[i];
            break;
        }
    }

    this.$splitLine.addStyle('stroke-width', LinearColorBar_Design.barBlockMargin / LinearColorBar_Design.height * cHeight + '')
        .attr({
            d: Array(splitCount + 1).fill(0).map(function (u, i) {
                return 'M' + (maxValueX - i * splitDist) + ' ' + (barY - 1) + 'v' + (barHeight + 2);
            }).join(' ')
        })
};

LinearColorBar.prototype._updateGradient = function () {
    var barMax = 1 + this._extendValue;
    var gradientElt = this.$gradient.clearChild();
    this._colorMapping.forEach(function (it) {
        LinearColorBar_g({
            tag: 'stop',
            attr: {
                offset: (it.value <= 1 ? it.value / barMax * 100 : 100) + '%'
            },
            style: {
                'stop-color': it.color + '',
                'stop-opacity': '1'
            }
        }).addTo(gradientElt);
    });
};


LinearColorBar.prototype.BUILDIN_COLORS_RANGE = {
    'rainbow': [
        { value: 0, color: 'red' },
        { value: 1 / 6, color: 'orange' },
        { value: 1 / 3, color: 'yellow' },
        { value: 1 / 2, color: 'green' },
        { value: 2 / 3, color: 'blue' },
        { value: 5 / 6, color: 'indigo' },
        { value: 1, color: 'violet' },
        { value: Infinity, color: 'violet' }
    ],
    'rainbow-invert': [
        { value: 0, color: 'violet' },
        { value: 1 / 6, color: 'indigo' },
        { value: 1 / 3, color: 'blue' },
        { value: 1 / 2, color: 'green' },
        { value: 2 / 3, color: 'yellow' },
        { value: 5 / 6, color: 'orange' },
        { value: 1, color: 'red' },
        { value: Infinity, color: 'violet' }
    ],
    'performance': [
        { value: 0, color: 'red' },
        { value: 0.5, color: 'orange' },
        { value: 1, color: 'green' },
        { value: Infinity, color: 'green' }
    ],
    'performance-invert': [
        { value: 0, color: 'green' },
        { value: 0.5, color: 'orange' },
        { value: 1, color: 'red' },
        { value: Infinity, color: 'red' }
    ]
}

LinearColorBar.tag = 'LinearColorBar'.toLowerCase();
LinearColorBar.render = function () {
    return LinearColorBar_({
        class: 'as-linear-color-bar',
        child: [
            'svg.as-linear-color-background',
            '.as-linear-color-value-text',
            '.as-linear-color-min-value-text',
            '.as-linear-color-max-value-text'
        ]
    });
};

LinearColorBar.property = {};
LinearColorBar.property.valueText = {
    set: function (value) {
        value = value + '';
        this._valueText = value;
        this.$valueText.clearChild().addChild(LinearColorBar_({ text: value }));
    },
    get: function () {
        return this._valueText;
    }
};


LinearColorBar.property.minValueText = {
    set: function (value) {
        value = value + '';
        this._minValueText = value;
        this.$minValueText.clearChild().addChild(LinearColorBar_({ text: value }));
    },
    get: function () {
        return this._valueText;
    }
};

LinearColorBar.property.maxValueText = {
    set: function (value) {
        value = value + '';
        this._maxValueText = value;
        this.$maxValueText.clearChild().addChild(LinearColorBar_({ text: value }));
    },
    get: function () {
        return this._valueText;
    }
};

LinearColorBar.property.value = {
    set: function (value) {
        this._value = value;
    },
    get: function () {
        return this._value;
    }
};

LinearColorBar.property.extendValue = {
    set: function (value) {
        this._extendValue = value;
        this._updateGradient();
    },
    get: function () {
        return this._extendValue;
    }
};


LinearColorBar.property.colorMapping = {
    set: function (value) {
        if (typeof (value) == "string") value = this.BUILDIN_COLORS_RANGE[value];
        this._colorMapping = value.slice();
        this._colorMapping.sort(function (a, b) {
            return a.value - b.value;
        })
        this._updateGradient();
    },
    get: function () {
        return this._colorMapping;
    }
};

ACore["d" /* default */].install(LinearColorBar);
/* harmony default export */ var js_LinearColorBar = (LinearColorBar);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/mediainput.css
var mediainput = __webpack_require__(175);

// EXTERNAL MODULE: ./node_modules/absol/src/Converter/file.js + 1 modules
var Converter_file = __webpack_require__(36);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/Text.js
var Text = __webpack_require__(30);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/MediaInput.js











var MediACore = new Dom["b" /* default */]();
MediACore.install(ACore["d" /* default */]);


var MediaInput_ = MediACore._;
var MediaInput_$ = MediACore.$;


function openFileDialog(props) {
    if (!MediACore.$fileInput) {
        MediACore.$fileInput = MediaInput_({
            tag: 'input',
            class: 'vmedia-no-show',
            attr: {
                type: 'file'
            },
            props: {}
        }).addTo(document.body);
    }
    props = props || {};


    if (props.accept) {
        if (props.accept instanceof Array)
            MediACore.$fileInput.attr('accept', props.accept.join(','));
        else
            MediACore.$fileInput.attr('accept', props.accept);
    }
    else {
        MediACore.$fileInput.attr('accept', null);
    }

    if (props.multiple) {
        MediACore.$fileInput.attr('multiple', 'true');
    }
    else {
        MediACore.$fileInput.attr('multiple');
    }
    MediACore.$fileInput.value = null;
    MediACore.$fileInput.click();


    return new Promise(function (resolve, reject) {
        var finish = false;
        var body = MediaInput_$('body');
        MediACore.$fileInput.once('change', function () {
            finish = true;
            resolve(Array.prototype.map.call(this.files, function (file) {
                return file;
            }));
        });

        body.once('mousedown', function () {
            if (finish) return;
            resolve();
        });

    });
}

function MediaInput() {
    this.$editor = MediaInput_$('.vmedia-media-input-text-container-editor', this);
    this.$editor.on('paste', this.eventHandler.paste);
    this.$editor.on('keydown', this.eventHandler.keydown, true);
    this.$addImagebtn = MediaInput_$('#add-image-btn', this);
    this.$addImagebtn.on('click', this.eventHandler.clickAddImage);
    this.$addFilebtn = MediaInput_$('#add-file-btn', this);
    this.$addFilebtn.on('click', this.eventHandler.clickAddFile);
    this.$imagePreviewContainer = MediaInput_$('.vmedia-media-input-imagepreview-container', this);
    this.on('dragover', this.eventHandler.dragOver);
    this.on('drop', this.eventHandler.drop);
    this.$sendbtn = MediaInput_$('#send-btn', this);
    this.$sendbtn.on('click', this.eventHandler.send);
    this.$toolLeftCtn = MediaInput_$('.vmedia-media-input-tool-container-left', this);
    this.$pluginContentCtn = MediaInput_$('.vmedia-media-input-plugin-content-container', this);
    this.snapData = [];
    this.snapDataHead = 0;
    this.sync = this.afterAttached();
    this.snapText();
}

MediaInput.tag = 'MediaInput'.toLowerCase();

MediaInput.render = function () {
    return MediaInput_({
        class: 'vmedia-media-input',
        extendEvent: ['send', 'update', 'releaseplugin'],
        child: {
            class: 'vmedia-media-input-text-container',
            child: [{
                class: 'vmedia-media-input-imagepreview-container',
                child: {
                    class: 'vmedia-media-input-dropover',
                    child: 'download-ico'
                }
            },
                {
                    class: 'vmedia-media-input-text-container-editor',
                    attr: {
                        contenteditable: 'true'
                    },
                    on: {}
                },
                {
                    class: 'vmedia-media-input-text-container-buttons',
                    attr: {
                        title: 'Send'
                    }

                },
                {
                    class: 'vmedia-media-input-tool-container',
                    child: [
                        {
                            class: 'vmedia-media-input-tool-container-left',
                            child: [

                                {
                                    tag: 'button',
                                    attr: {
                                        id: 'add-image-btn',
                                        title: 'Add image'
                                    },
                                    child: 'add-image-ico'

                                },
                                {
                                    tag: 'button',
                                    attr: {
                                        id: 'add-file-btn',
                                        title: 'Add file'
                                    },
                                    child: 'add-file-ico'
                                },

                            ]
                        },
                        {
                            class: 'vmedia-media-input-tool-container-right',
                            child: [{
                                tag: 'button',
                                id: 'send-btn',
                                attr: {
                                    title: 'Send'
                                },
                                child: 'send-ico'
                            }]

                        }
                    ],
                },
                '.vmedia-media-input-plugin-content-container.blur',
            ]
        }
    });
};



MediaInput.prototype.addImage = function (url, title, data) {
    MediaInput_({
        tag: 'imagepreview',
        attr: {
            title: title
        },
        props: {
            data: data,
            imgSrc: url
        },
        on: {
            pressremove: function () {
                this.selfRemove();
            }
        }
    }).addTo(this.$imagePreviewContainer);
};
MediaInput.prototype.addFile = function (url, ext, title, data) {
    MediaInput_({
        tag: 'filepreview',
        attr: {
            title: title
        },
        props: {
            fileSrc: url,
            ext: ext,
            data: data
        },
        on: {
            pressremove: function () {
                this.selfRemove();
            }
        }
    }).addTo(this.$imagePreviewContainer);
};


MediaInput.property = {};

MediaInput.property.text = {
    set: function (value) {
        this.$editor.clearChild();
        value = value || '';
        var lines = value.split(/\r*\n/);
        if (lines.length < 1) return;
        this.$editor.addChild(document.createTextNode(lines[0]));
        lines.shift();
        lines.forEach(function (line) {
            this.$editor.addChild(MediaInput_({ child: document.createTextNode(line) }));
        }.bind(this));
        this.snapText();
    },
    get: function () {
        return this.getTextFromElements(this.$editor);
    }
};

MediaInput.property.files = {
    get: function () {
        return Array.prototype.filter.call(this.$imagePreviewContainer.childNodes, function (e) {
            return e._azar_extendTags && e._azar_extendTags.filepreview;
        }).map(function (e) {
            return e.data;
        });
    }
};
MediaInput.property.images = {
    get: function () {
        return Array.prototype.filter.call(this.$imagePreviewContainer.childNodes, function (e) {
            return e._azar_extendTags && e._azar_extendTags.imagepreview;
        }).map(function (e) {
            return e.data;
        });
    }
};

// MediaInput.property

MediaInput.property.plugins = {
    set: function (value) {
        this.sync = this.sync.then(this._dettachPlugins.bind(this, this._plugins));
        if (value) {
            if (!(value instanceof Array)) value = [value];
            this._plugins = value;
            this.addClass('has-plugin');

        }
        else {
            //remove plugin
            this.sync.then(this._dettachPlugins.bind(this));
            this._plugins = null;
            this.removeClass('has-plugin');
        }
        this.sync = this.sync.then(this._attachPlugins.bind(this, this._plugins));
    },
    get: function () {
        return this._plugins || null;
    }
}


MediaInput.prototype.appendText = function (text) {
    var lastBr = null;
    if (this.$editor.childNodes && this.$editor.childNodes.length > 0
        && this.$editor.childNodes[this.$editor.childNodes.length - 1].tagName
        && this.$editor.childNodes[this.$editor.childNodes.length - 1].tagName.toLowerCase() == 'br') {
        lastBr = this.$editor.childNodes[this.$editor.childNodes.length - 1];
    }

    var lines = text.split(/\r?\n/);
    if (lastBr) {
        for (var i = 0; i < lines.length; ++i) {
            if (i > 0) this.$editor.addChild(MediaInput_('br'));
            var e = MediaInput_({ text: lines[i] });
            this.$editor.addChild(e);
        }
    }
    else {
        for (var i = 0; i < lines.length; ++i) {
            if (i > 0) this.$editor.addChildBefore(MediaInput_('br'), lastBr);
            var e = MediaInput_({ text: lines[i] });
        }
        this.$editor.addChildBefore(e, lastBr);
    }

    Object(Text["setSelectionRange"])(this.$editor, Infinity);
};


MediaInput.prototype._attachPlugins = function (plugins) {
    if (!plugins) return;
    var self = this;
    plugins.forEach(function (plugin) {
        var oldContent = null;
        var $button = MediaInput_('button').addTo(self.$toolLeftCtn).on('click', function () {
            if (self._lastActivePlugin == plugin) return;
            self.releasePlugin();
            self._lastActivePlugin = plugin;
            self.$pluginContentCtn.removeClass('blur');
            self.$pluginContentCtn.clearChild();
            if (plugin.getContent) {
                var newContent = plugin.getContent(self, MediaInput_, MediaInput_$, self.$pluginContentCtn, oldContent);
                oldContent = newContent;
                self.$pluginContentCtn.addChild(newContent);
            }
            var buttonBound = $button.getBoundingClientRect();
            var rootBound = self.$pluginContentCtn.parentNode.getBoundingClientRect();
            self.$pluginContentCtn.addStyle({
                left: buttonBound.left + buttonBound.width / 2 - rootBound.left + 'px',
                bottom: rootBound.bottom - buttonBound.top + 'px'
            });
            if (plugin.onActive) plugin.onActive(self);
            setTimeout(function () {
                var outListener = function (event) {
                    if (EventEmitter["b" /* default */].hitElement(self.$pluginContentCtn, event)) {

                    }
                    else if (self._lastActivePlugin == plugin) {
                        var prevented = true;
                        if (plugin.onBlur) plugin.onBlur({
                            preventDefault: function () {
                                prevented = false;
                            }
                        });
                        if (prevented) {
                            self.releasePlugin();
                            MediaInput_$(document.body).off('click', outListener);
                        }
                    }
                    else {
                        MediaInput_$(document.body).off('click', outListener);
                    }
                };
                MediaInput_$(document.body).on('click', outListener);
                self.once('releaseplugin', function (ev) {
                    if (ev.plugin == plugin) {
                        MediaInput_$(document.body).off('click', outListener);
                    }
                });
            }, 100);
        });

        var btnInners = plugin.getTriggerInner(self, MediaInput_, MediaInput_$, $button);
        if (!(btnInners instanceof Array)) btnInners = [btnInners];
        btnInners.forEach(function (e) {
            if (typeof e == 'string') {
                e = MediaInput_({ text: e });
            }
            $button.addChild(e);
        });
        if (plugin.onAttached)
            plugin.onAttached(self);
    });
    //todo
    return true;
};

MediaInput.prototype.releasePlugin = function () {
    if (this._lastActivePlugin) {
        var plugin = this._lastActivePlugin;
        plugin.onDeactived && plugin.onDeactived(self);
        this.$pluginContentCtn.addClass('blur');
        this.emit('releaseplugin', { target: this, plugin: plugin }, this);
        this._lastActivePlugin = null;
    }

}

MediaInput.prototype._dettachPlugins = function (plugins) {
    if (!plugins) return;
    var self = this;
    plugins.forEach(function (plugin) {
        if (plugin.onAttached)
            plugin.onAttached(self);
    });
    //todo
    this._lastActivePlugin = null;
    return true;
};

MediaInput.prototype.focus = function () {
    this.$editor.focus();
    Object(Text["setSelectionRange"])(this.$editor, Infinity);
};

MediaInput.prototype.clear = function () {
    Array.prototype.filter.call(this.$imagePreviewContainer.childNodes, function (e) {
        return e._azar_extendTags && e._azar_extendTags.imagepreview;
    }).forEach(function (e) {
        e.selfRemove();
    });

    Array.prototype.filter.call(this.$imagePreviewContainer.childNodes, function (e) {
        return e._azar_extendTags && e._azar_extendTags.filepreview;
    }).forEach(function (e) {
        return e.selfRemove();
    });

    this.$editor.innerHTML = "";
    this.emit('update', { target: this }, this);
};


MediaInput.prototype.escapeSpace = function (s) {
    return s.replace(/\s/g, '&nbsp');
};


MediaInput.prototype.unescapeSpace = function (s) {
    return s.replace(/&nbsp/g, ' ');
};


MediaInput.prototype.getTextFromElements = function (element) {
    return Object(Text["getTextIn"])(element);
    // var self = this;

    // function visit(e, prevE) {
    //     var ac = '';
    //     var isNewLine = false;
    //     if (prevE && prevE.nodeType != Node.TEXT_NODE) {

    //         if (prevE.tagName && prevE.tagName.toLowerCase() == 'br') {
    //             isNewLine = true;
    //         }
    //         else if (Element.prototype.getComputedStyleValue.call(prevE, 'display') == 'block') {
    //             isNewLine = true;
    //         }
    //     }

    //     if (e.nodeType == Node.TEXT_NODE) {
    //         if (isNewLine) ac += '\n';
    //         ac += e.data;
    //     }
    //     else {
    //         var lastE = undefined;
    //         for (var i = 0; i < e.childNodes.length; ++i) {
    //             ac += visit(e.childNodes[i], i > 0 ? e.childNodes[i - 1] : null);

    //         }
    //     }
    //     return ac;
    // }

    // return visit(element);
};

MediaInput.prototype.getElementsFromText = function (text) {
    var newElements = text.split('\n')
        .map(function (text) {
            return document.createTextNode(text);
        })
        .reduce(function (ac, cr, i, arr) {
            if (i > 0)
                ac.push(MediaInput_('br'));
            ac.push(cr);
            return ac;
        }, []);
    return newElements;
};


// MediaInput.prototype.textOnly = function(e) {
//     if (e.nodeType == Node.TEXT_NODE) return e.textContent;
//     if (!e.tagName) return '';
//     if (e.tagName.toLowerCase() == 'br') return '\n';
//     return ($(e).getComputedStyleValue('display') == 'block' ? '\n' : '') + Array.prototype.map.call(e.childNodes, this.textOnly.bind(this)).join('')
// };

MediaInput.prototype.makeTextOnly = function () {
    var self = this;
    var editor = this.$editor;
    Array.apply(null, this.$editor.childNodes).forEach(function (e) {
        e = MediaInput_$(e);
        if (e.nodeType == Node.TEXT_NODE) return;
        if (e.tagName) {
            var tagName = e.tagName.toLowerCase();
            if (tagName == 'br') return;
            if (tagName.match(/img|script|svg|button|iframe|hr|video|canvas/)) {
                e.selfRemove(e);
            }

            if (tagName.match(/select|input|textarea/)) {
                e.selfReplace(document.createTextNode(e.value));
                return;
            }

            var newElements = self.getElementsFromText(self.getTextFromElements(e));
            var lastElement;
            if (e.getComputedStyleValue('display') == 'block') {
                lastElement = MediaInput_('br');
            }
            else {
                lastElement = newElements.pop();
            }
            e.selfReplace(lastElement);
            newElements.forEach(function (nE) {
                editor.addChildBefore(nE, lastElement);
            });
        }
    });


    this.emit('update', { target: editor }, this);
};

MediaInput.eventHandler = {};


MediaInput.eventHandler.keydown = function (event) {
    if (event.key == "Enter") {
        if (!event.ctrlKey && !event.altKey && !event.shiftKey) {
            event.preventDefault();
            this.eventHandler.send(event);
            this.snapText();
        }

    }
    if (event.ctrlKey && event.key == 'z') {
        event.preventDefault();
        this.undoText();
    }
    if (event.ctrlKey && event.key == 'x') {
        setTimeout(this.snapText.bind(this), 100)
    }
    setTimeout(this.emit.bind(this, 'update', event, this), 1);
};


MediaInput.eventHandler.send = function (event) {
    if (this.images.length == 0 && this.text.trim().length == 0 && this.files.length == 0) {
        return;
    }
    this.emit('send', event, this);
    this.snapText();
};

MediaInput.eventHandler.clickAddImage = function (event) {
    openFileDialog({ accept: 'image/*', multiple: true }).then(function (files) {
        if (!files) return;
        files.map(function (file) {
            var url = (window.URL || window.webkitURL).createObjectURL(file);
            this.addImage(url, file.name, { file: file, name: file.name, url: url });
            this.emit('update', event, this);
        }.bind(this));
    }.bind(this));
};

MediaInput.eventHandler.clickAddFile = function (event) {
    openFileDialog({ multiple: true }).then(function (files) {
        if (!files) return;
        files.map(function (file) {
            var url = (window.URL || window.webkitURL).createObjectURL(file);
            if (file.type.match(/^image/)) {
                this.addImage(url, file.name, { file: file, name: file.name, url: url });
            }
            else {
                var p = file.name.split('.');
                var ext = p.length > 1 ? p[p.length - 1] : '';
                this.addFile(url, ext.toUpperCase(), file.name, { file: file, name: file.name, url: url });
            }
        }.bind(this));
        this.emit('update', event, this);
    }.bind(this));
};


MediaInput.eventHandler.dragOver = function (event) {
    event.preventDefault();
    this._lastDragOver = new Date().getTime();
    var currentDragOver = this._lastDragOver;
    if (!this.dragOver) {
        this.dragOver = true;
        this.addClass('dragover');
        this.emit('update', event, this);
    }
    setTimeout(function () {
        this._waitDragFileOut
        if (this._lastDragOver == currentDragOver) {
            this.removeClass('dragover');
            this.dragOver = false;
            this.emit('update', event, this);
        }
    }.bind(this), 200);
};


MediaInput.eventHandler.drop = function (event) {
    event.preventDefault();
    if (event.dataTransfer.items) {
        for (var i = 0; i < event.dataTransfer.items.length; i++) {
            if (event.dataTransfer.items[i].kind === 'file') {
                var file = event.dataTransfer.items[i].getAsFile();
                if (!file.type && file.size % 4096 == 0) {
                    //todo: folder
                }
                else {
                    this.addSystemFile(file);
                    this.emit('update', event, this);
                }

            }
        }
    }
    else {
        for (var i = 0; i < event.dataTransfer.files.length; i++) {
            var file = event.dataTransfer.files[i];
            if (!file.type && file.size % 4096 == 0) {

            }
            else {
                this.addSystemFile(file);
                this.emit('update', event, this);
            }
        }
    }
};


MediaInput.prototype.addSystemFile = function (file) {
    var url = (window.URL || window.webkitURL).createObjectURL(file);
    if (file.type.match(/^image/)) {
        this.addImage(url, file.name, { file: file, name: file.name, url: url });
    }
    else {
        var p = file.name.split('.');
        var ext = p.length > 1 ? p[p.length - 1] : '';
        this.addFile(url, ext.toUpperCase(), file.name, { file: file, name: file.name, url: url });
    }
}


MediaInput.eventHandler.paste = function (event) {
    var pasteData = (event.clipboardData || window.clipboardData);
    var beforePasteElement = [];
    var self = this;

    function visit(e, ac) {
        ac.push(e);
        if (e.childNodes) {
            for (var i = 0; i < e.childNodes.length; ++i) {
                visit(e.childNodes[i], ac)
            }
        }
    }

    visit(this.$editor, beforePasteElement);


    function relocalCursor() {
        var afterPasteElement = [];
        visit(self.$editor, afterPasteElement);
        var diffElts = afterPasteElement.filter(function (e) {
            return beforePasteElement.indexOf(e) < 0;
        });
        if (diffElts.length > 0) {
            var last = diffElts.pop();
            if (last.nodeType == Node.TEXT_NODE) {
                var range = document.createRange();
                range.selectNodeContents(last);
                range.setStart(last, last.data.length);
                var sel = window.getSelection();
                sel.removeAllRanges();
                sel.addRange(range);
            }
            else {
                Object(Text["setSelectionRange"])(last, Infinity);
            }
        }
    }

    /**Safari bug */
    if (pasteData && pasteData.items) {
        var items = pasteData.items;
        var isAddImage = false;
        for (var i = 0; i < items.length; i++) {
            if (items[i].type.indexOf('image') !== -1) {
                var blob = items[i].getAsFile();
                var URLObj = (window.URL || window.webkitURL);
                var source = URLObj.createObjectURL(blob);
                var file = Object(Converter_file["blobToFile"])(blob);
                var buffer = Object(Converter_file["blobToArrayBuffer"])(blob).then(function (arrayBuffer) {
                    this.addImage(source, 'Clipboard', {
                        file: blob,
                        name: null,
                        url: source,
                        blob: blob,
                        arrayBuffer: arrayBuffer
                    });
                    this.emit('update', event, this);
                }.bind(this));

                isAddImage = true;
                this.emit('update', event, this);
            }
        }
        if (isAddImage)
            event.preventDefault();
        requestAnimationFrame(function () {
            self.makeTextOnly();
            relocalCursor();
        });
    }
    else {
        requestAnimationFrame(function () {
            var img = MediaInput_$('img', this.$editor, function (img) {
                if (img) {
                    img = MediaInput_$(img);
                    var source = img.getAttribute('src');
                    img.selfRemove();
                    Dom["b" /* default */].imageToCanvas(img).then(function (canvas) {
                        var dataURI = canvas.toDataURL();
                        var blob = Object(Converter_file["dataURItoBlob"])(dataURI);
                        var file = Object(Converter_file["blobToFile"])(blob);
                        var buffer = Object(Converter_file["blobToArrayBuffer"])(blob).then(function (arrayBuffer) {
                            this.addImage(source, 'Clipboard', {
                                dataURI: dataURI,
                                file: blob,
                                name: null,
                                url: source,
                                blob: blob,
                                arrayBuffer: arrayBuffer
                            });
                            this.emit('update', event, this);
                        }.bind(this));

                    }.bind(this), function (e) {
                    }).catch(function (e) {
                    });

                }
            }.bind(this));
            this.makeTextOnly();
            relocalCursor();
        }.bind(this));
    }
};


MediaInput.prototype.undoText = function () {
    if (this.snapDataHead <= 1) return;
    this.snapDataHead--;
    if (this.snapDataHead <= 0) return;
    var newText = this.snapData[this.snapDataHead - 1];
    this.text = newText;
    Object(Text["setSelectionRange"])(this.$editor, Infinity);
};

MediaInput.prototype.redoText = function () {
    if (this.snapData.length <= this.snapDataHead) return;
    this.snapDataHead++;
    var newText = this.snapData[this.snapDataHead - 1];
    var currentText = this.text;
    this.text = newText;
    Object(Text["setSelectionRange"])(this.$editor, Infinity);
};

MediaInput.prototype.snapText = function () {
    while (this.snapData.length > this.snapDataHead && this.snapData.length > 0) this.snapData.pop();
    var oldText = this.snapData[this.snapDataHead - 1];
    var newText = this.text;
    if (newText == oldText) return;
    this.snapData.push(this.text);
    this.snapDataHead++;
}


function ImagePreview() {

    var res = MediaInput_({
        extendEvent: 'pressremove',
        class: ['vmedia-media-input-imagepreview', 'vmedia-no-select'],
        child: ['img', 'times-ico']
    });

    res.$img = MediaInput_$('img', res);
    res.$timesIco = MediaInput_$('times-ico', res);
    res.$timesIco.on('click', function (event) {
        res.emit('pressremove', event, res);
    });
    OOP["a" /* default */].drillProperty(res, res.$img, 'imgSrc', 'src');
    return res;
};


function FilePreview() {
    var res = MediaInput_({
        extendEvent: 'pressremove',
        class: ['vmedia-media-input-filepreview', 'vmedia-no-select'],
        child: ['attachment-ico', 'times-ico']
    });

    res.$img = MediaInput_$('attachment-ico', res);
    OOP["a" /* default */].drillProperty(res, res.$img, 'ext');
    res.$timesIco = MediaInput_$('times-ico', res);
    res.$timesIco.on('click', function (event) {
        res.emit('pressremove', event, res);
    });
    return res;
};


MediACore.creator.mediainput = MediaInput;
MediACore.creator.imagepreview = ImagePreview;
MediACore.creator.filepreview = FilePreview;

MediACore.creator['send-ico'] = function () {
    return MediaInput_(
        [
            '<svg class="send" width="100" height="100" version="1.1" viewBox="0 0 26.458 26.458">',
            '    <g transform="translate(0 -270.54)">',
            '        <path d="m0.64298 272.44 3.1712 9.5402 22.152 1.7742-22.152 1.7482-3.1712 9.4749 25.323-11.223z" />',
            '    </g>',
            '</svg>'
        ].join('')
    );
};

MediACore.creator['add-file-ico'] = function () {
    return MediaInput_(
        [
            '<svg class="add-file" width="100" height="100" version="1.1" viewBox="0 0 26.458 26.458" xmlns="http://www.w3.org/2000/svg">',
            '    <g transform="translate(0 -270.54)">',
            '        <path d="m4.2431 295.69c-0.74006-0.0759-1.4136-0.33772-2.0047-0.77942-0.19965-0.14919-0.60549-0.55475-0.75233-0.75182-0.45099-0.60524-0.7154-1.2913-0.77699-2.016-0.01275-0.15007-0.01628-2.6111-0.01252-8.7468 0.0049-8.0504 0.0068-8.5472 0.03338-8.6986 0.0883-0.50391 0.22692-0.91024 0.44705-1.3104 0.52794-0.95973 1.452-1.6645 2.5119-1.9158 0.44319-0.10508 0.12729-0.0972 4.1445-0.10308 2.5538-4e-3 3.6864-1e-4 3.7795 0.0121 0.38853 0.0508 0.80777 0.24687 1.2709 0.59434 0.44102 0.33085 0.68272 0.55272 1.7227 1.5813 0.46507 0.45998 1.2812 1.2664 1.8136 1.7921 0.96172 0.94958 1.3847 1.3824 1.696 1.7354 0.61073 0.69257 0.92 1.2063 1.0441 1.7344 0.02613 0.11122 0.02875 0.28598 0.03409 2.2731 0.0047 1.7451 0.0018 2.1574-0.01502 2.178-0.01424 0.0174-0.10685 0.0394-0.2936 0.0699-0.45695 0.0745-1.0078 0.22363-1.4356 0.38862-0.10025 0.0387-0.1888 0.0663-0.19678 0.0613-0.0085-5e-3 -0.01461-0.7983-0.01475-1.9156-2.09e-4 -1.6438-0.0036-1.9208-0.0245-2.0096-0.06972-0.29578-0.28642-0.50043-0.63767-0.60222-0.32942-0.0955-0.31104-0.0947-2.4299-0.10482l-1.9437-9e-3 -0.12495-0.0442c-0.25474-0.0901-0.45899-0.26526-0.5666-0.48578-0.10853-0.22238-0.10356-0.127-0.10407-1.9994-4.63e-4 -1.7153-0.01031-2.1544-0.05446-2.4288-0.06935-0.43095-0.22893-0.69171-0.5027-0.82138l-0.10904-0.0516h-3.1807c-3.4262 0-3.27-4e-3 -3.5482 0.0835-0.68034 0.21325-1.1718 0.754-1.3329 1.4666l-0.0345 0.15261v8.5059c0 8.1045 0.0014 8.5125 0.02871 8.6468 0.08088 0.39719 0.25808 0.72858 0.53956 1.0091 0.28082 0.27984 0.576 0.44186 0.98191 0.53896 0.11389 0.0273 0.36156 0.0293 4.5294 0.0374l4.409 9e-3 0.02019 0.0402c0.0111 0.0221 0.07695 0.15943 0.14632 0.30521s0.17519 0.3518 0.23515 0.45783c0.14341 0.25357 0.43703 0.69284 0.61725 0.92343 0.0793 0.10148 0.14077 0.19003 0.13659 0.19679-0.0073 0.0118-9.9306 0.0132-10.046 1e-3z" />',
            '        <path transform="matrix(.26458 0 0 .26458 0 270.54)" d="m72.469 65.742v7.4062h-7.4062v7.2852h7.4062v7.2812h7.2793v-7.2812h7.3535v-7.2852h-7.3535v-7.4062zm24.948 11.119a21.371 21.371 0 0 1-21.371 21.371 21.371 21.371 0 0 1-21.371-21.371 21.371 21.371 0 0 1 21.371-21.371 21.371 21.371 0 0 1 21.371 21.371z" style="fill-rule:evenodd;" />',
            '        <path d="m17.256 283.76 1.921-0.47607-0.04725-4.2884c0-0.50159-0.29516-1.2441-1.0789-2.0168l-4.6989-4.6324c-0.73814-0.72769-1.5947-0.97084-2.1519-0.97084h-7.0235c-2.1533 0.0144-3.4601 2.6226-3.4778 3.4778v17.284c0 2.121 2.2409 3.5346 3.5346 3.5346h10.058l-1.1146-1.9305h-8.6658c-1.1271 0-1.8503-1.1115-1.8503-1.8503v-16.867c0-1.0721 1.1373-1.6977 1.6977-1.6977h6.2175c0.43142 0 0.8103 0.28958 0.8103 1.1742v3.714c0 0.24768 0.36442 0.90967 0.90968 0.90967h3.2537c1.2453 0 1.6905 0.32876 1.6905 1.1613z"  />',
            '    </g>',
            '</svg>'
        ].join('')
    );
};
MediACore.creator['add-image-ico'] = function () {
    return MediaInput_(
        [
            '<svg class="add-image" width="100" height="100" version="1.1" viewBox="0 0 26.458 26.458" xmlns="http://www.w3.org/2000/svg" xmlns:cc="http://creativecommons.org/ns#" xmlns:dc="absol/src/HTML5/Elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">',
            '    <g transform="translate(0 -270.54)">',
            '        <path d="m24.73 288.69a5.9808 5.9808 0 0 1-5.9808 5.9808 5.9808 5.9808 0 0 1-5.9808-5.9808 5.9808 5.9808 0 0 1 5.9808-5.9808 5.9808 5.9808 0 0 1 5.9808 5.9808zm1.503-0.037a7.5843 7.5843 0 0 1-7.5843 7.5843 7.5843 7.5843 0 0 1-7.5843-7.5843 7.5843 7.5843 0 0 1 7.5843-7.5843 7.5843 7.5843 0 0 1 7.5843 7.5843z" style="fill-rule:evenodd;fill:#414141"/>',
            '        <path d="m17.869 284.42v3.4127h-3.4081v1.6066h3.4081v3.438h1.6061v-3.438h3.4432v-1.6066h-3.4432v-3.4127z" style="fill-rule:evenodd;fill:#414141"/>',
            '        <path d="m24.614 281.39v-6.1305c0-1.6957-1.2841-2.6602-2.6602-2.6602h-18.412c-1.4547 0-2.7249 1.0223-2.7249 2.7249v14.986c0 1.2346 0.99768 2.6028 2.586 2.586h6.9542c-0.36184-0.63963-0.51495-1.0286-0.69323-1.6506h-6.4562c-0.29938 0-0.72246-0.40379-0.72246-0.72247v-1.8082l6.0428-6.7569 2.0296 2.0129 0.9605-1.3029-2.9734-3.1488-5.9885 6.7736v-11.426c0-0.24935 0.30766-0.63476 0.63476-0.63476h18.934c0.3592 0 0.84357 0.19284 0.84357 0.84357v5.2285c0.61147 0.22444 1.1564 0.59412 1.6454 1.0858z" style="fill:#414141"/>',
            '        <circle cx="17.869" cy="277.61" r="1.6891" style="fill-rule:evenodd;fill:#414141"/>',
            '    </g>',
            '</svg>'
        ].join('')
    );
};

MediACore.creator['attachment-ico'] = function () {
    return MediaInput_(
        [
            '<svg class="attachment" width="1024" height="1024"  version="1.1" viewBox="0 0 1024 1024" xmlns="http://www.w3.org/2000/svg" >',
            '    <path d="M145.6 0C100.8 0 64 35.2 64 80v862.4C64 987.2 100.8 1024 145.6 1024h732.8c44.8 0 81.6-36.8 81.6-81.6V324.8L657.6 0h-512z" fill="#8199AF"/>',
            '    <path d="M960 326.4v16H755.2s-100.8-20.8-99.2-108.8c0 0 4.8 92.8 97.6 92.8H960z" fill="#617F9B"/>',
            '    <path d="M657.6 0v233.6c0 25.6 17.6 92.8 97.6 92.8H960L657.6 0z" fill="#fff"/>',
            '    <path d="m491.77 770.31c17.6-19.2 17.6-48 0-67.2s-48-17.6-65.6 0l-147.2 147.2c-17.6 17.6-17.6 48 0 65.6s48 19.2 65.6 0l91.2-89.6c4.8-4.8 4.8-12.8 0-17.6s-14.4-6.4-19.2 0l-57.6 56c-8 8-19.2 8-27.2 0s-8-20.8 0-28.8l56-56c20.8-20.8 54.4-20.8 75.2 0s20.8 54.4 0 75.2l-89.6 89.6c-33.6 33.6-88 33.6-123.2 0-33.6-33.6-33.6-88 0-121.6l147.2-147.2c33.6-33.6 89.6-33.6 123.2 0s33.6 88 0 121.6l-14.4 14.4c-1.6-14.4-6.4-28.8-16-41.6z" style="fill:#fff"/>',
            '    <path d="m130.09 23.864h504.75v182.93h-545.65v-140.08c0.34155-16.845 13.608-42.414 40.9-42.847z" style="fill-opacity:.29648;fill-rule:evenodd;fill:#fff"/>',
            '</svg>'
        ]
            .join('')
    );
};

MediACore.creator['attachment-ico'].property = {
    ext: {
        set: function (value) {
            value = value || '';
            if (this.$ext) {
                this.$ext.selfRemove();
            }
            this.$ext = Svg["a" /* default */].ShareInstance._('<text text-anchor="middle" x="321.39" y="170" font-size="145.76" style="fill:white;" >' + value + '</text>').addTo(this);
        },
        get: function () {
            return this._ext || '';
        }
    }
};


MediACore.creator['times-ico'] = function () {
    return MediaInput_(
        [
            '<svg class="times" width="100" height="100" version="1.1" viewBox="0 0 26.458 26.458" xmlns="http://www.w3.org/2000/svg">',
            '    <g transform="translate(0 -270.54)">',
            '        <path d="m7.7013 276.49 5.4832 5.4832 5.5494-5.5494 1.7874 1.7874-5.5291 5.5291 5.4957 5.4957-1.754 1.754-5.5124-5.5124-5.5542 5.5542-1.7623-1.7623 5.5375-5.5375-5.5208-5.5208zm17.103 7.3351a11.558 11.558 0 0 1-11.558 11.558 11.558 11.558 0 0 1-11.558-11.558 11.558 11.558 0 0 1 11.558-11.558 11.558 11.558 0 0 1 11.558 11.558z" style="fill-rule:evenodd;"/>',
            '    </g>'
        ].join('')
    );
};


MediACore.creator['download-ico'] = function () {
    return MediaInput_(
        [
            '<svg class="download" width="100mm" height="100mm" version="1.1" viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg">',
            '    <g transform="translate(0,-197)">',
            '        <path d="m44.888 209.14h13.982c1.1087 0.0459 2.2328 0.74137 2.317 2.3612v23.694h13.622c1.9742-0.18801 3.004 2.6244 1.9175 4.1118l-23.469 23.918c-0.876 0.77477-1.9993 0.77232-2.9362 0l-23.559-24.009c-0.86532-1.0422 0.11658-4.1953 2.3821-4.2047h13.268v-22.939c-0.08167-1.1772 0.78292-2.9507 2.4768-2.9312z" style="fill:#00c3e5"/>',
            '        <path d="m86.97 276.99a3.5027 3.5696 0 0 1-3.5027 3.5696 3.5027 3.5696 0 0 1-3.5027-3.5696 3.5027 3.5696 0 0 1 3.5027-3.5696 3.5027 3.5696 0 0 1 3.5027 3.5696zm-12.768 0a3.5027 3.5696 0 0 1-3.5027 3.5696 3.5027 3.5696 0 0 1-3.5027-3.5696 3.5027 3.5696 0 0 1 3.5027-3.5696 3.5027 3.5696 0 0 1 3.5027 3.5696zm-60.003-16.135h24.609c9.1206 13.508 17.573 12.942 26.609 0h23.839c2.8529 5e-3 3.5087 2.3205 3.4679 3.8227v18.953c0.04867 1.3083-1.5145 2.9901-2.7505 2.9832h-76.253c-1.049 0.0441-2.6554-1.4851-2.6306-3.1451l-1.56e-4 -18.792c0.0024-1.3549 0.50958-3.7927 3.1091-3.8227z" style="fill-rule:evenodd;fill:#00c3e5"/>',
            '    </g>',
            '</svg>'
        ].join('')
    );
};

MediACore.creator['plus-ico'] = function () {
    return MediaInput_(
        '<svg class="_7oal" height="24" width="24" viewBox="0 0 24 24"><g fill="none" fill-rule="evenodd"><polygon points="-6,30 30,30 30,-6 -6,-6 "></polygon><path d="m18,11l-5,0l0,-5c0,-0.552 -0.448,-1 -1,-1c-0.5525,0 -1,0.448 -1,1l0,5l-5,0c-0.5525,0 -1,0.448 -1,1c0,0.552 0.4475,1 1,1l5,0l0,5c0,0.552 0.4475,1 1,1c0.552,0 1,-0.448 1,-1l0,-5l5,0c0.552,0 1,-0.448 1,-1c0,-0.552 -0.448,-1 -1,-1m-6,13c-6.6275,0 -12,-5.3725 -12,-12c0,-6.6275 5.3725,-12 12,-12c6.627,0 12,5.3725 12,12c0,6.6275 -5.373,12 -12,12" ></path></g></svg>'
    );
};


ACore["d" /* default */].install(MediaInput);


/* harmony default export */ var js_MediaInput = (MediaInput);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/MessageInput.js + 1 modules
var MessageInput = __webpack_require__(37);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/numberinput.css
var numberinput = __webpack_require__(179);

// EXTERNAL MODULE: ./node_modules/absol/src/Math/int.js
var Math_int = __webpack_require__(14);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/NumberInput.js








var NumberInput_ = ACore["d" /* default */]._;
var NumberInput_$ = ACore["d" /* default */].$;


function NumberInput() {
    this.eventHandler = OOP["a" /* default */].bindFunctions(this, NumberInput.eventHandler);
    this.$input = NumberInput_$('input', this)
        .on('keydown', this.eventHandler.keydown)
        .on('keyup', this.eventHandler.keyup)
        .on('paste', this.eventHandler.paste)
        .on('change', this.eventHandler.change);
    this.$input.value = 0;
    this._previusValue = 0;//to kwnow whenever the value changed
    this._value = 0;
    this._max = Infinity;
    this._min = -Infinity;
    this.$upBtn = NumberInput_$('.absol-number-input-button-up-container button', this)
        .on('mousedown', this.eventHandler.mouseDownUpBtn);
    this.$downBtn = NumberInput_$('.absol-number-input-button-down-container button', this)
        .on('mousedown', this.eventHandler.mouseDownDownBtn);
    this._decimalSeparator = '.';
    this._thousandsSeparator = '';
    this._floatFixed = -1;// unset
    this._decimalPadding = -1;//unset
}

NumberInput.tag = 'NumberInput'.toLowerCase();

NumberInput.render = function () {
    return NumberInput_({
        class: 'absol-number-input',
        extendEvent: ['change'],
        child: [
            {
                class: 'absol-number-input-text-container',
                child: 'input[type="text"]'
            },
            {
                class: 'absol-number-input-button-up-container',
                child: {
                    tag: 'button',
                    child: 'span.mdi.mdi-menu-up'
                }
            },
            {
                class: 'absol-number-input-button-down-container',
                child: {
                    tag: 'button',
                    child: 'span.mdi.mdi-menu-down'
                }
            }

        ]
    });
};


NumberInput.eventHandler = {};

NumberInput.eventHandler.mouseDownUpBtn = function (event) {
    if (EventEmitter["b" /* default */].isMouseRight(event)) return;
    var self = this;
    var body = NumberInput_$(document.body);
    var pressing = true;
    var timeout = -1;
    var i = 0;

    function tick() {
        if (pressing) {
            if (i == 0 || i >= 4) {
                self.value = Math.round(self.value * Math.pow(10, Math.max(self._floatFixed, 0)) + 1) / Math.pow(10, Math.max(self._floatFixed, 0));
                self.notifyChanged({ by: 'long_press_button' });
            }
            ++i;
            self.__pressingUpTimeout__ = setTimeout(tick, 100);
        }
    }

    function finish(event) {
        pressing = false;
        if (timeout >= 0) {
            clearTimeout(timeout);
            timeout = -1;
        }
        body.off('mouseup', finish);
        body.off('mouseleave', finish);
        if (event.type == 'mouseup') {
            self.$input.focus();
        }
        self.notifyChanged({ originEvent: event, by: 'press_button' });
    }

    body.on('mouseup', finish);
    body.on('mouseleave', finish);
    tick();
};

NumberInput.eventHandler.mouseDownDownBtn = function (event) {
    if (EventEmitter["b" /* default */].isMouseRight(event)) return;
    var self = this;
    var body = NumberInput_$(document.body);
    var pressing = true;
    var timeout = -1;
    var i = 0;

    function tick() {
        if (pressing) {
            if (i == 0 || i >= 4) {
                self.value = Math.round(self.value * Math.pow(10, Math.max(self._floatFixed, 0)) - 1) / Math.pow(10, Math.max(self._floatFixed, 0));
                self.notifyChanged({ by: 'long_press_button' });
            }
            ++i;
            self.__pressingUpTimeout__ = setTimeout(tick, 100);
        }
    }

    function finish(event) {
        pressing = false;
        if (timeout >= 0) {
            clearTimeout(timeout);
            timeout = -1;
        }
        body.off('mouseup', finish);
        body.off('mouseleave', finish);
        if (event.type == 'mouseup') {
            self.$input.focus();
        }
        self.notifyChanged({ originEvent: event, by: 'press_button' });
    }

    body.on('mouseup', finish);
    body.on('mouseleave', finish);
    tick();
};


NumberInput.eventHandler.keyup = function (event) {
    var cValue = parseFloat(this.$input.value);
    if (!isNaN(cValue) && cValue <= this.max && this.min <=cValue) {
        this._value = cValue;
        this.notifyChanged({ originEvent: event, by: 'keyup' });
    }
};


NumberInput.eventHandler.keydown = function () {
    var key = event.key;
    var text = this.$input.value;
    if (key && key.length == 1 && !event.ctrlKey) {
        if (key.match(/[0-9.\-\+]/)) {
            if (key == '.' && text.indexOf('.') >= 0) event.preventDefault();
            if ((key == '+' || key == '-') && (text.indexOf('+') >= 0 || text.indexOf('-') >= 0 || Object(Text["getCaretPosition"])(this.$input) > 0)) event.preventDefault();
        }
        else event.preventDefault();
    }
};

NumberInput.eventHandler.change = function (event) {
    this.value = parseFloat(this.$input.value);
    this.notifyChanged({ originEvent: event, by: 'input_change' });
};

NumberInput.eventHandler.paste = function (e) {
    e.preventDefault();
    var text = "";
    if (e.clipboardData && e.clipboardData.getData) {
        text = e.clipboardData.getData("text/plain");

    }
    else if (window.clipboardData && window.clipboardData.getData) {
        text = window.clipboardData.getData("Text");
    }

    var oldText = this.$input.value;
    var caretPos = Object(Text["getCaretPosition"])(this.$input);
    var newText = oldText.substr(0, caretPos) + text + oldText.substr(caretPos);
    var matched = newText.match(/[+-]?([0-9]*[.])?[0-9]+/);
    if (matched) {
        this.value = parseFloat(matched[0]);
    }
};


NumberInput.prototype.notifyChanged = function (option) {
    option = option || {};
    if (this._previusValue != this.value || this._prevBy !== option.by) {
        this.emit('change', Object.assign({ target: this, value: this.value }, option || {}), this);
        this._previusValue = this.value;
        this._prevBy = option.by;
    }
}


NumberInput.prototype.numberToString = function (number) {
    return Object(Math_int["numberToString"])(this._value, this._floatFixed, this._decimalSeparator, this._thousandsSeparator, this._decimalPadding);
};


NumberInput.prototype.updateTextValue = function () {
    if (this._value == Infinity || this._value == -Infinity) this.$input.value = this._value + "";
    this.$input.value = this.numberToString(this._value);
}

NumberInput.prototype.stringToNumber = function (string) {
    var matchedInf = string.toLowerCase().match('/([+-])?infinity/');
    if (matchedInf) {
        if (matchedInf[1] == '-')
            return Infinity;
        return -Infinity;
    }
    else if (this._thousandsSeparator == '.') {
        string = string.replace(/\./g, '').replace(/\,/, '.');
    }
    else if (this._thousandsSeparator == ',') {
        string = string.replace(/\,/g, '');
    }

    return parseFloat(string);
};


NumberInput.property = {};

NumberInput.property.value = {
    set: function (value) {
        if (typeof (value) != 'number' || isNaN(value)) value = 0;
        this._value = Math.max(this._min, Math.min(this._max, value));
        this.updateTextValue();
    },
    get: function () {
        return this._value;
    }
};


NumberInput.property.max = {
    set: function (value) {
        if (!(typeof value == 'number') || isNaN(value)) {
            value = Infinity;
        }
        this._max = value;
        this._value = Math.min(value, this._value);
        this._min = Math.min(this._min, this._value);
        this.updateTextValue();
    },
    get: function () {
        return this._max;
    }
};

NumberInput.property.min = {
    set: function (value) {
        if (!(typeof value == 'number') || isNaN(value)) {
            value = -Infinity;
        }
        this._min = value;
        this._value = Math.max(value, this._value);
        this._max = Math.max(this._max, this._value);
        this.updateTextValue();

    },
    get: function () {
        return this._min;
    }
};

NumberInput.property.decimalSeparator = {
    set: function (value) {
        if (value == ',') {
            if (this._thousandsSeparator == ',')
                this._thousandsSeparator = '.';
        }
        else if (value == '.') {
            if (this._thousandsSeparator == '.')
                this._thousandsSeparator = ',';
        }
        else {
            value = '';
        }
        this._decimalSeparator = value;
        this.updateTextValue();
    },
    get: function () {
        return this._decimalSeparator;
    }
};


NumberInput.property.thousandsSeparator = {
    set: function (value) {
        if (value == ',') {
            if (this._decimalSeparator == ',')
                this._decimalSeparator = '.';
        }
        else if (value == '.') {
            if (this._decimalSeparator == '.')
                this._decimalSeparator = ',';
        }
        else {
            value = '';
        }
        this._thousandsSeparator = value;
        this.updateTextValue();
    },
    get: function () {
        return this._thousandsSeparator;
    }
};

NumberInput.property.floatFixed = {
    set: function (value) {
        if (typeof value == "number") {
            if (isNaN(value)) {
                value = -1;
            }
            else {
                value = Math.round(Math.max(-1, Math.min(100, value)));
            }
        }
        else {
            value = -1;
        }

        this._floatFixed = value;
        this.updateTextValue();
    },
    get: function () {
        return this._floatFixed;
    }
};

NumberInput.property.decimalPadding = {
    set: function (value) {
        if (typeof value == "number") {
            if (isNaN(value)) {
                value = 0;
            }
            else {
                value = Math.round(Math.max(-1, Math.min(100, value)));
            }
        }
        else {
            value = 0;
        }
        this._decimalPadding = value;
        this.updateTextValue();
    },
    get: function () {
        return this._decimalPadding;
    }
};


NumberInput.property.disabled = {
    set: function (value) {
        this.$input.disabled = !!value;
        this.$upBtn.disabled = !!value;
        this.$downBtn.disabled = !!value;
        if (value)
            this.addClass('absol-disabled');
        else
            this.removeClass('absol-disabled');
    },
    get: function () {
        return this.$input.disabled;
    }
};


ACore["d" /* default */].install('NumberInput'.toLowerCase(), NumberInput);

/* harmony default export */ var js_NumberInput = (NumberInput);


// CONCATENATED MODULE: ./node_modules/absol-acomp/js/NumberSpanInput.js



var NumberSpanInput_ = ACore["d" /* default */]._;
var NumberSpanInput_$ = ACore["d" /* default */].$;


/***
 * @extends  AElement
 * @constructor
 */
function NumberSpanInput() {
    this.ev_keydown = this.ev_keydown.bind(this);
    this.on('keydown', this.ev_keydown, true);
    this.readOnly = false;
    this.value = 0;
    this.on('paste', function (event) {
        event.preventDefault();
    })
}

NumberSpanInput.tag = 'NumberSpanInput'.toLowerCase();
NumberSpanInput.render = function () {
    return NumberSpanInput_({ tag: 'span', child: { text: '' } });
};

NumberSpanInput.prototype.selectAll = function(){
    var sel;
    if (window.getSelection) {
        sel = window.getSelection();
        sel.removeAllRanges();
        var range = document.createRange();
        range.selectNode(this.childNodes[this.childNodes.length - 1]);
        sel.addRange(range);
    } else {
        console.error("TimePicker: Not support!")
    }
};

NumberSpanInput.prototype.selectEnd = function(){
    var sel;
    if (window.getSelection) {
        sel = window.getSelection();
        sel.removeAllRanges();
        this._autoAddZero();
        var length = this.firstChild.data.length;
        var range = document.createRange();
        range.setStart(this.firstChild, length);
        range.setEnd(this.firstChild, length);
        sel.addRange(range);
    } else {
        console.error("TimePicker: Not support!")
    }
};

NumberSpanInput.prototype.selectNone = function(){
    var sel;
    if (document.activeElement === this){
        sel = window.getSelection();
        sel.removeAllRanges();
    }
}

NumberSpanInput.prototype._autoAddZero = function (){
    if (!this.firstChild){
        this.addChild(NumberSpanInput_({text:'0'}));
    }
}

/***
 *
 * @param {KeyboardEvent} event
 */
NumberSpanInput.prototype.ev_keydown = function (event) {
    if (event.key && event.key.length == 1 && !event.ctrlKey && !event.altKey) {
        if (event.key.match(/[0-9]/)) {

        }
        else {
            event.preventDefault();
        }
    }
    else if (event.key == 'Enter'){
        event.preventDefault();
    }
};


NumberSpanInput.property = {};

NumberSpanInput.property.readOnly = {
    set: function (value) {
        this.contentEditable = !value;
    },
    get: function () {
        return this.contentEditable === false|| this.contentEditable === 'false';
    }
};

/***
 *
 * @type {NumberSpanInput}
 */
NumberSpanInput.property.value = {
    set: function (value) {
        this._autoAddZero();
        this.firstChild.data = value + '';
    },
    get: function () {
        return (this.firstChild && this.firstChild.data)||'';
    }
}

ACore["d" /* default */].install(NumberSpanInput);

/* harmony default export */ var js_NumberSpanInput = (NumberSpanInput);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/OnsScreenWindow.js
var OnsScreenWindow = __webpack_require__(55);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/pageselector.css
var pageselector = __webpack_require__(183);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/PageSelector.js




var PageSelector_ = ACore["d" /* default */]._;
var PageSelector_$ = ACore["d" /* default */].$;

function PageSelector() {
    this.$pageInput = PageSelector_$('.absol-page-number-input input', this);
    this.$pageInput.on('keyup', this.eventHandler.pressEnterKey);
    this.$prevBtn = PageSelector_$('li.page-previous', this);
    this.$nextBtn = PageSelector_$('li.page-next', this);
    this.$firstBtn = PageSelector_$('li.page-first', this);
    this.$lastBtn = PageSelector_$('li.page-last', this);
    this.$nextBtn.on('click', this.eventHandler.clickNext);
    this.$prevBtn.on('click', this.eventHandler.clickPrev);
    this.$firstBtn.on('click', this.eventHandler.clickFirst);
    this.$lastBtn.on('click', this.eventHandler.clickLast);
    this.$buttonContainer = PageSelector_$('.absol-page-number-buttons', this);
    this._buttons = [];
    this._pageOffset = 1;
    this._selectedIndex = 1;
    this._pageCount = 1;
    this._pageRange = 1;
    this.$pageInput.value = this._selectedIndex;
}

PageSelector.tag = 'PageSelector'.toLowerCase();

PageSelector.render = function (){
    return PageSelector_({
        class: ['absol-page-selector'],
        extendEvent: ['change'],
        child:
            [
                {
                    class: 'absol-page-number-input',
                    child: [{
                        tag: 'label',
                        child: { text: "Page" }
                    },
                        {
                            tag:'input',
                            attr:{
                                type:'text'
                            }
                        }]
                },

                {
                    tag: 'ul',
                    class: 'absol-page-number-buttons',
                    child: [
                        ' <li class="page-first">\
                        <a aria-controls="dtBasicExample" data-dt-idx="0" tabindex="0" class="absol-page-link">First</a>\
                    </li>',
                        ' <li class="page-previous">\
                        <a aria-controls="dtBasicExample" data-dt-idx="0" tabindex="0" class="absol-page-link">Previous</a>\
                    </li>',

                        '<li class="page-next" >\
                        <a aria-controls="dtBasicExample" data-dt-idx="7" tabindex="0" class="absol-page-link">Next</a>\
                    </li>',
                        ' <li class="page-last">\
                        <a aria-controls="dtBasicExample" data-dt-idx="0" tabindex="0" class="absol-page-link">Last</a>\
                    </li>',
                    ]
                }
            ]
    });
}


PageSelector.eventHandler = {};

PageSelector.eventHandler.pressEnterKey = function(event){
    if (event.keyCode != 13) return;
    var index = parseInt(this.$pageInput.value.trim(), 10);
    if ((index < 1) || (index > this._pageCount)) {
        this.$pageInput.value = this._selectedIndex;
        return;
    }
    this.selectPage(index, true);
}

PageSelector.eventHandler.clickLast = function (event) {
    this.selectPage(this._pageCount, true);
};

PageSelector.eventHandler.clickFirst = function (event) {
    this.selectPage(1, true);
};

PageSelector.eventHandler.clickNext = function (event) {
    if (this._selectedIndex == this._pageCount) return;
    this.selectPage(this._selectedIndex + 1, true);
};

PageSelector.eventHandler.clickPrev = function (event) {
    if (this._selectedIndex == 1) return;
    this.selectPage(this._selectedIndex - 1, true);
}


PageSelector.eventHandler.clickIndex = function (index, event) {
    this.selectPage(index + this._pageOffset, true);
};

PageSelector.prototype._createButton = function (index) {
    var button = PageSelector_({
        tag: 'li',
        class: 'absol-page-number',
        child: {
            tag: 'a',
            attr: {  'data-index': index },
            child: { text: '' + index }
        },
        on: {
            click: PageSelector.eventHandler.clickIndex.bind(this, index)
        }
    });
    this.$buttonContainer.addChildBefore(button, this.$nextBtn);
    return button;
};

PageSelector.prototype.setPageRange = function (pageCount) {
    this._pageRange = pageCount;
    if (this._buttons.length > 0) throw new Error("Not implement change pageCount");
    while (this._buttons.length < pageCount) {
        this._buttons.push(this._createButton(this._buttons.length));
    }
};

PageSelector.prototype.setStartPage = function (index) {
    this._buttons.forEach(function (e, i) {
        e.childNodes[0].innerHTML = i + index + '';
    });
    this._pageOffset = index;
};

PageSelector.prototype.selectPage = function (index, userActive) {
    if (index == this._selectedIndex) this.setStartPage(index - parseInt(this._pageRange / 2));
    if (index > this._selectedIndex){
        if (index == (this._pageOffset + this._pageRange - 1)) this.setStartPage(index - parseInt(this._pageRange / 2));
    }
    if (index < this._selectedIndex){
        if (index == this._pageOffset) this.setStartPage(index - parseInt(this._pageRange / 2));
    }

    if (index > (this._pageCount - parseInt(this._pageRange / 2))) this.setStartPage(this._pageCount - this._pageRange + 1);
    if (index <= (parseInt(this._pageRange / 2))) this.setStartPage(1);

    var pageOffset = this._pageOffset;
    this._buttons.forEach(function (e, i) {
        if (i + pageOffset == index) {
            e.addClass('active');
        }
        else {
            e.removeClass('active');
        }
    });
    if (this._selectedIndex != index) {
        this._selectedIndex = index;
        this.$pageInput.value = index;
        this.emit('change', { target: this, selectedIndex: index, userActive: !!userActive }, this);
    }
};

PageSelector.prototype.getSelectedPage = function () {
    return this._selectedIndex;
}

PageSelector.prototype.setPageCount = function (count) {
    this._pageCount = count;
};

PageSelector.property = {};

PageSelector.prototype.init = function (props) {
    props = props || {};
    props.pageOffset = props.pageOffset || 1;
    props.pageRange = props.pageRange || 5;
    props.pageCount = props.pageCount || 15;
    props.selectedIndex = typeof (props.selectedIndex) == "number" ? props.selectedIndex : props.pageOffset;
    if (props.pageCount < props.pageRange) props.pageRange = props.pageCount;
    this.setPageCount(props.pageCount);
    this.setPageRange(props.pageRange);
    this.setStartPage(props.pageOffset);
    this.selectPage(props.selectedIndex);
};


ACore["d" /* default */].install(PageSelector);

/* harmony default export */ var js_PageSelector = (PageSelector);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/preinput.css
var preinput = __webpack_require__(185);

// EXTERNAL MODULE: ./node_modules/absol/src/Detector/BrowserDetector.js
var BrowserDetector = __webpack_require__(10);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/PreInput.js







var PreInput_ = ACore["d" /* default */]._;
var PreInput_$ = ACore["d" /* default */].$;
var textDelay = BrowserDetector["a" /* default */].isSafari ? 100 : 1;


/***
 * @extends AElement
 * @constructor
 */
function PreInput() {
    this.defineEvent(['pasteimg', 'pastetext', 'change']);
    this.on('paste', this.eventHandler.paste);
    this.on('keydown', this.eventHandler.keydown);
    this.history = [];
    this.value = '';
    this.historyIndex = -1;
    this.commitChange('', 0);
}


PreInput.tag = 'preinput';
PreInput.render = function () {
    return PreInput_({
        tag: 'pre',
        class: 'as-preinput',
        attr: {
            contenteditable: 'true'
        },
        child: 'br'
    });
};

PreInput.prototype.applyData = function (text, offset) {
    var textNode = PreInput_({ text: text });
    this.clearChild()
        .addChild(textNode).addChild(PreInput_('br'));

    if (document.activeElement === this && this.isDescendantOf(document.body)) {
        if (document.getSelection) {
            var sel = document.getSelection();
            sel.removeAllRanges();
            var range = document.createRange();
            if (typeof offset == 'number') {
                range.setStart(textNode, Math.min(text.length, offset));
            }
            else {
                range.setStart(textNode, Math.min(text.length, offset.start));
                range.setEnd(textNode, Math.min(text.length, offset.end));
            }
            sel.addRange(range);
            this.scrollIntoRange(range);

        }
        else {
            console.error("PreInput: Not support!");
        }
    }
};


PreInput.prototype.select = function (offset){
    if (document.activeElement !== this) this.focus();
    this.applyData(this.value, offset);
};

PreInput.prototype.scrollIntoRange = function (range) {
    var elementBound = range.getBoundingClientRect();

    var viewportBound = this.getBoundingClientRect();
    var dBottom = 0;
    if (range.startContainer && range.startContainer.data && range.startContainer.data.charAt(range.startContainer.data.length - 1) == '\n')
        dBottom += this.getFontSize() * 1.5;
    var currentScrollTop = this.scrollTop;
    var newScrollTop = currentScrollTop;
    if (elementBound.bottom + dBottom > viewportBound.bottom) {
        newScrollTop = currentScrollTop + (elementBound.bottom + dBottom - viewportBound.bottom);
    }
    if (elementBound.top < viewportBound.top) {
        newScrollTop = currentScrollTop - (viewportBound.top - elementBound.top);
    }

    if (newScrollTop != currentScrollTop) {
        this.scrollTop = newScrollTop;
    }

    var currentScrollLeft = this.scrollLeft;
    var newScrollLeft = currentScrollLeft;
    if (elementBound.right > viewportBound.right) {
        newScrollLeft = currentScrollLeft + (elementBound.right - viewportBound.right);
    }
    if (elementBound.left < viewportBound.left) {
        newScrollLeft = currentScrollLeft - (viewportBound.left - elementBound.left);
    }

    if (newScrollLeft != currentScrollLeft) {
        this.scrollLeft = newScrollLeft;
    }
};

PreInput.prototype.undo = function () {
    if (this.historyIndex <= 0) return;
    this.historyIndex--;
    var record = this.history[this.historyIndex];
    this.applyData(record.text, record.offset);
    this.emit('change', { target: this, value: record.text, action: 'undo', record: record, type: 'change' }, this);
};


PreInput.prototype.redo = function () {
    if (this.historyIndex + 1 >= this.history.length) return;
    this.historyIndex++;
    var record = this.history[this.historyIndex];
    this.applyData(record.text, record.offset);
    this.emit('change', { target: this, value: record.text, action: 'redo', record: record, type: 'change' }, this);
};


PreInput.prototype.commitChange = function (text, offset) {
    while (this.historyIndex < this.history.length - 1) {
        this.history.pop();
    }
    var lastText = this.history.length > 0 ? this.history[this.history.length - 1].text : null;
    if (text === lastText) {
        if (this.history[this.history.length - 1].offset != offset)
            this.history[this.history.length - 1].offset = offset;
    }
    else {
        this.historyIndex = this.history.length;
        var record = {
            text: text,
            offset: offset
        };
        this.history.push(record);
        this.emit('change', {
            target: this,
            value: record.text,
            action: 'commit',
            record: record,
            type: 'change'
        }, this);
    }
};

PreInput.prototype.waitToCommit = function (text, offset) {
    var thisInput = this;
    if (this._commitTimeout > 0)
        clearTimeout(this._commitTimeout);
    this._commitTimeout = setTimeout(function () {
        thisInput.commitChange(text, offset);
    }, textDelay);
};

PreInput.prototype.getPosition = function (node, offset) {
    if (!node) return NaN;
    if (node == this)
        return offset;
    var parent = node.parentElement;
    if (!parent) return NaN;
    var text = '';
    var child;
    var lastBr = false;
    for (var i = 0; i < parent.childNodes.length; ++i) {
        child = parent.childNodes[i];
        if (child == node) break;
        text += this.stringOf(child);
    }
    return this.getPosition(parent, text.length + offset);
};


PreInput.prototype.getSelectPosition = function () {
    if (window.getSelection) {
        var sel = window.getSelection();
        if (sel.getRangeAt && sel.rangeCount) {
            var range = sel.getRangeAt(0);
            var direction = 'forward';
            var cmpPosition = sel.anchorNode.compareDocumentPosition(sel.focusNode);
            if (cmpPosition === 4) {
                direction = 'forward';
            }
            else if (cmpPosition === 2) {
                direction = 'backward'
            }
            else if (!cmpPosition && sel.anchorOffset > sel.focusOffset ||
                cmpPosition === Node.DOCUMENT_POSITION_PRECEDING){
                direction = 'backward';
            }
            var startOffset = this.getPosition(range.startContainer, range.startOffset);
            var endOffset = this.getPosition(range.endContainer, range.endOffset);
            if (isNaN(startOffset)) return null;
            return {
                start: startOffset, end: endOffset, direction: direction
            }
        }
    }
    else if (document.selection) {
        console.error('May not support!');
    }
};

PreInput.prototype.stringOf = function (node) {
    if (!node) return '';
    if (node.nodeType == 3) {
        return node.data;
    }
    if (node.tagName == 'BR' || node.tagName == 'br') {
        return '\n';
    }
    var thisInput = this;

    return Array.prototype.map.call(node.childNodes, function (cNode, index, arr) {
        if ((cNode.tagName == 'BR' || cNode.tagName == 'br') && (index + 1 >= arr.length)) return '';
        return thisInput.stringOf(cNode);
    }).join('');

}


PreInput.prototype._pasteText = function (text) {
    var sel = window.getSelection();
    var range;
    if (window.getSelection) {

        sel = window.getSelection();
        if (sel.getRangeAt && sel.rangeCount) {
            try {

                range = sel.getRangeAt(0);
                range.deleteContents();

                var textNode = PreInput_({ text: text });
                range.insertNode(textNode);
                if (sel.removeRange) {
                    sel.removeRange(range);
                }
                else {
                    sel.removeAllRanges();
                }
                range = document.createRange();
                range.setStart(textNode, text.length);
                sel.addRange(range);
                this.scrollIntoRange(range);
                this.commitChange(this.stringOf(this), this.getPosition(textNode, text.length));
            } catch (error) {
                alert(error.message)
            }
        }
    }
    else if (document.selection && document.selection.createRange) {
        document.selection.createRange().text = text;
        this.commitChange(this.stringOf(this), this.getPosition(textNode, text.length));
        console.error('May not support!');
    }
};


/**
 * @type {PreInput}
 */
PreInput.eventHandler = {};


PreInput.eventHandler.paste = function (event) {
    var thisIp = this;
    var clipboardData = (event.clipboardData || window.clipboardData);
    /**Safari bug */
    if (clipboardData) {
        if (clipboardData.items) {
            var items = Array.prototype.slice.call(clipboardData.items);
            var imgItems = items.filter(function (item) {
                return item.type.indexOf('image') >= 0;
            });

            var plainTextItems = items.filter(function (item) {
                return item.type.indexOf('text/plain') >= 0;
            });

            if (imgItems.length > 0) {
                var imgFiles = imgItems.map(function (it) {
                    return it.getAsFile();
                });
                this.emit('pasteimg', {
                    target: this,
                    imageFile: imgFiles[0],
                    imageFiles: imgFiles,
                    orginEvent: event
                }, this);
            }
            else if (plainTextItems.length > 0) {

                var plainTextItem = plainTextItems[0];//only one item
                plainTextItem.getAsString(function (text) {
                    thisIp._pasteText(text);
                });
            }
            else {
                window.ABSOL_DEBUG && console.error("Can not handle clipboard data");
            }
            event.preventDefault();
        }
        else {
            var text = event.clipboardData.getData('text/plain');
            if (text) {
                event.preventDefault();
                this._pasteText(text);
            }
            else {
                var currentText = this.stringOf(this);
                var currentSelection = this.getSelectPosition();

                setTimeout(function () {
                    var images = [];
                    PreInput_$('img', thisIp, function (elt) {
                        images.push(elt);
                    });

                    Promise.all(images.map(function (img) {
                        return Dom["b" /* default */].imageToCanvas(img).then(function (canvas) {
                            var dataURI = canvas.toDataURL();
                            var blob = Object(Converter_file["dataURItoBlob"])(dataURI);
                            var file = Object(Converter_file["blobToFile"])(blob);
                            return {
                                file: file, blob: blob, url: dataURI
                            }
                        }, function (error) {
                            console.error(error)
                        }).catch(function (error) {
                            console.error(error)
                        });
                    })).then(function (results) {
                        results = results.filter(function (it) {
                            return !!it;
                        });
                        if (results.length > 0) {
                            var imgFiles = results.map(function (it) {
                                return it.file
                            });
                            var urls = results.map(function (it) {
                                return it.url
                            });
                            thisIp.emit('pasteimg', {
                                target: this,
                                imageFile: imgFiles[0],
                                imageFiles: imgFiles,
                                urls: urls,
                                url: urls[0],
                                orginEvent: event
                            }, thisIp);
                        }
                    });
                    thisIp.applyData(currentText, currentSelection);
                }, textDelay);

            }
        }
    }
    else {
        setTimeout(function () {
            if (window.getSelection) {
                var sel = window.getSelection();
                if (sel.getRangeAt && sel.rangeCount) {
                    var range = sel.getRangeAt(0);
                    var text = this.stringOf(this);
                    var offset = this.getPosition(range.startContainer, range.startOffset);
                    this.waitToCommit(text, offset);
                }
            }
            else if (document.selection) {
                console.error('May not support!');
            }
        }.bind(this), textDelay);
    }
};


PreInput.eventHandler.keydown = function (event) {
    if (event.ctrlKey) {
        switch (event.key) {
            case 'z':
                this.undo();
                event.preventDefault();
                break;
            case 'y':
                this.redo();
                event.preventDefault();
                break;

            default:
                break;
        }
    }
    if (!event.ctrlKey && !event.altKey) {
        setTimeout(function () {
            if (window.getSelection) {
                var sel = window.getSelection();
                if (sel.getRangeAt && sel.rangeCount) {
                    var range = sel.getRangeAt(0);
                    var text = this.stringOf(this);
                    var offset = this.getPosition(range.startContainer, range.startOffset);
                    this.waitToCommit(text, offset);
                }
            }
            else if (document.selection) {
                console.error('May not support!');
            }
        }.bind(this), textDelay);
    }
};

PreInput.property = {};

PreInput.property.value = {
    set: function (value) {
        value = value || '';
        this.applyData(value, value.length);
        this.commitChange(value, value.length);
    },
    get: function () {
        return this.stringOf(this);
    }
};

PreInput.property.disabled = {
    set: function (value) {
        value = !!value;
        if (value === this.containsClass('as-disabled')) return;
        if (value) {
            this.addClass('as-disabled');
            this.attr({
                contenteditable: undefined,
                oncut: 'return false',
                onpaste: 'return false',
                onkeydown: 'if(event.metaKey) return true; return false;'
            });
        }
        else {
            this.removeClass('as-disabled');
            this.attr({
                contenteditable: true,
                oncut: undefined,
                onpaste: undefined,
                onkeydown: undefined
            });
        }
    },
    get: function () {
        return this.containsClass('as-disabled');
    }
}


ACore["d" /* default */].install(PreInput);

/* harmony default export */ var js_PreInput = (PreInput);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/progressbar.css
var progressbar = __webpack_require__(187);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/ProgressBar.js



var ProgressBar_ = ACore["d" /* default */]._;
var ProgressBar_$ = ACore["d" /* default */].$;


function ProgressBar() {
    this._value = 0;
    this._variant = null;
    this.$value = ProgressBar_$('.as-progress-bar-value', this);
    this._striped = false;
    this._animated = false;
}

ProgressBar.tag = 'ProgressBar'.toLowerCase();
ProgressBar.render = function () {
    return ProgressBar_({
        class: 'as-progress-bar',
        child: {
            class: 'as-progress-bar-value'
        }
    });
};


ProgressBar.property = {};


/**
 * @type {ProgressBar}
 */
ProgressBar.property.variant = {
    set: function (value) {
        if (this._variant) {
            this.removeClass('as-variant-' + this._variant);
        }
        if (value) {
            this.addClass('as-variant-' + value)
        }
        else {
            value = null;
        }
        this._variant = value;
    },
    get: function () {
        return this._variant;
    }

};

/**
 * @type {ProgressBar}
 */
ProgressBar.property.value = {
    set: function (value) {
        value = Math.max(0, Math.min(1, value || 0));
        this._value = value;
        this.$value.addStyle('width', value * 100 + '%');

    },
    get: function () {
        return this._value;
    }
};


ProgressBar.property.animated = {
    set: function (value) {
        value = !!value;
        this._striped = value;
        if (value) {
            this.addClass('as-animated');
        }
        else {
            this.removeClass('as-animated');
        }
    },
    get: function () {
        return this._animated;
    }
}

ProgressBar.property.striped = {
    set: function (value) {
        value = !!value;
        this._striped = value;
        if (value) {
            this.addClass('as-striped');
        }
        else {
            this.removeClass('as-striped');
        }
    },
    get: function () {
        return this._striped;
    }
}


ACore["d" /* default */].install(ProgressBar);


/* harmony default export */ var js_ProgressBar = (ProgressBar);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/quicklistbutton.css
var quicklistbutton = __webpack_require__(189);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/FollowerToggler.js




var FollowerToggler_ = ACore["d" /* default */]._;
var FollowerToggler_$ = ACore["d" /* default */].$;

/***
 * @extends AElement
 * @constructor
 */
function FollowerToggler() {
    this.defineEvent(['close', 'open', 'preopen']);
    this.on('click', this.eventHandler.click);
    this.addClass('as-follower-trigger');
    this.$follower = null;
    this._opened = false;
}

FollowerToggler.tag = 'FollowerToggler'.toLowerCase();

FollowerToggler.render = function () {
    return FollowerToggler_('div');
};

FollowerToggler.prototype.toggle = function () {
    if (this._opened) this.close();
    else this.open();
};

FollowerToggler.prototype.open = function () {
    if (this._opened) return;
    this._opened = true;
    this.addClass('as-follower-trigger-open');
    if (!this.$follower) return;
    this.emit('preopen', { name: 'preopen', target: this }, this);
    var thisTg = this;
    setTimeout(function () {
        thisTg.$follower.refollow();
        thisTg.$follower.removeClass('absol-follower-hidden');
        document.body.addEventListener('click', thisTg.eventHandler.clickBody);
        thisTg.emit('open', { name: 'open', target: this }, this);
    }, 1);
};

FollowerToggler.prototype.close = function () {
    if (!this._opened) return;
    this._opened = false;
    this.removeClass('as-follower-trigger-open');
    if (!this.$follower) return;
    this.$follower.unfollow();
    this.$follower.addClass('absol-follower-hidden');
    document.body.removeEventListener('click', this.eventHandler.clickBody);
    this.emit('close', { name: 'close', target: this }, this);
};


FollowerToggler.prototype.bindFollower = function (elt) {
    if (this.$follower) {
        this.$follower.followTarget = null;
    }
    if (elt && elt.refollow) {
        if (this._opened)
            elt.removeClass('absol-follower-hidden');
        else
            elt.addClass('absol-follower-hidden');
        elt.followTarget = this;
        this.$follower = elt;
    }
    else {
        throw new Error("Must be a follower!");
    }
}

FollowerToggler.eventHandler = {};

FollowerToggler.eventHandler.clickBody = function (event) {
    if (EventEmitter["b" /* default */].hitElement(this, event) || EventEmitter["b" /* default */].hitElement(this.$follower, event))
        return;
    this.close();
};


FollowerToggler.eventHandler.click = function () {
    this.toggle();
};

ACore["d" /* default */].install(FollowerToggler);

/* harmony default export */ var js_FollowerToggler = (FollowerToggler);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/QuickListButton.js




 var QuickListButton_ = ACore["d" /* default */]._;
var QuickListButton_$ = ACore["d" /* default */].$;

/****
 * @extends FollowerToggler
 * @constructor
 */
function QuickListButton() {
    this.$shareFollower = QuickListButton.getFollower();
    QuickListButton_({
        tag: 'followertoggler', elt: this,
        on: {
            preopen: this.eventHandler.preopen,
            close: this.eventHandler.closeFollower
        }
    });
    this.bindFollower(this.$shareFollower);
    this.$iconCtn.remove();
    this.$content.addChild(this.$iconCtn);
    this._items = this._items;
    this._anchor = [];
    this.$list = null;
    this._listUpdated = true;
    this._opened = false;
    this.anchor = [12, 13, 15, 14];//todo: add property
}


QuickListButton.$follower = QuickListButton_('follower.as-quick-list-button-follower');

QuickListButton.getFollower = function () {
    if (!QuickListButton.$follower)
        QuickListButton.$follower = QuickListButton_('follower.as-quick-list-button-follower');
    return QuickListButton.$follower;
};

QuickListButton.tag = 'QuickListButton'.toLowerCase();

QuickListButton.render = function () {
    return QuickListButton_({
        tag: 'flexiconbutton',
        class: 'as-quick-list-button',
        extendEvent: 'select',
        props: {
            text: "+ Thêm",
            icon: 'span.mdi.mdi-menu-down'
        }
    });
};


QuickListButton.property = {};

QuickListButton.property.items = {
    set: function (value) {
        value = value || [];
        this._items = value;
        this._listUpdated = false;
    },
    get: function () {
        return this._items;
    }
};

/**
 * @type {QuickListButton}
 */
QuickListButton.eventHandler = {};


QuickListButton.eventHandler.preopen = function () {
    this.$shareFollower.addTo(document.body);
    this.$shareFollower.anchor = this.anchor;
    if (this.$list == null) {
        this.$list = QuickListButton_('selectlist.absol-bscroller')
            .on('pressitem', this.eventHandler.pressitem);
    }
    if (!this._listUpdated) {
        this._listUpdated = true;
        this.$list.items = this._items;
    }
    this.$shareFollower.addChild(this.$list);
    this.$shareFollower.on({
        preupdateposition: this.eventHandler.preUpdatePosition,
    });

};

QuickListButton.eventHandler.preUpdatePosition = function () {
    var bound = this.getBoundingClientRect();
    var screenSize = Dom["b" /* default */].getScreenSize();
    var maxHeight = Math.max(screenSize.height - bound.bottom, bound.top) - 10;
    this.$list.addStyle('max-height', maxHeight + 'px');
};

QuickListButton.eventHandler.closeFollower = function () {
    this.$shareFollower.off({
        preupdateposition: this.eventHandler.preUpdatePosition
    });
};

QuickListButton.eventHandler.pressitem = function (event) {
    this.close();
    this.emit('select', Object.assign({}, event, { type: 'select', target: this }));
};


ACore["d" /* default */].install(QuickListButton);

/* harmony default export */ var js_QuickListButton = (QuickListButton);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/SelectList.js
var SelectList = __webpack_require__(45);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/QuickMenu.js
var QuickMenu = __webpack_require__(27);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/quickpath.css
var quickpath = __webpack_require__(194);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/QuickPath.js




var QuickPath_ = ACore["d" /* default */]._;
var QuickPath_$ = ACore["d" /* default */].$;

function QuickPath() {
    this._holders = [];
}

/**
 * @type {QuickPath}
 */
QuickPath.eventHandler = {};

QuickPath.eventHandler.click = function (event) {
    var button = this._fileButton(event.target)
    if (button) this.pressButton(button);
};

QuickPath.tag = 'QuickPath'.toLowerCase();

/**
 * @returns {QuickPath}
 */
QuickPath.render = function () {
    return QuickPath_({
        class: 'absol-quick-path',
        extendEvent: ['change', 'press']
    });
};


QuickPath.prototype.updatePath = function () {
    this.clearChild();
    var self = this;
    this._holders = this._path.map(function (data, index) {
        var holder = self._createButton(data, index);
        holder.buttom.addTo(self);
        return holder;
    })


};

QuickPath.prototype._createButton = function (pathItem, index) {
    var buttom = QuickPath_({
        tag: 'expnode',
        class: 'absol-quick-path-btn',
        attr: {
            'data-index': '' + index
        }
    });
    buttom.status = 'close';
    buttom.name = pathItem.name;
    if (pathItem.icon) {
        buttom.icon = pathItem.icon;
    }
    if (pathItem.iconSrc) {
        buttom.icon = { tag: 'img', props: { src: pathItem.iconSrc } };
    }
    var thisQuickpath = this;

    if (pathItem.items) {
        QuickMenu["a" /* default */].toggleWhenClick(buttom,
            {
                getAnchor: function () {
                    return [1, 2, 6, 5];
                },
                getMenuProps: function () {
                    return {
                        extendStyle: {
                            fontSize: buttom.getComputedStyleValue('font-size')
                        },
                        items: pathItem.items.map(function (it, menuIndex) {
                            var res = {
                                text: it.name,
                                menuIndex: menuIndex,
                                icon: it.iconSrc ? { tag: 'img', props: { src: it.iconSrc } } : (it.icon || undefined),
                                extendStyle: it.extendStyle || {},
                                extendClass: it.extendClass || [],
                            }
                            return res;
                        })
                    }
                },
                onOpen: function () {
                    buttom.status = 'open';
                    thisQuickpath.emit('press', {
                        target: thisQuickpath,
                        pathItem: pathItem,
                        index: index
                    }, thisQuickpath);

                },
                onClose: function () {
                    buttom.status = 'close';
                },
                onSelect: function (item) {
                    var dataItem = pathItem.items[item.menuIndex];
                    thisQuickpath.emit('change', {
                        target: thisQuickpath,
                        pathItem: pathItem,
                        item: dataItem,
                        index: index
                    }, thisQuickpath);
                    thisQuickpath.status = 'close';

                }
            })
    }
    else {
        buttom.on('click', function () {
            this.emit('press', { target: thisQuickpath, pathItem: pathItem, index: index }, thisQuickpath);
        });
    }

    return { buttom: buttom };
}

QuickPath.prototype.push = function (item) {
    this.path.push(item);
    var holder = this._createButton(item, this.path.length - 1);
    this.addChild(holder, buttom);
    this._holders.push(holder);
};

QuickPath.prototype.clear = function () {
    this.path = [];
    this._holders = [];
}


QuickPath.prototype.pop = function () {
    //todo
    var res = this.path.pop();
    var button = QuickPath_$('button[data-index="' + this.path.length + '"]');
    if (button) button.remove();
    return res;
};


QuickPath.property = {};

/**
 * @typedef PathElement
 * @property {String} name
 * @property {String} icon
 * @property {Array<String>} items
 *
 */

QuickPath.property.path = {
    /**
     * @param {Array<PathElement>} value
     */
    set: function (value) {
        this._path = value || [];
        this.updatePath();
    },
    get: function () {
        return this._path || [];
    }
};


QuickPath.property.textPath = {
    get: function () {
        return this.path.join('/');
    }
};

ACore["d" /* default */].install('quickpath', QuickPath);

/* harmony default export */ var js_QuickPath = (QuickPath);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/RadioButton.js
var RadioButton = __webpack_require__(72);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Radio.js
var Radio = __webpack_require__(73);

// EXTERNAL MODULE: ./node_modules/absol/src/Network/XHR.js
var XHR = __webpack_require__(59);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/RemoteSvg.js



var RemoteSvg_ = ACore["d" /* default */]._;
var RemoteSvg_$ = ACore["d" /* default */].$;


function RemoteSvg() {

}

RemoteSvg.tag = 'RemoteSvg'.toLowerCase();

RemoteSvg.render = function () {
    return RemoteSvg_('svg').defineEvent('load');
};

RemoteSvg.property = {
    src: {
        set: function (value) {
            this._src = value;
            var self = this;
            RemoteSvg.loadIcon(value).then(function (data) {
                self.emit('load', { target: self, src: value, data: data }, self);
                self.attr(data.attr);
                self.init(data.props);
            });
        },
        get: function () {
            return this._name;
        }
    }
};


RemoteSvg.attribute = {
    src: {
        set: function (value) {

        },
        get: function () {

        },
        remove: function () {

        }
    }
};

RemoteSvg.__cache__ = {};

RemoteSvg.__div_parser__ = document.createElement('div');

RemoteSvg.loadIcon = function (path) {
    if (RemoteSvg.__cache__[path]) {
        return RemoteSvg.__cache__[path];
    }
    else {
        RemoteSvg.__cache__[path] = XHR["a" /* default */].getRequest(path, 'text').then(function (result) {
            RemoteSvg.__div_parser__.innerHTML = result;

            var svgElt = RemoteSvg_$('svg', RemoteSvg.__div_parser__);
            var res = {
                attr: {},
                props: {}
            };
            if (svgElt) {
                Array.prototype.forEach.call(svgElt.attributes, function (attribute) {
                    res.attr[attribute.name] = attribute.value;
                });
                res.props.innerHTML = svgElt.innerHTML;
            }
            return res;

        }, function () {
            return {};
        });
        return RemoteSvg.__cache__[path];
    }

};


ACore["d" /* default */].install(RemoteSvg);


/* harmony default export */ var js_RemoteSvg = (RemoteSvg);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/resizebox.css
var resizebox = __webpack_require__(200);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/ResizeBox.js





var ResizeBox_ = ACore["d" /* default */]._;
var ResizeBox_$ = ACore["d" /* default */].$;


function ResizeBox() {
    this.on('mousedown', this.eventHandler.mouseDownBody);
    this._mousedownEventData = undefined;
    this._mousemoveEventData = undefined;
    this._lastClickTime = 0;
}

ResizeBox.tag = 'ResizeBox'.toLowerCase();

ResizeBox.render = function () {
    return ResizeBox_({
        class: 'as-resize-box',
        extendEvent: ['beginmove', 'endmove', 'moving', 'click', 'dblclick'],//override click event
        child: {
            class: 'as-resize-box-body',
            child: [
                '.as-resize-box-dot.left-top',
                '.as-resize-box-dot.top',
                '.as-resize-box-dot.right-top',
                '.as-resize-box-dot.right',
                '.as-resize-box-dot.right-bottom',
                '.as-resize-box-dot.bottom',
                '.as-resize-box-dot.left-bottom',
                '.as-resize-box-dot.left'
            ]
        }

    });
};

ResizeBox.eventHandler = {};

ResizeBox.eventHandler.mouseDownBody = function (event) {
    if (EventEmitter["b" /* default */].isMouseRight(event)) return;
    event.preventDefault();
    this._optionNames = event.target.attr('class').match(/body|left|top|right|bottom/g);
    var option = this._optionNames.reduce(function (ac, key) {
        ac[key] = true;
        return ac;
    }, {});

    this._mousedownEventData = {
        clientX: event.clientX,
        clientY: event.clientY,
        target: this,
        originEvent: event,
        prevented: false,
        preventDefault: function () {
            this.prevented = true;
        },
        option: option,
        begin: false,
        type: 'beginmove'
    };

    ResizeBox_$(document.body).on('mousemove', this.eventHandler.mouseMoveBody);
    ResizeBox_$(document.body)
        .on('mouseup', this.eventHandler.mouseFinishBody)
        .on('mouseleave', this.eventHandler.mouseFinishBody);

};

ResizeBox.eventHandler.mouseMoveBody = function (event) {
    if (this._mousedownEventData.option.body && !this.canMove) return;
    if (this._mousedownEventData && !this._mousedownEventData.begin && !this._mousedownEventData.prevented) {
        this.emit('beginmove', this._mousedownEventData, this);
        if (this._mousedownEventData.prevented) {
            ResizeBox_$(document.body).off('mousemove', this.eventHandler.mouseMoveBody);
        }
        else {
            this._mousedownEventData.begin = true;
            ResizeBox_$(document.body)
                .addClass('as-resize-box-overiding')
                .addClass(this._optionNames.join('-'));
        }

    }


    if (this._mousedownEventData.begin) {
        event.preventDefault();
        this._mousemoveEventData = {
            clientX: event.clientX,
            clientY: event.clientY,
            clientX0: this._mousedownEventData.clientX,
            clientY0: this._mousedownEventData.clientY,
            clientDX: event.clientX - this._mousedownEventData.clientX,
            clientDY: event.clientY - this._mousedownEventData.clientY,
            target: this,
            originEvent: event,
            option: this._mousedownEventData.option,
            type: 'moving'
        };

        this.emit('moving', this._mousemoveEventData, this);
    }
};

ResizeBox.eventHandler.mouseFinishBody = function (event) {

    ResizeBox_$(document.body).off('mousemove', this.eventHandler.mouseMoveBody)
        .off('mouseup', this.eventHandler.mouseFinishBody)
        .off('mouseleave', this.eventHandler.mouseFinishBody)
        .removeClass('as-resize-box-overiding')
        .removeClass(this._optionNames.join('-'));
    this._optionNames = undefined;

    if (this._mousedownEventData.begin) {
        this._mousefinishEventData = {
            clientX: event.clientX,
            clientY: event.clientY,
            clientX0: this._mousedownEventData.clientX,
            clientY0: this._mousedownEventData.clientY,
            clientDX: event.clientX - this._mousedownEventData.clientX,
            clientDY: event.clientY - this._mousedownEventData.clientY,
            target: this,
            originEvent: event,
            option: this._mousedownEventData.option,
            type: 'endmove'
        };
        this.emit('endmove', this._mousefinishEventData, this);
    }
    else {
        if (EventEmitter["b" /* default */].hitElement(this, event)) {
            this.emit('click', event, this);
            var now = new Date().getTime();
            if (now - this._lastClickTime < 500) {
                this.emit('dblclick', event, this);
                this._lastClickTime = 0;
            }
            this._lastClickTime = now;
        }
    }
};


ResizeBox.property = {};

ResizeBox.property.canMove = {
    set: function (value) {
        if (value) {
            this.addClass('as-can-move');
        }
        else {
            this.removeClass('as-can-move');
        }
    },
    get: function () {
        return this.containsClass('as-can-move');
    }
};

ResizeBox.property.canResize = {
    set: function (value) {
        if (value) {
            this.addClass('as-can-resize');
        }
        else {
            this.removeClass('as-can-resize');
        }
    },
    get: function () {
        return this.containsClass('as-can-resize');
    }
};

ResizeBox.property.canClick = {
    set: function (value) {
        if (value) {
            this.addClass('as-can-click');
        }
        else {
            this.removeClass('as-can-click');
        }
    },
    get: function () {
        return this.containsClass('as-can-click');
    }
};

ACore["d" /* default */].install(ResizeBox);


/* harmony default export */ var js_ResizeBox = (ResizeBox);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Searcher.js
var Searcher = __webpack_require__(67);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/SelectBox.js
var SelectBox = __webpack_require__(68);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/SelectBoxItem.js
var SelectBoxItem = __webpack_require__(42);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/selecttable.css
var selecttable = __webpack_require__(95);

// EXTERNAL MODULE: ./node_modules/absol/src/String/stringMatching.js
var stringMatching = __webpack_require__(39);

// EXTERNAL MODULE: ./node_modules/absol/src/String/stringFormat.js
var stringFormat = __webpack_require__(15);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/SelectTable.js











var privateDom = new Dom["b" /* default */]().install(ACore["d" /* default */]);
var SelectTable_$ = privateDom.$;
var SelectTable_ = privateDom._;


function SelectTable() {
    var thisST = this;
    this.$attachhook = SelectTable_('attachhook').addTo(this);
    this.sync = new Promise(function (rs) {
        thisST.$attachhook.on('error', rs);
    });
    this.$buttonsContainer = SelectTable_$('.absol-select-table-buttons-container', this);
    this.$searchContainer = SelectTable_$('.absol-select-table-searchtextinput-container', this);
    this.$nonselectedItemsContainer = SelectTable_$('.absol-select-table-nonselected-items-container', this);
    this.$selectedItemsContainer = SelectTable_$('.absol-select-table-selected-items-container', this);

    this.$nonselectedSearchItemsContainer = SelectTable_$('.absol-select-table-nonselected-search-items-container', this);
    this.$selectedSearchItemsContainer = SelectTable_$('.absol-select-table-selected-search-items-container', this);

    this.$removeAllBtn = SelectTable_$('button.remove-all', this).on('click', this.eventHandler.removeAllBtnClick);
    this.$addAllBtn = SelectTable_$('button.add-all', this).on('click', this.eventHandler.addAllBtnClick);
    this.$vscrollerSelected = SelectTable_$('bscroller#selected', this)
    this.$vscrollerNonselected = SelectTable_$('bscroller#nonselected', this);
    this.$body = SelectTable_$('.absol-select-table-body', this);
    this.$header = SelectTable_$('.absol-select-table-header', this);
    /***
     *
     * @type {SearchTextInput}
     */
    this.$searchTextInput = SelectTable_$('searchtextinput', this).on('stoptyping', this.eventHandler.searchTextInputModify);
    this.$addAllBtn.updateSize = function () {
        thisST.updateScroller && thisST.updateScroller();
    };
    Dom["b" /* default */].addToResizeSystem(this.$addAllBtn);
    return this;
}

SelectTable.tag = 'SelectTable'.toLowerCase();

SelectTable.render = function () {
    return SelectTable_({
        class: 'absol-select-table',
        extendEvent: ['change', 'addall', 'removeall', 'add', 'remove'],
        child: [
            {
                class: 'absol-select-table-header',
                child: [
                    {
                        class: 'absol-select-table-searchtextinput-container',
                        child: 'searchtextinput'
                    },
                    {
                        class: 'absol-select-table-buttons-container',
                        child: [
                            {
                                tag: 'button',
                                class: 'add-all',
                                props: {
                                    innerHTML: 'Add All'
                                }
                            },
                            {
                                tag: 'button',
                                class: 'remove-all',
                                props: {
                                    innerHTML: 'Remove All'
                                }
                            }
                        ]
                    }

                ]
            },
            {
                class: 'absol-select-table-body',
                child: [

                    {
                        tag: 'bscroller',
                        attr: { id: 'nonselected' },
                        class: ['absol-select-table-items-scroller'],
                        child: {
                            child: ['.absol-select-table-nonselected-items-container', '.absol-select-table-nonselected-search-items-container']
                        }
                    },
                    {
                        tag: 'bscroller',
                        attr: { id: 'selected' },
                        class: ['absol-select-table-items-scroller'],
                        child: {
                            child: ['.absol-select-table-selected-items-container', '.absol-select-table-selected-search-items-container']

                        }

                    }
                ]
            }
        ]
    });
}


SelectTable.prototype.updateButtonsContainerSize = function () {
    var rootBound = this.$buttonsContainer.getBoundingClientRect();
    var containBound = this.$buttonsContainer.getBoundingRecursiveRect();
    var fontSize = this.getFontSize();
    this.$buttonsContainer.addStyle('width', (containBound.width + 1) / fontSize + 'em');
    this.$searchContainer.addStyle('right', (containBound.width + 5) / fontSize + 'em');
};

SelectTable.prototype.addAll = function () {
    Array.apply(null, this.$nonselectedItemsContainer.childNodes).forEach(function (e) {
        e.addTo(this.$selectedItemsContainer);
    }.bind(this));
    this.requestSort();
};

SelectTable.prototype.removeAll = function () {
    Array.apply(null, this.$selectedItemsContainer.childNodes).forEach(function (e) {
        e.addTo(this.$nonselectedItemsContainer);
    }.bind(this))
    this.requestSort();
};

SelectTable.prototype.updateScroller = function () {
    var update = function () {
        if (this.style.height) {
            var height = parseFloat(this.getComputedStyleValue('height').replace('px', ''));
            var headerHeight = parseFloat(this.$header.getComputedStyleValue('height').replace('px', ''));
            var bodyMargin = parseFloat(this.$body.getComputedStyleValue('margin-top').replace('px', ''));
            var borderWidth = 1;
            var availableHeight = height - headerHeight - bodyMargin * 2 - borderWidth * 2;
            this.$vscrollerNonselected.addStyle('max-height', availableHeight + 'px');
            this.$vscrollerSelected.addStyle('max-height', availableHeight + 'px');
        }
    }.bind(this);
    setTimeout(update, 1);
};

SelectTable.prototype.getAllItemElement = function () {
    var selectedItemElements = Array.apply(null, this.$selectedItemsContainer.childNodes);
    var nonselectedItemElements = Array.apply(null, this.$nonselectedItemsContainer.childNodes);
    return selectedItemElements.concat(nonselectedItemElements);
};

SelectTable.prototype.init = function (props) {
    this.super(props);
    this.sync = this.sync.then(this.updateButtonsContainerSize.bind(this));
};

SelectTable.eventHandler = {};
SelectTable.eventHandler.addAllBtnClick = function (event) {
    this.addAll();
    if (this.searching) {
        this.eventHandler.searchTextInputModify(event);
    }
    this.emit('addall', EventEmitter["b" /* default */].copyEvent(event, {}), this);
    this.updateScroller();
};

SelectTable.eventHandler.removeAllBtnClick = function (event) {
    this.removeAll();
    if (this.searching) {
        this.eventHandler.searchTextInputModify(event);
    }
    this.emit('removeall', EventEmitter["b" /* default */].copyEvent(event, {}), this);
    this.updateScroller();
};

SelectTable.prototype._filter = function (items, filterText) {
    var result = [];
    if (filterText.length == 1) {
        result = items.map(function (item) {
            var res = { item: item, text: typeof item === 'string' ? item : item.text };
            return res;
        }).map(function (it) {
            it.score = 0;
            var text = it.text.replace(/((\&nbsp)|(\s))+/g, ' ').trim();
            it.score += text.toLowerCase().indexOf(filterText.toLowerCase()) >= 0 ? 100 : 0;
            text = Object(stringFormat["nonAccentVietnamese"])(text);
            it.score += text.toLowerCase().indexOf(filterText.toLowerCase()) >= 0 ? 100 : 0;
            return it;
        });

        result.sort(function (a, b) {
            if (b.score - a.score == 0) {
                if (Object(stringFormat["nonAccentVietnamese"])(b.text) > Object(stringFormat["nonAccentVietnamese"])(a.text)) return -1;
                return 1;
            }
            return b.score - a.score;
        });
        result = result.filter(function (x) {
            return x.score > 0;
        });
    }
    else {
        var its = items.map(function (item) {
            var res = { item: item, text: typeof item === 'string' ? item : item.text };
            var text = res.text.replace(/((\&nbsp)|(\s))+/g, ' ').trim();
            res.score = (Object(stringMatching["phraseMatch"])(text, filterText)
                + Object(stringMatching["phraseMatch"])(Object(stringFormat["nonAccentVietnamese"])(text), Object(stringFormat["nonAccentVietnamese"])(filterText))) / 2;
            if (Object(stringFormat["nonAccentVietnamese"])(text).replace(/s/g, '').toLowerCase().indexOf(Object(stringFormat["nonAccentVietnamese"])(filterText).toLowerCase().replace(/s/g, '')) > -1)
                res.score = 100;
            return res;
        });
        if (its.length == 0) return;

        its.sort(function (a, b) {
            if (b.score - a.score == 0) {
                if (Object(stringFormat["nonAccentVietnamese"])(b.text) > Object(stringFormat["nonAccentVietnamese"])(a.text)) return -1;
                return 1;
            }
            return b.score - a.score;
        });
        var result = its.filter(function (x) {
            return x.score > 0.5;
        });
        if (result.length == 0) {
            var bestScore = its[0].score;
            result = its.filter(function (it) {
                return it.score + 0.001 >= bestScore;
            });
        }
        if (result[0].score == 0) result = [];
    }
    result = result.map(function (e) {
        return e.item;
    });

    return result;
};

SelectTable.prototype._stringcmp = function (s0, s1) {
    if (s0 == s1) return 0;
    if (s0 > s1) return 1;
    return -1;
};

SelectTable.prototype._getString = function (item) {
    if (typeof item == "string") return item;
    return item.text;
};

SelectTable.prototype._equalArr = function (a, b) {
    if (a.length != b.length) return false;
    for (var i = 0; i < a.length; ++i) {
        if (a[i] != b[i] && a[i].text != b[i].text && a[i].value != b[i].value) return false;
    }
    return true;
};


SelectTable.prototype._applySort = function (items, sortFlag) {
    var res = items.slice();

    if (sortFlag == 1 || sortFlag === true) {
        res.sort(function (a, b) {
            return this._stringcmp(this._getString(a), this._getString(b))
        }.bind(this))
    }
    else if (sortFlag == -1) {
        res.sort(function (a, b) {
            return -this._stringcmp(this._getString(a), this._getString(b))
        }.bind(this))
    }
    else if (typeof sortFlag == 'function') {
        res.sort(function (a, b) {
            return sortFlag(a, b)
        }.bind(this))
    }
    return res;
};

SelectTable.prototype.requestSort = function () {

    if (!this.sorted || this.sorted == 0) return;
    var selectedItems = this.selectedItems;
    var selectedItemsNew = this._applySort(selectedItems, this.sorted);
    if (!this._equalArr(selectedItems, selectedItemsNew)) {
        this.selectedItems = selectedItemsNew;
    }

    var nonselectedItems = this.nonselectedItems;
    var nonselectedItemsNew = this._applySort(nonselectedItems, this.sorted);
    if (!this._equalArr(nonselectedItems, nonselectedItemsNew)) {
        this.nonselectedItems = nonselectedItemsNew;
    }

};

SelectTable.eventHandler.searchTextInputModify = function (event) {
    var filterText = this.$searchTextInput.value.trim();
    if (filterText.length > 0) {
        var selectedItems = this.selectedItems;
        var nonselectedItems = this.nonselectedItems;
        this.selectedSearchItems = selectedItems;
        this.nonselectedSearchItems = this._filter(nonselectedItems, filterText);
        this.selectedSearchItems = this._filter(selectedItems, filterText);
    }
    else {
    }
    this.searching = filterText.length > 0;

};


SelectTable.property = {};

SelectTable.property.disableMoveAll = {
    set: function (value) {
        if (value)
            this.addClass('disable-move-all');
        else
            this.removeClass('disable-move-all');
    },
    get: function () {
        return this.containsClass('disable-move-all');
    }
};

SelectTable.property.removeAllText = {
    set: function (text) {
        this._removeAllText = text;
        //todo: update remove all text
        if (!text)
            this.$removeAllBtn.addStyle('display', 'none');
        else {
            this.$removeAllBtn.removeStyle('display');
            this.$removeAllBtn.innerHTML = this.removeAllText;
            this.updateButtonsContainerSize();
        }
    },
    get: function () {
        return this._removeAllText || 'Remove All'
    }
};

SelectTable.property.addAllText = {
    set: function (text) {
        this._addAllText = text;
        if (!text)
            this.$addAllBtn.addStyle('display', 'none');
        else {
            this.$addAllBtn.removeStyle('display');
            this.$addAllBtn.innerHTML = this.removeAllText;
            this.updateButtonsContainerSize();
        }
    },
    get: function () {
        return this._addAllText || 'Add All'
    }
};

SelectTable.property.searching = {
    set: function (value) {
        if (value) {
            this.addClass('searching');
        }
        else {
            this.removeClass('searching');
        }
        this.updateScroller();
    },
    get: function () {
        return this.containsClass('searching');
    }
};


SelectTable.property.sorted = {
    set: function (value) {
        this._sort = value;
        this.requestSort();

    },
    get: function () {
        return this._sort;
    }
};

SelectTable.property.selectedItems = {
    set: function (items) {
        this.$selectedItemsContainer.clearChild();
        var $nonselectedItemsContainer = this.$nonselectedItemsContainer;
        var $selectedItemsContainer = this.$selectedItemsContainer;
        var self = this;
        if (items instanceof Array) {
            items.map(function (item) {
                return SelectTable_({
                    tag: 'item',
                    props: {
                        data: item
                    },
                    on: {
                        requestmove: function (event) {
                            if (this.parentElement == $selectedItemsContainer) {
                                this.addTo($nonselectedItemsContainer);
                                self.emit('remove', EventEmitter["b" /* default */].copyEvent(event, { item: item }), self);
                            }
                            else {
                                this.addTo($selectedItemsContainer);
                                self.emit('add', EventEmitter["b" /* default */].copyEvent(event, { item: item }), self);
                            }
                            self.updateScroller();
                            self.requestSort();

                        }
                    }
                }).addTo(this.$selectedItemsContainer);
            }.bind(this))
        }
        else {
            // error
        }
        this.updateScroller();
        this.requestSort();
    },
    get: function () {
        return Array.prototype.map.call(this.$selectedItemsContainer.childNodes, function (e) {
            return e.data;
        });
    }

}

SelectTable.property.nonselectedItems = {
    set: function (items) {
        this.$nonselectedItemsContainer.clearChild();
        var $nonselectedItemsContainer = this.$nonselectedItemsContainer;
        var $selectedItemsContainer = this.$selectedItemsContainer;
        var self = this;
        if (items instanceof Array) {
            items.map(function (item) {
                return SelectTable_({
                    tag: 'item',
                    props: {
                        data: item
                    },
                    on: {
                        requestmove: function (event) {
                            if (this.parentElement == $selectedItemsContainer) {
                                this.addTo($nonselectedItemsContainer);
                                self.emit('remove', EventEmitter["b" /* default */].copyEvent(event, { item: item }), self);
                            }
                            else {
                                this.addTo($selectedItemsContainer);
                                self.emit('add', EventEmitter["b" /* default */].copyEvent(event, { item: item }), self);
                            }
                            self.updateScroller();
                            self.requestSort();
                        }
                    }
                }).addTo(this.$nonselectedItemsContainer);
            }.bind(this))
        }
        else {
            // error
        }
        this.updateScroller();
        this.requestSort();
    },
    get: function () {
        return Array.prototype.map.call(this.$nonselectedItemsContainer.childNodes, function (e) {
            return e.data;
        });
    }
};


SelectTable.property.selectedSearchItems = {
    set: function (items) {
        this.$selectedSearchItemsContainer.clearChild();
        var $nonselectedSearchItemsContainer = this.$nonselectedSearchItemsContainer;
        var $selectedSearchItemsContainer = this.$selectedSearchItemsContainer;
        var table = this;
        if (items instanceof Array) {
            items.map(function (item) {
                return SelectTable_({
                    tag: 'item',
                    props: {
                        data: item
                    },
                    on: {
                        requestmove: function (event) {
                            if (this.parentElement == $selectedSearchItemsContainer) {
                                this.addTo($nonselectedSearchItemsContainer);
                                table.getAllItemElement().filter(function (itemElement) {
                                    if (itemElement.data == this.data) {
                                        itemElement.addTo(table.$nonselectedItemsContainer);
                                        return true;
                                    }
                                    return false;
                                }.bind(this));
                                table.emit('remove', EventEmitter["b" /* default */].copyEvent(event, { item: item }), table);

                            }
                            else {
                                this.addTo($selectedSearchItemsContainer);
                                table.getAllItemElement().filter(function (itemElement) {
                                    if (itemElement.data == this.data) {
                                        itemElement.addTo(table.$selectedItemsContainer);
                                        return true;
                                    }
                                    return false;
                                }.bind(this));
                                table.emit('add', EventEmitter["b" /* default */].copyEvent(event, { item: item }), table);

                            }
                            table.updateScroller();
                            table.requestSort();
                        }
                    }
                }).addTo(this.$selectedSearchItemsContainer);
            }.bind(this))
        }
        else {
            // error
        }
        this.updateScroller();
    },
    get: function () {
        return Array.prototype.map.call(this.$selectedSearchItemsContainer.childNodes, function (e) {
            return e.data;
        });
    }

}

SelectTable.property.nonselectedSearchItems = {
    set: function (items) {
        this.$nonselectedSearchItemsContainer.clearChild();
        var $nonselectedSearchItemsContainer = this.$nonselectedSearchItemsContainer;
        var $selectedSearchItemsContainer = this.$selectedSearchItemsContainer;
        var table = this;
        if (items instanceof Array) {
            items.map(function (item) {
                return SelectTable_({
                    tag: 'item',
                    props: {
                        data: item
                    },
                    on: {
                        requestmove: function (event) {
                            if (this.parentElement == $selectedSearchItemsContainer) {
                                this.addTo($nonselectedSearchItemsContainer);
                                table.getAllItemElement().filter(function (itemElement) {
                                    if (itemElement.data == this.data) {
                                        itemElement.addTo(table.$nonselectedItemsContainer);
                                        return true;
                                    }
                                    return false;
                                }.bind(this));
                                table.emit('remove', EventEmitter["b" /* default */].copyEvent(event, { item: item }), table);
                            }
                            else {
                                this.addTo($selectedSearchItemsContainer);
                                table.getAllItemElement().filter(function (itemElement) {
                                    if (itemElement.data == this.data) {
                                        itemElement.addTo(table.$selectedItemsContainer);
                                        return true;
                                    }
                                    return false;
                                }.bind(this));
                                table.emit('add', EventEmitter["b" /* default */].copyEvent(event, { item: item }), table);

                            }
                            table.updateScroller();
                            table.requestSort();

                        }
                    }
                }).addTo(this.$nonselectedSearchItemsContainer);
            }.bind(this))
        }
        else {
            // error
        }
        this.updateScroller();
    },
    get: function () {
        return Array.prototype.map.call(this.$nonselectedSearchItemsContainer.childNodes, function (e) {
            return e.data;
        });
    }
};


/*
namespace of selecttable
*/
function Item() {
    var res = SelectTable_({
        extendEvent: ['requestmove'],
        class: 'absol-select-table-item',
        child: ['span.absol-select-table-item-text',
            {
                class: 'absol-select-table-item-right-container',
                child: {
                    class: 'absol-select-table-item-right-container-table',
                    child: {
                        class: 'absol-select-table-item-right-container-cell',
                        child: ['addicon', 'subicon']
                    }
                }

            }
        ]
    });
    res.$text = SelectTable_$('span', res);
    res.eventHandler = OOP["a" /* default */].bindFunctions(res, Item.eventHandler);
    res.$rightBtn = SelectTable_$('.absol-select-table-item-right-container', res);
    res.on('dblclick', res.eventHandler.dblclick);
    res.$rightBtn.on('click', res.eventHandler.rightBtClick);
    return res;
};


Item.eventHandler = {};
Item.eventHandler.dblclick = function (event) {
    event.preventDefault();
    if (!EventEmitter["b" /* default */].hitElement(this.$rightBtn, event))
        this.emit('requestmove', event, this);
};

Item.eventHandler.rightBtClick = function (event) {
    this.emit('requestmove', event, this);
};


Item.property = {};
Item.property.data = {
    set: function (value) {
        this._data = value;
        if (value) {
            var text;
            if (typeof value == "string") {
                text = value;
            }
            else {
                text = value.text;
            }
            this.$text.innerHTML = text;
        }
    },
    get: function () {
        return this._data;
    }
};

Item.property.text = {
    get: function () {
        return this._data ? (typeof this._data == 'string' ? this._data : this._data.text) : '';
    }
};

/**
 *
 * <svg width="100mm" height="100mm" version="1.1" viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg">
 <g transform="translate(0,-197)">
 <path d="m39.873 198.21v38.668h-38.668v20.252h38.668v38.668h20.253v-38.668h38.668v-20.252h-38.668v-38.668z" style="fill-rule:evenodd;fill:#5fbbc2;stroke-linejoin:round;stroke-width:2.4109;stroke:#002eea"/>
 </g>
 </svg>
 */

function AddIcon() {
    return Svg["a" /* default */].ShareInstance.buildSvg(
        '<svg class="add-icon" width="100mm" height="100mm" version="1.1" viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg">' +
        '<g transform="translate(0,-197)">' +
        '<path d="m39.873 198.21v38.668h-38.668v20.252h38.668v38.668h20.253v-38.668h38.668v-20.252h-38.668v-38.668z" style="fill-rule:evenodd;stroke-linejoin:round;stroke-width:2.4109;" />' +
        '</g>' +
        '</svg>'
    );
};

function SubIcon() {
    return Svg["a" /* default */].ShareInstance.buildSvg(
        '<svg class="sub-icon" width="100mm" height="100mm" version="1.1" viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg">' +
        ' <g transform="translate(0,-197)">' +
        '  <path d="m98.795 236.87v20.253h-97.589v-20.253z" style="fill-rule:evenodd;stroke-linejoin:round;stroke-width:2.411;"/>' +
        ' </g>' +
        '</svg>'
    );
};

privateDom.install({
    subicon: SubIcon,
    addicon: AddIcon,
    item: Item
});

SelectTable.privateDom = privateDom;


ACore["d" /* default */].install(SelectTable);

/* harmony default export */ var js_SelectTable = (SelectTable);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/SelectTable2.js










var SelectTable2_privateDom = new Dom["b" /* default */]().install(ACore["d" /* default */]).install(js_SelectTable.privateDom);
var SelectTable2_$ = SelectTable2_privateDom.$;
var SelectTable2_ = SelectTable2_privateDom._;


function SelectTable2() {
    var thisST = this;
    this.$attachhook = SelectTable2_('attachhook').addTo(this);
    this.sync = new Promise(function (rs) {
        thisST.$attachhook.on('error', rs);
    });
    this.$buttonsContainer = SelectTable2_$('.absol-select-table-buttons-container', this);
    this.$searchContainer = SelectTable2_$('.absol-select-table-searchtextinput-container', this);
    this.$nonselectedItemsContainer = SelectTable2_$('.absol-select-table-nonselected-items-container', this);
    this.$selectedItemsContainer = SelectTable2_$('.absol-select-table-selected-items-container', this);

    this.$nonselectedSearchItemsContainer = SelectTable2_$('.absol-select-table-nonselected-search-items-container', this);
    this.$selectedSearchItemsContainer = SelectTable2_$('.absol-select-table-selected-search-items-container', this);

    this.$removeAllBtn = SelectTable2_$('button.remove-all', this).on('click', this.eventHandler.removeAllBtnClick);
    this.$addAllBtn = SelectTable2_$('button.add-all', this).on('click', this.eventHandler.addAllBtnClick);
    this.$vscrollerSelected = SelectTable2_$('vscroller#selected', this)
    this.$vscrollerNonselected = SelectTable2_$('vscroller#nonselected', this);
    this.$body = SelectTable2_$('.absol-select-table-body', this);
    this.$searchTextInput = SelectTable2_$('searchtextinput', this).on('stoptyping', this.eventHandler.searchTextInputModify);
};


SelectTable2.tag = 'SelectTable2'.toLowerCase();

SelectTable2.render = function () {
    return SelectTable2_({
        class: ['absol-select-table', 'exclude'],
        extendEvent: ['change', 'addall', 'removeall', 'add', 'remove'],
        child: [
            {
                class: 'absol-select-table-header',
                child: [
                    {
                        class: 'absol-select-table-searchtextinput-container',
                        child: 'searchtextinput'
                    },
                    {
                        class: 'absol-select-table-buttons-container',
                        child: [
                            {
                                tag: 'button',
                                class: 'add-all',
                                props: {
                                    innerHTML: 'Add All'
                                }
                            },
                            {
                                tag: 'button',
                                class: 'remove-all',
                                props: {
                                    innerHTML: 'Remove All'
                                }
                            }
                        ]
                    }

                ]
            },
            {
                class: 'absol-select-table-body',
                child: [

                    {
                        tag: 'vscroller',
                        attr: { id: 'nonselected' },
                        class: 'absol-select-table-items-scroller',
                        child: {
                            child: ['.absol-select-table-nonselected-items-container', '.absol-select-table-nonselected-search-items-container']
                        }
                    },
                    {
                        tag: 'vscroller',
                        attr: { id: 'selected' },
                        class: 'absol-select-table-items-scroller',
                        child: {
                            child: ['.absol-select-table-selected-items-container', '.absol-select-table-selected-search-items-container']

                        }

                    }
                ]
            }
        ]
    });
};


SelectTable2.prototype.updateButtonsContainerSize = function () {
    var rootBound = this.$buttonsContainer.getBoundingClientRect();
    var containBound = this.$buttonsContainer.getBoundingRecursiveRect();
    var fontSize = this.getFontSize();
    this.$buttonsContainer.addStyle('width', (containBound.width + 1) / fontSize + 'em');
    this.$searchContainer.addStyle('right', (containBound.width + 5) / fontSize + 'em');
};

SelectTable2.prototype.addAll = function () {
    Array.apply(null, this.$nonselectedItemsContainer.childNodes).forEach(function (e) {
        e.addTo(this.$selectedItemsContainer);
    }.bind(this));
    this.requestSort();
};

SelectTable2.prototype.removeAll = function () {
    Array.apply(null, this.$selectedItemsContainer.childNodes).forEach(function (e) {
        e.addTo(this.$nonselectedItemsContainer);
    }.bind(this))
    this.requestSort();
};

SelectTable2.prototype.updateScroller = function () {
    var update = function () {
        if (this.style.height) {
            var bodyMargin = parseFloat(this.$body.getComputedStyleValue('margin-top').replace('px', '') || (0.14285714285 * 14 + ''));
            var bound = this.getBoundingClientRect();
            var bodyBound = this.$body.getBoundingClientRect();
            var bodyRBound = this.$body.getBoundingRecursiveRect();
            var availableHeight = bound.bottom - bodyMargin - bodyBound.top;
            var isOverflowHeight = availableHeight < bodyRBound.height;
            if (isOverflowHeight) {
                this.$vscrollerNonselected.addStyle('max-height', availableHeight + 'px');
                this.$vscrollerSelected.addStyle('max-height', availableHeight + 'px');
                this.$vscrollerSelected.addClass('limited-height');
                this.$vscrollerNonselected.addClass('limited-height');
            }
            else {
                this.$vscrollerNonselected.removeStyle('max-height');
                this.$vscrollerSelected.removeStyle('max-height');
                this.$vscrollerSelected.removeClass('limited-height');
                this.$vscrollerSelected.removeClass('limited-height');
                this.$vscrollerNonselected.removeClass('limited-height');
            }
        }
        requestAnimationFrame(this.$vscrollerNonselected.requestUpdateSize.bind(this.$vscrollerNonselected));
        requestAnimationFrame(this.$vscrollerSelected.requestUpdateSize.bind(this.$vscrollerSelected));
    }.bind(this);
    setTimeout(update, 1);
};

SelectTable2.prototype.getAllItemElement = function () {
    var selectedItemElements = Array.apply(null, this.$selectedItemsContainer.childNodes);
    var nonselectedItemElements = Array.apply(null, this.$nonselectedItemsContainer.childNodes);
    return selectedItemElements.concat(nonselectedItemElements);
};

SelectTable2.prototype.init = function (props) {
    this.super(props);
    this.sync = this.sync.then(this.updateButtonsContainerSize.bind(this));
};

SelectTable2.eventHandler = {};
SelectTable2.eventHandler.addAllBtnClick = function (event) {
    this.addAll();
    if (this.searching) {
        this.eventHandler.searchTextInputModify(event);
    }
    this.emit('addall', EventEmitter["b" /* default */].copyEvent(event, {}), this);
    this.updateScroller();
};

SelectTable2.eventHandler.removeAllBtnClick = function (event) {
    this.removeAll();
    if (this.searching) {
        this.eventHandler.searchTextInputModify(event);
    }
    this.emit('removeall', EventEmitter["b" /* default */].copyEvent(event, {}), this);
    this.updateScroller();
};

SelectTable2.prototype._filter = function (items, filterText) {
    var result = [];
    if (filterText.length == 1) {
        result = items.map(function (item) {
            var res = { item: item, text: typeof item === 'string' ? item : item.text };
            return res;
        }).map(function (it) {
            it.score = 0;
            var text = it.text.replace(/((\&nbsp)|(\s))+/g, ' ').trim();
            it.score += text.toLowerCase().indexOf(filterText.toLowerCase()) >= 0 ? 100 : 0;
            text = Object(stringFormat["nonAccentVietnamese"])(text);
            it.score += text.toLowerCase().indexOf(filterText.toLowerCase()) >= 0 ? 100 : 0;
            return it;
        });

        result.sort(function (a, b) {
            if (b.score - a.score == 0) {
                if (Object(stringFormat["nonAccentVietnamese"])(b.text) > Object(stringFormat["nonAccentVietnamese"])(a.text)) return -1;
                return 1;
            }
            return b.score - a.score;
        });
        result = result.filter(function (x) {
            return x.score > 0;
        });
    }
    else {
        var its = items.map(function (item) {
            var res = { item: item, text: typeof item === 'string' ? item : item.text };
            var text = res.text.replace(/((\&nbsp)|(\s))+/g, ' ').trim();
            res.score = (Object(stringMatching["phraseMatch"])(text, filterText)
                + Object(stringMatching["phraseMatch"])(Object(stringFormat["nonAccentVietnamese"])(text), Object(stringFormat["nonAccentVietnamese"])(filterText))) / 2;
            if (Object(stringFormat["nonAccentVietnamese"])(text).replace(/s/g, '').toLowerCase().indexOf(Object(stringFormat["nonAccentVietnamese"])(filterText).toLowerCase().replace(/s/g, '')) > -1)
                res.score = 100;
            return res;
        });
        if (its.length == 0) return;

        its.sort(function (a, b) {
            if (b.score - a.score == 0) {
                if (Object(stringFormat["nonAccentVietnamese"])(b.text) > Object(stringFormat["nonAccentVietnamese"])(a.text)) return -1;
                return 1;
            }
            return b.score - a.score;
        });
        var result = its.filter(function (x) {
            return x.score > 0.5;
        });
        if (result.length == 0) {
            var bestScore = its[0].score;
            result = its.filter(function (it) {
                return it.score + 0.001 >= bestScore;
            });
        }
        if (result[0].score == 0) result = [];
    }
    result = result.map(function (e) {
        return e.item;
    });

    return result;
};

SelectTable2.prototype._stringcmp = function (s0, s1) {
    if (s0 == s1) return 0;
    if (s0 > s1) return 1;
    return -1;
};

SelectTable2.prototype._getString = function (item) {
    if (typeof item == "string") return item;
    return item.text;
};

SelectTable2.prototype._equalArr = function (a, b) {
    if (a.length != b.length) return false;
    for (var i = 0; i < a.length; ++i) {
        if (a[i] != b[i]) return false;
    }
    return true;
};


SelectTable2.prototype._applySort = function (items, sortFlag) {
    var res = items.slice();

    if (sortFlag == 1 || sortFlag === true) {
        res.sort(function (a, b) {
            return this._stringcmp(this._getString(a), this._getString(b))
        }.bind(this))
    }
    else if (sortFlag == -1) {
        res.sort(function (a, b) {
            return -this._stringcmp(this._getString(a), this._getString(b))
        }.bind(this))
    }
    else if (typeof sortFlag == 'function') {
        res.sort(function (a, b) {
            return sortFlag(a, b)
        }.bind(this))
    }
    return res;
};

SelectTable2.prototype.requestSort = function () {
    if (!this.sorted || this.sorted == 0) return;
    var selectedItems = this.selectedItems;
    var selectedItemsNew = this._applySort(selectedItems, this.sorted);
    if (!this._equalArr(selectedItems, selectedItemsNew)) {
        this.selectedItems = selectedItemsNew;
    }

    var nonselectedItems = this.nonselectedItems;
    var nonselectedItemsNew = this._applySort(nonselectedItems, this.sorted);
    if (!this._equalArr(nonselectedItems, nonselectedItemsNew)) {
        this.nonselectedItems = nonselectedItemsNew;
    }

};

SelectTable2.eventHandler.searchTextInputModify = function (event) {
    var filterText = this.$searchTextInput.value.trim();
    if (filterText.length > 0) {
        var selectedItems = this.selectedItems;
        var nonselectedItems = this.nonselectedItems;
        this.selectedSearchItems = selectedItems;
        this.nonselectedSearchItems = this._filter(nonselectedItems, filterText);
        this.selectedSearchItems = this._filter(selectedItems, filterText);
    }
    else {

    }
    this.searching = filterText.length > 0;

};


SelectTable2.property = {};

SelectTable2.property.disableMoveAll = {
    set: function (value) {
        if (value)
            this.addClass('disable-move-all');
        else
            this.removeClass('disable-move-all');
    },
    get: function () {
        return this.containsClass('disable-move-all');
    }
};

SelectTable2.property.removeAllText = {
    set: function (text) {
        this._removeAllText = text;
        //todo: update remove all text
        if (!text)
            this.$removeAllBtn.addStyle('display', 'none');
        else {
            this.$removeAllBtn.removeStyle('display');
            this.$removeAllBtn.innerHTML = this.removeAllText;
            this.updateButtonsContainerSize();
        }
    },
    get: function () {
        return this._removeAllText || 'Remove All'
    }
};

SelectTable2.property.addAllText = {
    set: function (text) {
        this._addAllText = text;
        if (!text)
            this.$addAllBtn.addStyle('display', 'none');
        else {
            this.$addAllBtn.removeStyle('display');
            this.$addAllBtn.innerHTML = this.removeAllText;
            this.updateButtonsContainerSize();
        }
    },
    get: function () {
        return this._addAllText || 'Add All'
    }
};

SelectTable2.property.searching = {
    set: function (value) {
        if (value) {
            this.addClass('searching');
        }
        else {
            this.removeClass('searching');
        }
        this.updateScroller();
    },
    get: function () {
        return this.containsClass('searching');
    }
};


SelectTable2.property.sorted = {
    set: function (value) {
        this._sort = value;
        this.requestSort();

    },
    get: function () {
        return this._sort;
    }
};

SelectTable2.property.selectedItems = {
    set: function (items) {
        this.$selectedItemsContainer.clearChild();
        var $nonselectedItemsContainer = this.$nonselectedItemsContainer;
        var $selectedItemsContainer = this.$selectedItemsContainer;
        var self = this;
        if (items instanceof Array) {
            items.map(function (item) {
                return SelectTable2_({
                    tag: 'item',
                    props: {
                        data: item
                    },
                    on: {
                        requestmove: function (event) {
                            if (this.parentElement == $selectedItemsContainer) {
                                this.addTo($nonselectedItemsContainer);
                                self.emit('remove', EventEmitter["b" /* default */].copyEvent(event, { item: item }), self);
                            }
                            else {
                                this.addTo($selectedItemsContainer);
                                self.emit('add', EventEmitter["b" /* default */].copyEvent(event, { item: item }), self);
                            }
                            self.updateScroller();
                            self.requestSort();

                        }
                    }
                }).addTo(this.$selectedItemsContainer);
            }.bind(this))
        }
        else {
            // error
        }
        this.updateScroller();
        this.requestSort();
    },
    get: function () {
        return Array.prototype.map.call(this.$selectedItemsContainer.childNodes, function (e) {
            return e.data;
        });
    }

}

SelectTable2.property.nonselectedItems = {
    set: function (items) {
        this.$nonselectedItemsContainer.clearChild();
        var $nonselectedItemsContainer = this.$nonselectedItemsContainer;
        var $selectedItemsContainer = this.$selectedItemsContainer;
        var self = this;
        if (items instanceof Array) {
            items.map(function (item) {
                return SelectTable2_({
                    tag: 'item',
                    props: {
                        data: item
                    },
                    on: {
                        requestmove: function (event) {
                            if (this.parentElement == $selectedItemsContainer) {
                                this.addTo($nonselectedItemsContainer);
                                self.emit('remove', EventEmitter["b" /* default */].copyEvent(event, { item: item }), self);
                            }
                            else {
                                this.addTo($selectedItemsContainer);
                                self.emit('add', EventEmitter["b" /* default */].copyEvent(event, { item: item }), self);
                            }
                            self.updateScroller();
                            self.requestSort();
                        }
                    }
                }).addTo(this.$nonselectedItemsContainer);
            }.bind(this))
        }
        else {
            // error
        }
        this.updateScroller();
        this.requestSort();
    },
    get: function () {
        return Array.prototype.map.call(this.$nonselectedItemsContainer.childNodes, function (e) {
            return e.data;
        });
    }
};


SelectTable2.property.selectedSearchItems = {
    set: function (items) {
        this.$selectedSearchItemsContainer.clearChild();
        var $nonselectedSearchItemsContainer = this.$nonselectedSearchItemsContainer;
        var $selectedSearchItemsContainer = this.$selectedSearchItemsContainer;
        var table = this;
        if (items instanceof Array) {
            items.map(function (item) {
                return SelectTable2_({
                    tag: 'item',
                    props: {
                        data: item
                    },
                    on: {
                        requestmove: function (event) {
                            if (this.parentElement == $selectedSearchItemsContainer) {
                                this.addTo($nonselectedSearchItemsContainer);
                                table.getAllItemElement().filter(function (itemElement) {
                                    if (itemElement.data == this.data) {
                                        itemElement.addTo(table.$nonselectedItemsContainer);
                                        return true;
                                    }
                                    return false;
                                }.bind(this));
                                table.emit('remove', EventEmitter["b" /* default */].copyEvent(event, { item: item }), table);

                            }
                            else {
                                this.addTo($selectedSearchItemsContainer);
                                table.getAllItemElement().filter(function (itemElement) {
                                    if (itemElement.data == this.data) {
                                        itemElement.addTo(table.$selectedItemsContainer);
                                        return true;
                                    }
                                    return false;
                                }.bind(this));
                                table.emit('add', EventEmitter["b" /* default */].copyEvent(event, { item: item }), table);

                            }
                            table.updateScroller();
                            table.requestSort();
                        }
                    }
                }).addTo(this.$selectedSearchItemsContainer);
            }.bind(this))
        }
        else {
            // error
        }
        this.updateScroller();
    },
    get: function () {
        return Array.prototype.map.call(this.$selectedSearchItemsContainer.childNodes, function (e) {
            return e.data;
        });
    }

}

SelectTable2.property.nonselectedSearchItems = {
    set: function (items) {
        this.$nonselectedSearchItemsContainer.clearChild();
        var $nonselectedSearchItemsContainer = this.$nonselectedSearchItemsContainer;
        var $selectedSearchItemsContainer = this.$selectedSearchItemsContainer;
        var table = this;
        if (items instanceof Array) {
            items.map(function (item) {
                return SelectTable2_({
                    tag: 'item',
                    props: {
                        data: item
                    },
                    on: {
                        requestmove: function (event) {
                            if (this.parentElement == $selectedSearchItemsContainer) {
                                this.addTo($nonselectedSearchItemsContainer);
                                table.getAllItemElement().filter(function (itemElement) {
                                    if (itemElement.data == this.data) {
                                        itemElement.addTo(table.$nonselectedItemsContainer);
                                        return true;
                                    }
                                    return false;
                                }.bind(this));
                                table.emit('remove', EventEmitter["b" /* default */].copyEvent(event, { item: item }), table);
                            }
                            else {
                                this.addTo($selectedSearchItemsContainer);
                                table.getAllItemElement().filter(function (itemElement) {
                                    if (itemElement.data == this.data) {
                                        itemElement.addTo(table.$selectedItemsContainer);
                                        return true;
                                    }
                                    return false;
                                }.bind(this));
                                table.emit('add', EventEmitter["b" /* default */].copyEvent(event, { item: item }), table);

                            }
                            table.updateScroller();
                            table.requestSort();

                        }
                    }
                }).addTo(this.$nonselectedSearchItemsContainer);
            }.bind(this))
        }
        else {
            // error
        }
        this.updateScroller();
    },
    get: function () {
        return Array.prototype.map.call(this.$nonselectedSearchItemsContainer.childNodes, function (e) {
            return e.data;
        });
    }
};


/*
namespace of selecttable
*/
function SelectTable2_Item() {
    var res = SelectTable2_({
        extendEvent: ['requestmove', 'clickadd', 'clickremove', 'clickexclude'],
        class: 'absol-select-table-item',
        child: ['span.absol-select-table-item-text',
            {
                class: 'absol-select-table-item-right-container',
                child: {
                    class: 'absol-select-table-item-right-container-table',
                    child: {
                        class: 'absol-select-table-item-right-container-row',
                        child: [
                            {
                                attr: {
                                    title: 'Add'
                                },
                                class: ['absol-select-table-item-right-container-cell', 'add'],
                                child: 'addicon'

                            },
                            {
                                attr: {
                                    title: 'Remove'
                                },
                                class: ['absol-select-table-item-right-container-cell', 'remove'],
                                child: 'subicon'

                            },
                            {
                                attr: {
                                    title: 'Exclude'
                                },
                                class: ['absol-select-table-item-right-container-cell', 'exclude'],
                                child: 'excludeico'
                            },
                        ]
                    }
                }

            }
        ]
    });
    res.$text = SelectTable2_$('span', res);
    res.eventHandler = OOP["a" /* default */].bindFunctions(res, SelectTable2_Item.eventHandler);
    res.$rightBtn = SelectTable2_$('.absol-select-table-item-right-container', res);
    res.on('dblclick', res.eventHandler.dblclick);
    res.$addBtn = SelectTable2_$('.absol-select-table-item-right-container-cell.add', res).on('click', res.eventHandler.addBtClick);
    res.$removeBtn = SelectTable2_$('.absol-select-table-item-right-container-cell.remove', res).on('click', res.eventHandler.removeBtClick);
    res.$excludeBtn = SelectTable2_$('.absol-select-table-item-right-container-cell.exclude', res).on('click', res.eventHandler.excludeBtClick);
    return res;
};


SelectTable2_Item.eventHandler = {};
SelectTable2_Item.eventHandler.dblclick = function (event) {
    event.preventDefault();
    if (!EventEmitter["b" /* default */].hitElement(this.$rightBtn, event))
        this.emit('requestmove', event, this);
};

SelectTable2_Item.eventHandler.rightBtClick = function (event) {
    this.emit('requestmove', event, this);
};

SelectTable2_Item.eventHandler.removeBtClick = function (event) {
    this.emit('clickremove', event, this);
};

SelectTable2_Item.eventHandler.addBtClick = function (event) {
    this.emit('clickadd', event, this);
};

SelectTable2_Item.eventHandler.excludeBtClick = function (event) {
    this.emit('clickexclude', event, this);
};


SelectTable2_Item.property = {};
SelectTable2_Item.property.data = {
    set: function (value) {
        this._data = value;
        if (value) {
            var text;
            if (typeof value == "string") {
                text = value;
            }
            else {
                text = value.text;
            }
            this.$text.innerHTML = text;
        }
    },
    get: function () {
        return this._data;
    }
};

SelectTable2_Item.property.text = {
    get: function () {
        return this._data ? (typeof this._data == 'string' ? this._data : this._data.text) : '';
    }
};


function ExcludeIco() {
    return SelectTable2_(
        '<svg class="exclude-icon" width="24" height="24" viewBox="0 0 24 24">\
            <path  d="M8.27,3L3,8.27V15.73L8.27,21H15.73C17.5,19.24 21,15.73 21,15.73V8.27L15.73,3M9.1,5H14.9L19,9.1V14.9L14.9,19H9.1L5,14.9V9.1M11,15H13V17H11V15M11,7H13V13H11V7" />\
        </svg>');
}


SelectTable2_privateDom.install({
    item: SelectTable2_Item,
    excludeico: ExcludeIco
});

// not completed yet

ACore["d" /* default */].install('selecttable2', SelectTable2);
/* harmony default export */ var js_SelectTable2 = (SelectTable2);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/spaninput.css
var spaninput = __webpack_require__(210);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/SpanInput.js





var SpanInput_ = ACore["d" /* default */]._;
var SpanInput_$ = ACore["d" /* default */].$;


function SpanInput() {
    this.defineEvent(['change']);
    this._inputType = 0;
    this._lastValue = null;
    this.on('paste', this.eventHandler.paste)
        .on('keyup', this.eventHandler.keyup)
        .on('keydown', this.eventHandler.keydown)
        .on('blur', this.eventHandler.blur);
}


SpanInput.prototype.notifyValueChange = function (event) {
    var cValue = this.value;
    if (this._lastValue != cValue && (this._inputType != 1 || !isNaN(this._lastValue) || !isNaN(cValue))) {
        this._lastValue = cValue;
        this.emit('change', { type: 'change', value: cValue, originEvent: event }, this);
    }
}

SpanInput.eventHandler = {};

SpanInput.eventHandler.keyup = function (event) {
    if (this._inputType == 0) {
        this.notifyValueChange(event);
    }
    else if (this._inputType == 1) {
        this.eventHandler.numberKeyup(event)

    }
};

SpanInput.eventHandler.keydown = function (event) {
    if (this._inputType == 0) {
    }
    else if (this._inputType == 1) {
        this.eventHandler.numberKeydown(event)
    }
};


SpanInput.eventHandler.numberBlur = function (value) {
    this.notifyValueChange(event);
};


SpanInput.eventHandler.textBlur = function (event) {
    this.notifyValueChange(event);
};

SpanInput.eventHandler.blur = function (event) {
    if (this._inputType == 0) {
        this.eventHandler.textBlur(event);
    }
    else if (this._inputType == 1) {
        this.eventHandler.numberKeydown(event)
    }
}


SpanInput.eventHandler.numberKeyup = function (event) {
    this.notifyValueChange();
};

SpanInput.eventHandler.numberKeydown = function (event) {
    var key = event.key;
    if (key == 'Enter') {
        event.preventDefault();
        this.blur();
        this.notifyValueChange();
        return;
    }


    if (key && key.length == 1 && !event.ctrlKey && !event.altKey) {
        if (key.match(/[0-9.\-\+]/)) {
            if (key == '.' && this.text.indexOf('.') >= 0) event.preventDefault();
            if ((key == '+' || key == '-') && (this.text.indexOf('+') >= 0 || this.text.indexOf('-') >= 0 || getCaretPosition(this) > 0)) event.preventDefault();
        }
        else event.preventDefault();
    }
};


SpanInput.eventHandler.paste = function (event) {
    event.preventDefault();
    if (event.clipboardData && event.clipboardData.getData) {
        var text = event.clipboardData.getData("text/plain");
        if (this._inputType == 1) text = text.replace(/[^0-9.\-+]/g, '');
        document.execCommand("insertHTML", false, text);
        if (this._inputType == 1) {
            if (isNaN(this.value)) {
                this.value = NaN;
            }
        }
    }
    else if (window.clipboardData && window.clipboardData.getData) {
        var text = window.clipboardData.getData("Text");
        if (this._inputType == 1) text = text.replace(/[^0-9.\-+]/g, '');
        Object(utils["insertTextAtCursor"])(text);
        if (this._inputType == 1) {
            if (isNaN(this.value)) {
                this.value = NaN;
            }
        }
    }
};


SpanInput.property = {};
SpanInput.property.value = {
    set: function (value) {
        if (this._inputType == 1 && isNaN(value)) value = null;
        this.clearChild();
        if (value !== null) this.addChild(SpanInput_({ text: value + '' }));
    },
    get: function () {
        if (this._inputType == 1) {
            return parseFloat(this.text);
        }
        else {
            return this.text;
        }
    }
};

SpanInput.property.type = {
    set: function (value) {
        var index = ['text', 'number'].indexOf(value);
        if (index < 0) index = 0;
        this._inputType = index;
        if (index == 1) {
            this.addClass('absol-span-input-empty-minus');

        }
        else {
            this.removeClass('absol-span-input-empty-minus');
        }
    },
    get: function () {
        return ['text', 'number'][this._inputType];
    }
};


SpanInput.property.text = {
    get: function () {
        return Object(Text["getTextIn"])(this);
    }
}

SpanInput.tag = 'spaninput';

SpanInput.render = function () {
    return SpanInput_('span.absol-span-input[contenteditable="true"]');
};


ACore["d" /* default */].install(SpanInput);

/* harmony default export */ var js_SpanInput = (SpanInput);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/statictabbar.css
var statictabbar = __webpack_require__(212);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/StaticTabbar.js





var StaticTabbar_$ = ACore["d" /* default */].$;
var StaticTabbar_ = ACore["d" /* default */]._;


function StaticTabbar() {
    var thisST = this;
    this.$activeBox = StaticTabbar_$('.absol-static-tabbar-active-box', this)
    this.$hline = StaticTabbar_$('.absol-static-tabbar-hline', this);
    this.$buttons = [];
    this._btDict = {};
    this._activedButton = undefined;
    this.sync = new Promise(function (resolve) {
        StaticTabbar_('attachhook').on('error', function () {
            this.remove();
            resolve();
        }).addTo(thisST);
    });
    return this;
}

StaticTabbar.tag = 'StaticTabbar'.toLowerCase();

StaticTabbar.render = function () {
    return StaticTabbar_({
        class: 'absol-static-tabbar',
        extendEvent: 'change',
        child: [
            {
                class: 'absol-static-tabbar-active-box',
                child: '.absol-static-tabbar-hline'
            }
        ]
    });
};

StaticTabbar.prototype.fireChange = function (data) {
    this.emit('change', { target: this, data, value: this.value }, self);
}

StaticTabbar.property = {};

StaticTabbar.property.items = {
    set: function (value) {
        this.$buttons.forEach(function (e) {
            e.remove()
        });
        this._items = value;
        var self = this;
        this.$buttons = this.items.map(function (tab) {
            var ident = (tab.value || Object(stringGenerate["randomIdent"])());
            var button = StaticTabbar_({
                tag: 'button',
                class: 'absol-static-tabbar-button',
                id: 'tab-' + ident,
                child: {
                    tag: 'span',
                    child: { text: tab.text }
                },
                on: {
                    click: function (event) {
                        if (self.value != tab.value) {
                            self.value = ident;
                            self.fireChange(tab);
                        }
                    }
                }
            }).addTo(self);
            self._btDict[ident] = button;
            return button;
        });
        if (this.value !== undefined) {
            this.sync.then(this.activeTab.bind(this, this.value));
        }
    },
    get: function () {
        return this._items || [];
    }
};


StaticTabbar.property.value = {
    set: function (value) {
        this._value = value;
        if (this.$buttons.length > 0) {
            this.sync.then(this.activeTab.bind(this, value));
        }
    },
    get: function () {
        return this._value;
    }
};

StaticTabbar.prototype.activeTab = function (ident) {
    if (this._activedButton) this._activedButton.removeClass('active');
    var button = this._btDict[ident];
    this._activedButton = button;
    if (button) {
        button.addClass('active');
        var bound = this.getBoundingClientRect();
        var buttonBound = button.getBoundingClientRect();
        var dx = buttonBound.left - bound.left;
        var fontSize = this.getFontSize();
        this.$activeBox.addStyle({
            left: dx / fontSize + 'em',
            width: buttonBound.width / fontSize + 'em'
        });
    }
    else {
        this.$activeBox.addStyle({
            left: '0',
            width: '0'
        });
    }
};

ACore["d" /* default */].install('statictabbar', StaticTabbar);

/* harmony default export */ var js_StaticTabbar = (StaticTabbar);



// EXTERNAL MODULE: ./node_modules/absol-acomp/css/switch.css
var css_switch = __webpack_require__(214);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/Switch.js




var Switch_ = ACore["d" /* default */]._;
var Switch_$ = ACore["d" /* default */].$;


function Switch() {
    var thisS = this;
    this.$input = Switch_$('input', this);
    this.$input.on('click', function (event) {
        thisS.emit('change', event, thisS);
    });
    OOP["a" /* default */].drillProperty(this, this.$input, 'checked');
    OOP["a" /* default */].drillProperty(this, this.$input, 'isOn', 'checked');
}


Switch.tag = 'switch';

Switch.render = function () {
    return Switch_({
        tag: 'label',
        class: 'absol-switch',
        extendEvent: 'change',
        child: [
            'input[type="checkbox"]',
            'span.absol-switch-slider'
        ]
    });
};

Switch.attribute = {
    checked: {
        set: function (value) {
            if (value == 'false' || value == null) {
                this.checked = false;
            }
            else {
                this.checked = true;
            }

        },
        get: function () {
            return this.checked ? 'true' : 'false'
        },
        remove: function () {
            this.checked = false;
        }
    },
    disabled: {
        set: function (value) {
            if (value == 'false' || value == null) {
                this.disabled = false;
            }
            else {
                this.disabled = true;
            }

        },
        get: function () {
            return this.disabled ? 'true' : 'false'
        },
        remove: function () {
            this.disabled = false;
        }
    }
};


Switch.property = {
    disabled: {
        set: function (value) {
            this.$input.disabled = !!value;
            if (value) {
                this.addClass('disabled');
            }
            else {
                this.removeClass('disabled');
            }
        },
        get: function () {
            return this.$input.disabled;
        }
    }
};

ACore["d" /* default */].install('switch', Switch);

/* harmony default export */ var js_Switch = (Switch);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/CheckboxButton.js
var CheckboxButton = __webpack_require__(61);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/tablescroller.css
var tablescroller = __webpack_require__(216);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TableScroller.js





var TableScroller_$ = ACore["d" /* default */].$;
var TableScroller_ = ACore["d" /* default */]._;


function TableScroller() {
    var thisTS = this;
    this.$content = undefined;
    this.$fixedViewport = TableScroller_$('.absol-table-scroller-fixed-viewport', this);

    this.$leftScroller = TableScroller_$('.absol-table-scroller-left-vscroller', this);
    this.$leftViewport = TableScroller_$('.absol-table-scroller-left-vscroller-viewport', this)
        .on('scroll', thisTS.eventHandler.scrollLeftScrollerViewport);
    ;

    this.$headScroller = TableScroller_$('.absol-table-scroller-header-hscroller', this);
    this.$headScrollerViewport = TableScroller_$('.absol-table-scroller-header-hscroller-viewport', this)
        .on('scroll', this.eventHandler.scrollHeadScrollerViewport);

    this.$attachHook = TableScroller_$('attachhook', this);
    this.$attachHook.requestUpdateSize = this._updateContentSize.bind(this);
    this.$attachHook.on('error', function () {
        Dom["b" /* default */].addToResizeSystem(this);
    });

    this.sync = new Promise(function (rs) {
        thisTS.$attachHook.once('error', rs)
    });

    this.$viewport = TableScroller_$('.absol-table-scroller-viewport', this)
        .on('scroll', this.eventHandler.scrollViewport);

    this.$viewport.scrollInto = js_BScroller.prototype.scrollInto;

    this.$leftLine = TableScroller_$('.absol-table-scroller-left-line', this);
    this.$headLine = TableScroller_$('.absol-table-scroller-head-line', this);

    this.$vscrollbarCtn = TableScroller_$('.absol-table-scroller-vscrollbar-container', this);
    this.$vscrollbar = TableScroller_$('.absol-table-scroller-vscrollbar-container vscrollbar', this)
        .on('scroll', function () {
            thisTS.$viewport.scrollTop = this.innerOffset;
        });


    this.$hscrollbarCtn = TableScroller_$('.absol-table-scroller-hscrollbar-container', this);
    this.$hscrollbar = TableScroller_$('.absol-table-scroller-hscrollbar-container hscrollbar', this)
        .on('scroll', function () {
            thisTS.$viewport.scrollLeft = this.innerOffset;
        });

    this.$vscrollbar.hidden = false;
    this.$hscrollbar.hidden = false;
    this._fixedTableThsVisible = [];
    this._fixedTableTr = [];
    this._fixedTableThs = [];
}

TableScroller.tag = 'TableScroller'.toLowerCase();

TableScroller.render = function () {
    return TableScroller_({
        class: 'absol-table-scroller',
        child: [
            '.absol-table-scroller-viewport',
            '.absol-table-scroller-fixed-viewport',//place holder
            {
                class: 'absol-table-scroller-header-hscroller',
                child: '.absol-table-scroller-header-hscroller-viewport'
            },
            {
                class: 'absol-table-scroller-left-vscroller',
                child: '.absol-table-scroller-left-vscroller-viewport'
            },
            '.absol-table-scroller-head-line',
            '.absol-table-scroller-left-line',
            {
                class: 'absol-table-scroller-vscrollbar-container',
                child: {
                    tag: 'vscrollbar'
                }
            },
            {
                class: 'absol-table-scroller-hscrollbar-container',
                child: {
                    tag: 'hscrollbar'
                }
            },
            'attachhook'
        ]
    });
};


TableScroller.scrollSize = 17;//default 

Dom["b" /* default */].getScrollSize().then(function (size) {
    TableScroller.scrollSize = size.width;//default scroller
    TableScroller.$style = TableScroller_('style[id="table-scroller-css"]').addTo(document.head);
    TableScroller.$style.innerHTML = [
        '.absol-table-scroller .absol-table-scroller-viewport {',// 
        '    width: calc(100% + ' + size.width + 'px);',
        '    height: calc(100% + ' + size.width + 'px);',
        '}',
        '.absol-table-scroller .absol-table-scroller-header-hscroller-viewport {',
        '    margin-bottom: -' + size.width + 'px;/*default*/',
        '}'

    ].join('\n');
    Dom["b" /* default */].updateResizeSystem();
    setTimeout(Dom["b" /* default */].updateResizeSystem.bind(Dom["b" /* default */]), 30);// css load delay
});

TableScroller.eventHandler = {};
TableScroller.eventHandler.scrollViewport = function (event) {
    if (!this.__scrollingElement__ || this.__scrollingElement__ == this.$viewport) {
        this.__scrollingElement__ = this.$viewport;
        this.$headScrollerViewport.scrollLeft = this.$viewport.scrollLeft;
        this.$leftViewport.scrollTop = this.$viewport.scrollTop;
        this.$vscrollbar.innerOffset = this.$viewport.scrollTop;
        this.$hscrollbar.innerOffset = this.$viewport.scrollLeft;

        if (this.__scrollTimer__ > 0) {
            clearTimeout(this.__scrollTimer__);
        }
        this.__scrollTimer__ = setTimeout(function () {
            this.__scrollingElement__ = undefined;
            this.__scrollTimer__ = -1;
        }.bind(this), 300);
    }
};

TableScroller.eventHandler.scrollHeadScrollerViewport = function (event) {
    if (!this.__scrollingElement__ || this.__scrollingElement__ == this.$headScrollerViewport) {
        this.__scrollingElement__ = this.$headScrollerViewport;
        this.$viewport.scrollLeft = this.$headScrollerViewport.scrollLeft;
        if (this.__scrollTimer__ > 0) {
            clearTimeout(this.__scrollTimer__);
        }
        this.__scrollTimer__ = setTimeout(function () {
            this.__scrollingElement__ = undefined;
            this.__scrollTimer__ = -1;
        }.bind(this), 100);
    }
};


TableScroller.eventHandler.scrollLeftScrollerViewport = function () {
    if (!this.__scrollingElement__ || this.__scrollingElement__ == this.$leftViewport) {
        this.__scrollingElement__ = this.$leftViewport;
        this.$viewport.scrollTop = this.$leftViewport.scrollTop;
        if (this.__scrollTimer__ > 0) {
            clearTimeout(this.__scrollTimer__);
        }
        this.__scrollTimer__ = setTimeout(function () {
            this.__scrollingElement__ = undefined;
            this.__scrollTimer__ = -1;
        }.bind(this), 100);
    }
}

TableScroller.prototype.clearChild = function () {
    this.$viewport.clearChild();
    this.$fixedViewport.clearChild();
    this.$headScrollerViewport.clearChild();
    this.$leftViewport.clearChild();
    this.$content = null;
    return this;
};

TableScroller.prototype.addChild = function (elt) {
    if (this.$viewport.childNodes.length == 0) {
        if (elt.tagName && elt.tagName.toLowerCase() == 'table') {
            elt.classList.add('absol-table-scroller-origin');
            this.$viewport.addChild(elt);
            this.$content = elt;
            this._updateContent();
            this.sync.then(this._updateContentSize.bind(this)).then(function () {
                setTimeout(this._updateContentSize.bind(this), 30);
            }.bind(this));
        }
        else {
            throw new Error('Element must be a table!');
        }
    }
    else {
        throw new Error("Only 1 table accepted!");
    }
};


TableScroller.prototype._updateFixedTable = function () {
    var fixedCol = this.fixedCol;
    this.$fixedViewport.clearChild();
    this.$fixedTable = TableScroller_$(this.$content.cloneNode(false)).addClass('absol-table-scroller-fixed-table')
        .removeClass('absol-table-scroller-origin').addTo(this.$fixedViewport);
    this.$fixedTableThead = TableScroller_$(this.$contentThead.cloneNode(false)).addTo(this.$fixedTable);

    this.$fixedTableThead.clearChild();
    this._fixedTableThsVisible = [];
    var self = this;
    this._fixedTableTr = Array.prototype.filter.call(this.$contentThead.childNodes, function (elt) {
        return elt.tagName == "TR";
    }).map(function (tr) {
        var cloneTr = TableScroller_$(tr.cloneNode(false));
        cloneTr.__originElement__ = tr;
        self.$fixedTableThead.appendChild(cloneTr);
        return cloneTr;
    });

    this._fixedTableThs = this._fixedTableTr.map(function (tr) {
        return Array.prototype.filter.call(tr.__originElement__.childNodes, function (elt1) {
            return elt1.tagName == "TH" || elt1.tagName == "TD";
        }).reduce(function (ac, th) {
            var colspan = th.getAttribute('colspan');
            if (colspan) {
                colspan = parseInt(colspan);
            }
            else {
                colspan = 1;
            }
            ac.colspanSum += colspan;
            var cloneTh = TableScroller_$(th.cloneNode(true));
            tr.appendChild(cloneTh);
            cloneTh.__originElement__ = th;
            ac.result.push(cloneTh);
            if (ac.colspanSum <= fixedCol) {
                self._fixedTableThsVisible.push(th);
            }
            return ac;
        }, { result: [], colspanSum: 0 }).result;
    });

};


TableScroller.prototype._updateHeaderScroller = function () {
    var self = this;
    this.$headScrollerViewport.clearChild();
    this.$headScrollerTable = TableScroller_$(this.$content.cloneNode(false))
        .removeClass('absol-table-scroller-origin')
        .addTo(this.$headScrollerViewport);
    this.$headScrollerThead = TableScroller_$(this.$contentThead.cloneNode(false))
        .addTo(this.$headScrollerTable);

    this._headScrollerTr = Array.prototype.filter.call(this.$contentThead.childNodes, function (elt) {
        return elt.tagName == "TR";
    }).map(function (tr) {
        var cloneTr = TableScroller_$(tr.cloneNode(false));
        cloneTr.__originElement__ = tr;
        self.$headScrollerThead.appendChild(cloneTr);
        return cloneTr;
    });

    this._headScrollerTds = this._headScrollerTr.map(function (tr) {
        return Array.prototype.filter.call(tr.__originElement__.childNodes, function (elt1) {
            return elt1.tagName == "TH";
        }).map(function (th) {
            var cloneTh = TableScroller_$(th.cloneNode(true)).addTo(tr);
            cloneTh.__originElement__ = th;
            return cloneTh;
        });

    });
};


TableScroller.prototype._updateLeftTable = function () {
    this.$leftViewport.clearChild();
    this.$leftTable = TableScroller_$(this.$content.cloneNode(true)).addTo(this.$leftViewport);


};


TableScroller.prototype._updateContent = function () {
    this.$contentThead = TableScroller_$('thead', this.$content);
    this._updateFixedTable();
    this._updateHeaderScroller();
    this._updateLeftTable();
};

TableScroller.prototype._updateFixedTableSize = function () {
    var l = 1000;
    var r = -1000;
    this._fixedTableThsVisible.forEach(function (elt) {
        var b = elt.getBoundingClientRect();
        l = Math.min(l, b.left);
        r = Math.max(r, b.right);
    });
    this._leftWidth = Math.max(r - l, 0);

    this.$fixedViewport.addStyle('width', this._leftWidth + 2 + 'px');

    this._fixedTableTr.forEach(function (elt) {
        var styleHeight = elt.__originElement__.getBoundingClientRect().height + 'px';
        elt.addStyle('height', styleHeight);
    });

    this._fixedTableThs.forEach(function (row) {
        row.forEach(function (elt) {
            var styleWidth = elt.__originElement__.getBoundingClientRect().width + 'px';
            elt.addStyle('width', styleWidth);
        });
    });

    this.$fixedTable.addStyle({
        height: this.$contentThead.getBoundingClientRect().height + 'px',
        width: this.$content.getBoundingClientRect().width + 'px',
    });
};


TableScroller.prototype._updateHeaderScrollerSize = function () {
    var headHeight = this.$contentThead.getBoundingClientRect().height + 'px';
    this.$headScrollerTable.addStyle('height', headHeight);
    this.$headScrollerTable.addStyle('width', this.$content.getBoundingClientRect().width + 'px');
    this._headScrollerTr.forEach(function (elt) {
        var styleHeight = elt.__originElement__.getBoundingClientRect().height + 'px';
        elt.addStyle('height', styleHeight);
    });

    this._headScrollerTds.forEach(function (row) {
        row.forEach(function (elt) {
            var styleWidth = elt.__originElement__.getBoundingClientRect().width + 'px';
            elt.addStyle('width', styleWidth);
        });
    });
};

TableScroller.prototype._updateLeftTableSize = function () {
    this.$leftTable.addStyle('width', this.$content.getBoundingClientRect().width + 'px');
    this.$leftTable.addStyle('height', this.$content.getBoundingClientRect().height + 'px');
    this.$leftScroller.addStyle('width', this._leftWidth + 2 + 'px');
};

TableScroller.prototype._updateLinesSize = function () {
    if (this.$viewport.clientHeight < this.$viewport.scrollHeight) {
        this.addClass('scroll-v');
    }
    else {
        this.removeClass('scroll-v');
    }

    if (this.$viewport.clientWidth < this.$viewport.scrollWidth) {
        this.addClass('scroll-h');
    }
    else {
        this.removeClass('scroll-h');
    }

    this.$leftLine.addStyle({
        maxHeight: this.$content.getBoundingClientRect().height + 'px',
        left: this._leftWidth + 'px'
    });
    this.$headLine.addStyle({
        top: this.$contentThead.getBoundingClientRect().height + 'px',
        maxWidth: this.$content.getBoundingClientRect().width + 'px'
    });
};


TableScroller.prototype._updateScrollBarSize = function () {
    var viewportBound = this.$viewport.getBoundingClientRect();
    var tableBound = this.$content.getBoundingClientRect();
    this.$vscrollbar.innerHeight = this.$viewport.scrollHeight;
    this.$vscrollbar.outerHeight = viewportBound.height - TableScroller.scrollSize;


    this.$hscrollbar.innerWidth = this.$viewport.scrollWidth;
    this.$hscrollbar.outerWidth = viewportBound.width - TableScroller.scrollSize;

    var overHeight = this.$viewport.clientHeight < this.$viewport.scrollHeight;
    var overWidth = this.$viewport.clientWidth < this.$viewport.scrollWidth;
    if (overHeight) {
        if (overWidth) {
            this.$hscrollbarCtn.removeStyle('bottom');
            this.$vscrollbarCtn.removeStyle('right');
        }
        else {
            this.$vscrollbarCtn.addStyle('right', viewportBound.width - TableScroller.scrollSize - tableBound.width + 'px');
        }
    }
    else {
        if (overWidth) {
            this.$hscrollbarCtn.addStyle('bottom', viewportBound.height - TableScroller.scrollSize - tableBound.height + 'px');
        }
    }
};

TableScroller.prototype._updateContentSize = function () {
    if (!this.$fixedTable) return;
    this._updateFixedTableSize();
    this._updateHeaderScrollerSize();
    this._updateLeftTableSize();
    this._updateLinesSize();
    this._updateScrollBarSize();
};

TableScroller.property = {};

TableScroller.property.fixedCol = {
    set: function (value) {
        value = value || 0;
        this._fixedCol = value;
        if (this.$content) {
            this._updateContent();
            this.sync.then(this._updateContentSize.bind(this)).then(function () {
                setTimeout(this._updateContentSize.bind(this), 30)
            }.bind(this));
        }
    },
    get: function () {
        return this._fixedCol || 0;
    }
};


ACore["d" /* default */].install(TableScroller);

/* harmony default export */ var js_TableScroller = (TableScroller);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/tablevscroller.css
var tablevscroller = __webpack_require__(218);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TableVScroller.js




var TableVScroller_ = ACore["d" /* default */]._;
var TableVScroller_$ = ACore["d" /* default */].$;

function TableVScroller() {
    var thisTS = this;
    this.$attachHook = TableVScroller_$('attachhook', this);
    this.$attachHook.updateSize = this.update.bind(this);

    this.sync = new Promise(function (rs) {
        thisTS.$attachHook.on('error', rs)
    });
    this.$viewport = TableVScroller_$('.absol-table-vscroller-viewport', this);
    this.$attachHook.on('error', function () {
        Dom["b" /* default */].addToResizeSystem(thisTS.$attachHook);
        this.updateSize();
    });
    this.$topTable = TableVScroller_$('.absol-table-vscroller-head', this);
    this.$headLine = TableVScroller_$('.absol-table-vscroller-head-line', this);
}

TableVScroller.tag = 'TableVScroller'.toLowerCase();

TableVScroller.render = function () {
    return TableVScroller_(
        {
            class: 'absol-table-vscroller',
            child: [
                '.absol-table-vscroller-viewport',
                'table.absol-table-vscroller-head',
                '.absol-table-vscroller-head-line',
                'attachhook'
            ]
        }
    );
};

TableVScroller.prototype.clearChild = function () {
    this.$viewport.clearChild();
    this.$topTable.clearChild();
};

TableVScroller.prototype.addChild = function (elt) {
    if (this.$viewport.childNodes.length == 0) {
        if (elt.tagName && elt.tagName.toLowerCase() == 'table') {
            this.$viewport.addChild(elt);
            this.$table = TableVScroller_$(elt);
            this.$thead = TableVScroller_$('thead', elt);
            this.$tr = TableVScroller_$('tr', this.$thead);
            this.$topThead = this.$thead.cloneNode(true);
            this.$topTr = TableVScroller_$('tr', this.$topThead);
            this.$topTable.addChild(this.$topThead).addStyle('display', 'none');
            this.update();
        }
        else {
            throw new Error('Element must be a table!');
        }
    }
    else {
        throw new Error("Only 1 table accepted!");
    }
};

TableVScroller.prototype._trackBackgroundColor = function (element) {
    var current = this.$thead;
    var res;
    while (current && !res && res != 'rgba(0, 0, 0, 0)') {
        res = window.getComputedStyle(element).getPropertyValue('background-color');
        current = current.parentNode;

    }
    if (res == 'rgba(0, 0, 0, 0)') return 'white';
    return res;
}

TableVScroller.prototype.updateStyle = function () {
    if (!this.$thead) return;
    var clazz = this.$table.attr('class');
    if (clazz) {
        clazz = clazz.trim().split(/\s+/);
        for (var i = 0; i < clazz.length; ++i) {
            this.$topTable.addClass(clazz[i]);
        }
    }
    var bgColor = this._trackBackgroundColor(this.$thead);
    this.$topTable.addStyle('background-color', bgColor);
};


TableVScroller.prototype.updateSize = function () {
    var theadBound = this.$thead.getBoundingClientRect();
    var tableBound = this.$table.getBoundingClientRect();
    this.$topTable.addStyle({
        width: tableBound.width + 'px',
        height: theadBound.height + 'px'
    });
    this.$headLine.addStyle({
        top: theadBound.height + 'px',
        maxWidth: tableBound.width + 'px'
    });

    if (this.$viewport.clientHeight < this.$viewport.scrollHeight) {
        this.addClass('scroll-v');
    }
    else {
        this.removeClass('scroll-v');
    }
    var realNodes = this.$tr.childNodes;
    var topNodes = this.$topTr.childNodes;

    for (var i = 0; i < realNodes.length; ++i) {
        if (!realNodes[i].tagName) continue;
        var wstyle = window.getComputedStyle(TableVScroller_$(realNodes[i])).getPropertyValue('width');
        TableVScroller_$(topNodes[i]).attr('style', realNodes[i].attr('style')).addStyle('width', wstyle);
    }
    this.$topTable.removeStyle('display');
}


TableVScroller.prototype.update = function () {
    if (!this.$thead) return;
    this.updateStyle();
    this.updateSize();
};

ACore["d" /* default */].install(TableVScroller);

/* harmony default export */ var js_TableVScroller = (TableVScroller);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/textarea2.css
var textarea2 = __webpack_require__(220);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/selectmenu.css
var selectmenu = __webpack_require__(94);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/list/search.js
var search = __webpack_require__(17);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/SelectMenu.js








/*global absol*/
var SelectMenu_ = ACore["d" /* default */]._;
var SelectMenu_$ = ACore["d" /* default */].$;

ACore["d" /* default */].creator['dropdown-ico'] = function () {
    return SelectMenu_([
        '<svg class="dropdown" width="100mm" height="100mm" version="1.1" viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg">',
        '<g transform="translate(0,-197)">',
        '<path d="m6.3152 218.09a4.5283 4.5283 0 0 0-3.5673 7.3141l43.361 55.641a4.5283 4.5283 0 0 0 7.1421 7e-3l43.496-55.641a4.5283 4.5283 0 0 0-3.5673-7.3216z" />',
        '</g>',
        '</svg>'
    ].join(''));
};


function SelectMenu() {
    var thisSM = this;
    this._items = [];
    this._value = null;
    this._lastValue = null;
    this.$holderItem = SelectMenu_$('.absol-selectmenu-holder-item', this);

    this.$anchorCtn = SelectMenu.getAnchorCtn();
    this.$anchor = SelectMenu_('.absol-selectmenu-anchor.absol-disabled').addTo(this.$anchorCtn);
    this.$anchorContentCtn = SelectMenu_('.absol-selectmenu-anchor-content-container').addTo(this.$anchor);

    this.$dropdownBox = SelectMenu_('.absol-selectmenu-dropdown-box').addTo(this.$anchorContentCtn);
    this.$searchTextInput = SelectMenu_('searchtextinput').addStyle('display', 'none').addTo(this.$dropdownBox);
    this.$vscroller = SelectMenu_('bscroller').addTo(this.$dropdownBox);
    this.$selectlist = SelectMenu_('selectlist', this).addTo(this.$vscroller)
        .on('sizechangeasync', this.eventHandler.listSizeChangeAsync)
        .on('valuevisibilityasync', this.eventHandler.listValueVisibility);


    this.$scrollTrackElts = [];
    this.$removableTrackElts = [];

    this._itemsByValue = {};
    this.$searchTextInput.on('stoptyping', this.eventHandler.searchModify);
    this._searchCache = {};
    this.$selectlist.on('pressitem', this.eventHandler.selectlistPressItem, true);
    this.$selectlist.on('pressitem', function () {
        thisSM.isFocus = false;
    }, true);
    this._lastValue = "NOTHING_VALUE";
    this._resourceReady = true;


    this.on('mousedown', this.eventHandler.click, true);
    this.on('blur', this.eventHandler.blur);

    this.selectListBound = { height: 0, width: 0 };
    this.$attachhook = SelectMenu_$('attachhook', this)
        .on('error', this.eventHandler.attached);

    this.sync = new Promise(function (rs) {
        SelectMenu_$('attachhook', this).once('error', function () {
            rs();
        });
    });

    this._selectListScrollSession = null;
    this._itemIdxByValue = null;
    return this;
}

SelectMenu.tag = 'selectmenu-old';
SelectMenu.render = function () {
    return SelectMenu_({
        class: ['absol-selectmenu'],
        extendEvent: ['change', 'minwidthchange'],
        attr: {
            tabindex: '1'
        },
        child: [
            '.absol-selectmenu-holder-item',
            {
                tag: 'button',
                class: 'absol-selectmenu-btn',
                child: ['dropdown-ico']
            },
            'attachhook',
        ]
    });
};

SelectMenu.optimizeResource = true;

// //will remove after SelectMenu completed
SelectMenu.getRenderSpace = function () {
    if (!SelectMenu.getRenderSpace.warned) {
        console.warn('SelectMenu.getRenderSpace() will be removed in next version');
    }
    SelectMenu.getRenderSpace.warned = true;
    if (!SelectMenu.$renderSpace) {
        SelectMenu.$renderSpace = SelectMenu_('.absol-selectmenu-render-space')
            .addTo(document.body);
    }
    return SelectMenu.$renderSpace;
};


SelectMenu.getAnchorCtn = function () {
    if (!SelectMenu.$anchorCtn) {
        SelectMenu.$anchorCtn = SelectMenu_('.absol-selectmenu-anchor-container')
            .addTo(document.body);
    }
    return SelectMenu.$anchorCtn;
};


SelectMenu.prototype.updateItem = function () {
    this.$holderItem.clearChild();
    if (this._itemsByValue[this.value]) {
        var elt = SelectMenu_({ tag: 'selectlistitem', props: { data: this._itemsByValue[this.value] } }).addTo(this.$holderItem);
        elt.$descCtn.addStyle('width', this.$selectlist._descWidth + 'px');
    }
};

SelectMenu.prototype._dictByValue = function (items) {
    var dict = {};
    var item;
    for (var i = 0; i < items.length; ++i) {
        item = items[i];
        dict[item.value + ''] = item;
    }
    return dict;
};


SelectMenu.prototype.init = function (props) {
    props = props || {};
    Object.keys(props).forEach(function (key) {
        if (props[key] === undefined) delete props[key];
    });

    if (!('value' in props)) {
        if (props.items && props.items.length > 0) props.value = typeof props.items[0] == 'string' ? props.items[0] : props.items[0].value;
    }
    var value = props.value;
    delete props.value;
    this.super(props);
    this.value = value;
};

SelectMenu.property = {};
SelectMenu.property.items = {
    set: function (value) {
        this._searchCache = {};
        this._itemIdxByValue = null;
        /**
         * verity data
         */
        if (value) {
            value.forEach(function (it) {
                if (it && it.text) {
                    it.text = it.text + '';
                }
            });
        }

        this._items = value;
        this._itemsByValue = this._dictByValue(value);

        if (!this._itemsByValue[this.value] && value.length > 0) {
            this.value = value[0].value;
        }
        else
            this.updateItem();

        this.$dropdownBox.removeStyle('min-width');
        this.selectListBound = this.$selectlist.setItemsAsync(value || []);
        this.style.setProperty('--select-list-desc-width', this.$selectlist.measuredSize.descWidth + 'px');
        this._resourceReady = true;

        this.addStyle('min-width', this.selectListBound.width + 2 + 23 + 'px');
        this.emit('minwidthchange', {
            target: this,
            value: this.selectListBound.width + 2 + 23,
            type: 'minwidthchange'
        }, this);
    },
    get: function () {
        return this._items || [];
    }
};

SelectMenu.property.value = {
    set: function (value) {
        this.$selectlist.value = value;
        this._lastValue = value;
        this.updateItem();
    },
    get: function () {
        return this.$selectlist.value;
    }
};


SelectMenu.property.enableSearch = {
    set: function (value) {
        this._enableSearch = !!value;
        if (value) {
            this.$searchTextInput.removeStyle('display');
        }
        else {
            this.$searchTextInput.addStyle('display', 'none');
        }
    },
    get: function () {
        return !!this._enableSearch;
    }
};

SelectMenu.prototype.updateDropdownPostion = function (updateAnchor) {
    if (!this.isFocus) {
        this.$anchorContentCtn
            .removeStyle('left')
            .removeStyle('top');
        this.$dropdownBox.removeStyle('min-width');
        return;
    }
    var bound = this.getBoundingClientRect();
    if (!updateAnchor) {
        var outBound = Dom["b" /* default */].traceOutBoundingClientRect(this);

        if (!this.isFocus || bound.top > outBound.bottom || bound.bottom < outBound.top) {
            this.isFocus = false;
            return;
        }

        var anchorOutBound = Dom["b" /* default */].traceOutBoundingClientRect(this.$anchor);
        var searchBound = this.$searchTextInput.getBoundingClientRect();
        var availableTop = bound.top - anchorOutBound.top - (this.enableSearch ? searchBound.height + 8 : 0) - 20;
        var availableBottom = anchorOutBound.bottom - bound.bottom - (this.enableSearch ? searchBound.height + 8 : 0) - 20;

        if (this.forceDown || availableBottom >= this.selectListBound.height || availableBottom > availableTop) {
            this.isDropdowUp = false;
            if (this.$dropdownBox.firstChild != this.$searchTextInput) {
                this.$searchTextInput.selfRemove();
                this.$dropdownBox.addChildBefore(this.$searchTextInput, this.$vscroller);
            }
            this.$vscroller.addStyle('max-height', availableBottom + 'px');
        }
        else {
            this.isDropdowUp = true;
            if (this.$dropdownBox.lastChild !== this.$searchTextInput) {
                this.$searchTextInput.selfRemove();
                this.$dropdownBox.addChild(this.$searchTextInput);
            }
            this.$vscroller.addStyle('max-height', availableTop + 'px');
        }
        this.$dropdownBox.addStyle('min-width', bound.width + 'px');
    }
    var anchorBound = this.$anchor.getBoundingClientRect();
    if (this.isDropdowUp) {
        this.$anchorContentCtn.addStyle({
            left: bound.left - anchorBound.left + 'px',
            top: bound.top - anchorBound.top - this.$dropdownBox.clientHeight - 1 + 'px',
        });
    }
    else {
        this.$anchorContentCtn.addStyle({
            left: bound.left - anchorBound.left + 'px',
            top: bound.bottom - anchorBound.top + 'px',
        });
    }
};

SelectMenu.prototype.scrollToSelectedItem = function () {
    var self = this;
    setTimeout(function () {
        if (self.$selectlist.$selectedItem) {
            var fistChildBound = self.$selectlist.childNodes[1].getBoundingClientRect();
            var lastChildBound = self.$selectlist.lastChild.getBoundingClientRect();
            var listBound = {
                top: fistChildBound.top,
                height: lastChildBound.bottom - fistChildBound.top,
                bottom: lastChildBound.bottom
            }
            var itemBound = self.$selectlist.$selectedItem.getBoundingClientRect();
            if (self.isDropdowUp) {
                var scrollBound = self.$vscroller.getBoundingClientRect();
                self.$vscroller.scrollTop = Math.max(itemBound.bottom - scrollBound.height - listBound.top, 0);

            }
            else {
                self.$vscroller.scrollTop = itemBound.top - listBound.top;
            }
        }
    }.bind(this), 3);
};


SelectMenu.prototype.startTrackScroll = function () {
    var trackElt = this.parentElement;
    while (trackElt) {
        if (trackElt.addEventListener) {
            trackElt.addEventListener('scroll', this.eventHandler.scrollParent, false);

        }
        else {
            trackElt.attachEvent('onscroll', this.eventHandler.scrollParent, false);
        }

        this.$scrollTrackElts.push(trackElt);
        trackElt = trackElt.parentElement;
    }
    if (document.addEventListener) {
        document.addEventListener('scroll', this.eventHandler.scrollParent, false);

        document.addEventListener('wheel', this.eventHandler.wheelDocument, true);
    }
    else {
        document.attachEvent('onscroll', this.eventHandler.scrollParent, false);
    }
    this.$scrollTrackElts.push(document);

};

SelectMenu.prototype.stopTrackScroll = function () {
    var trackElt;
    for (var i = 0; i < this.$scrollTrackElts.length; ++i) {
        trackElt = this.$scrollTrackElts[i];
        if (trackElt.removeEventListener) {
            trackElt.removeEventListener('scroll', this.eventHandler.scrollParent, false);
        }
        else {
            trackElt.dettachEvent('onscroll', this.eventHandler.scrollParent, false);

        }
    }
    this.$scrollTrackElts = [];
};

SelectMenu.prototype.startListenRemovable = function () {
    var removableElt = this.parentElement;
    while (removableElt) {
        if (removableElt.isSupportedEvent && removableElt.isSupportedEvent('remove')) {
            removableElt.on('remove', this.eventHandler.removeParent);
        }
        removableElt = removableElt.parentElement;
    }
};

SelectMenu.prototype.stopListenRemovable = function () {
    var removableElt;
    while (this.$removableTrackElts.length > 0) {
        removableElt = this.$removableTrackElts.pop();
        removableElt.off('remove', this.eventHandler.removeParent);
    }
};

SelectMenu.prototype._releaseResource = function () {
    this.$selectlist.items = [];
};

SelectMenu.prototype._requestResource = function () {
    this.$selectlist.items = this._items || [];
};

SelectMenu.property.isFocus = {
    set: function (value) {
        var self = this;
        value = !!value;
        if (value == this.isFocus) return;
        this._isFocus = value;
        if (value) {
            this.startTrackScroll();
            this.selectListScrollToken = null;//force scroll
            var isAttached = false;
            setTimeout(function () {
                if (isAttached) return;
                SelectMenu_$('body').on('mousedown', self.eventHandler.bodyClick);
                isAttached = true;
            }, 1000);
            SelectMenu_$('body').once('click', function () {
                setTimeout(function () {
                    if (isAttached) return;
                    SelectMenu_$('body').on('mousedown', self.eventHandler.bodyClick);
                    isAttached = true;
                }, 10);
            });

            if (this.enableSearch) {
                setTimeout(function () {
                    self.$searchTextInput.focus();
                }, 50);
            }

            this.updateDropdownPostion();
            this.scrollToSelectedItem();
            this.$anchor.removeClass('absol-disabled');
        }
        else {
            this.$anchor.addClass('absol-disabled');
            this.stopTrackScroll();
            SelectMenu_$('body').off('mousedown', this.eventHandler.bodyClick);
            setTimeout(function () {
                if (self.$searchTextInput.value != 0) {
                    self.$searchTextInput.value = '';
                    self.$selectlist.items = self.items;
                    self._resourceReady = true;
                    self.$selectlist.removeClass('as-searching');
                }
            }, 100)
            this.updateItem();
        }
    },
    get: function () {
        return !!this._isFocus;
    }
};


SelectMenu.property.disabled = {
    set: function (value) {
        if (value) {
            this.addClass('disabled');
        }
        else {
            this.removeClass('disabled');
        }
    },
    get: function () {
        return this.containsClass('disabled');
    }
};


SelectMenu.property.hidden = {
    set: function (value) {
        if (value) {
            this.addClass('hidden');
        }
        else {
            this.removeClass('hidden');
        }
    },
    get: function () {
        return this.addClass('hidden');
    }
};

SelectMenu.property.selectedIndex = {
    get: function () {
        if (!this._itemIdxByValue) {
            this._itemIdxByValue = {};
            for (var i = 0; i < this._items.length; ++i) {
                this._itemIdxByValue[this._items[i].value] = i;
            }
        }
        var idx = this._itemIdxByValue[this._value];
        return idx >= 0 ? idx : -1;
    }
};

/**
 * @type {SelectMenu}
 */
SelectMenu.eventHandler = {};

SelectMenu.eventHandler.attached = function () {
    if (this._updateInterval) return;
    if (!this.$anchor.parentNode) this.$anchor.addTo(this.$anchorCtn);
    this.$attachhook.updateSize = this.$attachhook.updateSize || this.updateDropdownPostion.bind(this);
    Dom["b" /* default */].addToResizeSystem(this.$attachhook);
    this.stopListenRemovable();
    this.startListenRemovable();
    if (!this._resourceReady) {
        this._requestResource();
        this._resourceReady = true;
    }
    this._updateInterval = setInterval(function () {
        if (!this.isDescendantOf(document.body)) {
            clearInterval(this._updateInterval);
            this._updateInterval = undefined;
            this.$anchor.selfRemove();
            this.stopTrackScroll();
            this.stopListenRemovable();
            this.eventHandler.removeParent();
        }
    }.bind(this), 10000);
};


SelectMenu.eventHandler.scrollParent = function (event) {
    var self = this;
    if (this._scrollFrameout > 0) {
        this._scrollFrameout = 10;
        return;
    }
    this._scrollFrameout = this._scrollFrameout || 10;

    function update() {
        self.updateDropdownPostion(false);
        self.scrollToSelectedItem();
        self._scrollFrameout--;
        if (self._scrollFrameout > 0) requestAnimationFrame(update);
    }

    update();
};

SelectMenu.eventHandler.removeParent = function (event) {
    this._releaseResource();
    this._resourceReady = false;
};

SelectMenu.eventHandler.click = function (event) {
    if (EventEmitter["b" /* default */].isMouseRight(event)) return;
    this.isFocus = !this.isFocus;
};


SelectMenu.eventHandler.bodyClick = function (event) {
    if (!EventEmitter["b" /* default */].hitElement(this, event) && !EventEmitter["b" /* default */].hitElement(this.$anchor, event)) {
        setTimeout(function () {
            this.isFocus = false;
        }.bind(this), 5)
    }
};

SelectMenu.eventHandler.selectlistPressItem = function (event) {
    this.updateItem();
    if (this._lastValue != this.value) {
        event.lastValue = this._lastValue;
        event.value = this.value;
        setTimeout(function () {
            this.emit('change', event, this);
        }.bind(this), 1)
        this._lastValue = this.value;
    }
};


SelectMenu.eventHandler.searchModify = function (event) {
    var filterText = this.$searchTextInput.value.replace(/((\&nbsp)|(\s))+/g, ' ').trim();
    if (filterText.length == 0) {
        this._resourceReady = true;
        this.$selectlist.items = this.items;
        this.scrollToSelectedItem();
        this.$selectlist.removeClass('as-searching');
    }
    else {
        this.$selectlist.addClass('as-searching');
        var view = [];
        if (!this._searchCache[filterText]) {
            if (this._items.length > 0 && !this._items[0].__nvnText__) {
                Object(search["c" /* prepareSearchForList */])(this._items);
            }

            view = Object(search["d" /* searchListByText */])(filterText, this._items);
            this._searchCache[filterText] = view;
        }
        else {
            view = this._searchCache[filterText];
        }
        this.$selectlist.items = view;
        this._resourceReady = true;
        this.$vscroller.scrollTop = 0;
    }

    this.selectListBound = this.$selectlist.getBoundingClientRect();
    this.updateDropdownPostion(true);
};

SelectMenu.eventHandler.listSizeChangeAsync = function () {
    this.updateDropdownPostion();
};

SelectMenu.eventHandler.listValueVisibility = function (event) {
    if (!this.isFocus) return;
    if (this._selectListScrollSession == event.session) return;

    this._selectListScrollSession = event.session;
    this.scrollToSelectedItem();
};


ACore["d" /* default */].install(SelectMenu);

/* harmony default export */ var js_SelectMenu = (SelectMenu);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TextArea2.js





var TextArea2_ = ACore["d" /* default */]._;
var TextArea2_$ = ACore["d" /* default */].$;


function TextArea2() {
    this.on('keydown', this.eventHandler.keydown);
    this.on('paste', this.eventHandler.paste);
    this.on('cut', this.eventHandler.paste);
}

TextArea2.tag = 'TextArea2'.toLowerCase();

TextArea2.render = function () {
    return TextArea2_('textarea.absol-textarea2');
};


TextArea2.getRenderPre = function () {
    if (!TextArea2.$preSpace) {
        TextArea2.$preSpace = TextArea2_('textarea').addStyle({
            'overflow': 'hidden',
            'height': '12px',
            'resize': 'none'
        }).addTo(js_SelectMenu.getRenderSpace());
    }
    return TextArea2.$preSpace;
};

TextArea2.eventHandler = {};

TextArea2.eventHandler.keydown = function (event) {
    if (event.altKey || event.ctrlKey) return;
    var key = event.key;
    var selectPost = this.getInputSelection();
    var leftText = this.value.substring(0, selectPost.start);
    var rightText = this.value.substring(selectPost.end);


    var middText = '';
    if (key == 'Enter') {
        middText = '\n';
    }
    else if (key == 'Backspace') {
        if (leftText.length > 0) {
            leftText = leftText.substring(0, leftText.length - 1);
        }
    }
    else if (key == 'Delete') {
        if (selectPost.start < selectPost.end) {
            middText = '';
        }
        else if (rightText.length > 0) {
            rightText = rightText.substring(1);
        }
    }
    else if (key.length == 1) {//char
        middText = key;
    }
    else {
        return;
    }
    var newText = leftText + middText + rightText;

    var heightSyle = this._measureHeight(newText);
    this.addStyle('height', heightSyle);
};


TextArea2.eventHandler.paste = function (event) {
    // var text  = 
    var cl = event.clipboardData || window.clipboardData;
    var middText = cl.getData('Text') || '';
    var selectPost = this.getInputSelection();
    var leftText = this.value.substring(0, selectPost.start);
    var rightText = this.value.substring(selectPost.end);
    var newText = leftText + middText + rightText;

    var heightSyle = this._measureHeight(newText);
    this.addStyle('height', heightSyle);

};


TextArea2.eventHandler.cut = function (event) {
    // var text  = 
    var cl = event.clipboardData || window.clipboardData;
    var selectPost = this.getInputSelection();
    var leftText = this.value.substring(0, selectPost.start);
    var rightText = this.value.substring(selectPost.end);
    var newText = leftText + rightText;

    var heightSyle = this._measureHeight(newText);
    this.addStyle('height', heightSyle);

};

TextArea2.prototype._measureHeight = function (text) {
    var pre = TextArea2.getRenderPre();
    pre.addStyle('padding-left', this.getComputedStyleValue('padding-left'))
    pre.addStyle('padding-right', this.getComputedStyleValue('padding-right'))
    pre.addStyle('padding-top', this.getComputedStyleValue('padding-top'))
    pre.addStyle('padding-bottom', this.getComputedStyleValue('padding-bottom'));
    pre.addStyle('width', this.getComputedStyleValue('width'));
    pre.addStyle('height', this.getFontSize() + 'px');
    pre.addStyle('boder', this.getComputedStyleValue('boder'));
    pre.addStyle('font-size', this.getComputedStyleValue('font-size'));
    pre.addStyle('font-family', this.getComputedStyleValue('font-family'));
    pre.value = text;
    var result = pre.scrollHeight + 'px';
    return result;
};

/**
 * Return an object with the selection range or cursor position (if both have the same value)
 * @param {DOMElement} el A dom element of a textarea or input text.
 * @return {Object} reference Object with 2 properties (start and end) with the identifier of the location of the cursor and selected text.
 **/
TextArea2.prototype.getInputSelection = function () {
    var start = 0, end = 0, normalizedValue, range, textInputRange, len, endRange;

    if (typeof this.selectionStart == "number" && typeof this.selectionEnd == "number") {
        start = this.selectionStart;
        end = this.selectionEnd;
    }
    else {
        range = document.selection.createRange();

        if (range && range.parentElement() == this) {
            len = this.value.length;
            normalizedValue = this.value.replace(/\r\n/g, "\n");

            // Create a working TextRange that lives only in the input
            textInputRange = this.createTextRange();
            textInputRange.moveToBookmark(range.getBookmark());

            // Check if the start and end of the selection are at the very end
            // of the input, since moveStart/moveEnd doesn't return what we want
            // in those cases
            endRange = this.createTextRange();
            endRange.collapse(false);

            if (textInputRange.compareEndPoints("StartToEnd", endRange) > -1) {
                start = end = len;
            }
            else {
                start = -textInputRange.moveStart("character", -len);
                start += normalizedValue.slice(0, start).split("\n").length - 1;

                if (textInputRange.compareEndPoints("EndToEnd", endRange) > -1) {
                    end = len;
                }
                else {
                    end = -textInputRange.moveEnd("character", -len);
                    end += normalizedValue.slice(0, end).split("\n").length - 1;
                }
            }
        }
    }

    return {
        start: start,
        end: end
    };
}

ACore["d" /* default */].install(TextArea2);
/* harmony default export */ var js_TextArea2 = (TextArea2);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/textclipboard.css
var textclipboard = __webpack_require__(222);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TextClipboard.js



var TextClipboard_ = ACore["d" /* default */]._;
var TextClipboard_$ = ACore["d" /* default */].$;

function TextClipboard() {
    this.$textarea = TextClipboard_('<textarea class="absol-text-clipboard" wrap="off" autocorrect="off"' +
        ' autocapitalize="off" spellcheck="false"></textarea>').addTo(this);
}

TextClipboard.tag = 'TextClipboard'.toLowerCase();

TextClipboard.render = function () {
    return TextClipboard_({
        style: {
            positon: 'fixed',
            opacity: 0,
            width: '1px',
            height: '1px',
            top: 0,
            left: 0
        }
    });
};

TextClipboard.prototype.copy = function (text) {
    this.$textarea.value = text;
    this.$textarea.select();
    document.execCommand('copy');
};

TextClipboard.prototype.paste = function () {
    this.$textarea.select();
    document.execCommand('paste');
};

ACore["d" /* default */].install(TextClipboard);

/* harmony default export */ var js_TextClipboard = (TextClipboard);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/timeinput.css
var timeinput = __webpack_require__(224);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TimeInput.js









var TimeInput_STATE_NEW = 1;
var TimeInput_STATE_EDITED = 2;
var TimeInput_STATE_NONE = 0;

var TimeInput_ = ACore["d" /* default */]._;
var TimeInput_$ = ACore["d" /* default */].$;

/***
 * @extends {AElement}
 * @constructor
 */
function TimeInput() {
    this._editingData = {};
    this._isOpenPicker = false;
    this._lastEmitValue = null;
    this._hour = null;
    this._minute = null;
    this._format = 'hh:mm a';
    this.$clockBtn = TimeInput_$('.as-time-input-icon-btn', this)
        .on('click', this.eventHandler.clickClockBtn);
    this.$text = TimeInput_$('input', this)
        .on('mousedown', this.eventHandler.mouseDownInput)
        .on('mouseup', this.eventHandler.mouseUpInput)
        .on('dblclick', this.eventHandler.dblclickInput)
        .on('keydown', this.eventHandler.keydown)
        .on('blur', this.eventHandler.inputBlur)
        .on('contextmenu', function (event) {
            event.preventDefault();
        });

    this.$clearBtn = TimeInput_$('button.as-time-input-clear-btn', this)
        .on('click', this.clear.bind(this));

    this.$domSignal = TimeInput_('attachhook').addTo(this);
    this.domSignal = new DomSignal["a" /* default */](this.$domSignal);
    this.domSignal.on('request_auto_select', this._autoSelect.bind(this));
    this.dayOffset = null;
    this.hour = null;
    this.minute = null;
    this.disabled = false;
    this.notNull = true;
}


TimeInput.tag = 'timeinput';

TimeInput.render = function () {
    return TimeInput_({
        class: 'ac-time-input',
        extendEvent: ['change'],
        child: [
            {
                tag: 'input',
                class: 'as-time-input-text',
                attr: {
                    type: 'text'
                }
            },
            {
                tag: 'button',
                class: 'as-time-input-clear-btn',
                child: 'span.mdi.mdi-close-circle'
            },
            {
                tag: 'button',
                class: 'as-time-input-icon-btn',
                child: 'span.mdi.mdi-clock-outline'
            }
        ]
    })
};


TimeInput.prototype._autoSelect = js_DateTimeInput.prototype._autoSelect;


TimeInput.prototype.tokenMap = {
    h: 'h',
    H: 'H',
    HH: 'H',
    hh: 'h',
    m: 'm',
    mm: 'm',
    a: 'a'
};


TimeInput.prototype.tokenRegex = js_DateTimeInput.prototype.tokenRegex;
TimeInput.prototype._tokenAt = js_DateTimeInput.prototype._tokenAt;
TimeInput.prototype._editNextToken = js_DateTimeInput.prototype._editNextToken;
TimeInput.prototype._editPrevToken = js_DateTimeInput.prototype._editPrevToken;
TimeInput.prototype._makeTokenDict = js_DateTimeInput.prototype._makeTokenDict;

TimeInput.prototype._makeValueDict = function (hour, minute) {
    var res = {};
    if (typeof hour == 'number' && hour >= 0 && hour < 24) {
        res.h = { value: 1 + (hour - 1) % 12 };
        res.H = { value: hour };
        res.a = {
            value: hour >= 12 ? 'PM' : 'AM'
        };
    }
    else {
        res.h = { value: NaN };
        res.H = { value: NaN };
        res.a = { value: 'a' };
    }

    if (typeof minute === "number" && minute >= 0 && minute < 60) {
        res.m = { value: minute };
    }
    else {
        res.m = { value: NaN };
    }
    return res;
};

TimeInput.prototype._applyValue = function (hour, minute) {
    this._hour = hour;
    this._minute = minute;
    this.$text.value = this._applyTokenDict(this._format, this._makeValueDict(hour, minute));
    this._updateNullClass();
};

TimeInput.prototype._updateNullClass = function () {
    if (this._hour == null && this._minute == null) {
        this.addClass('as-value-null');
    }
    else {
        this.removeClass('as-value-null');
    }
};


TimeInput.prototype._applyTokenDict = function (format, dict) {
    var rgx = new RegExp(this.tokenRegex.source, 'g');
    var tokenMap = this.tokenMap;
    return format.replace(rgx, function (full, g1, g2, sourceText) {
        if (g1 && g1 === 'a') {
            return dict[g1].value;
        }
        else if (g1 && tokenMap[g1]) {
            var ident = tokenMap[g1];
            if (dict[ident] && !isNaN(dict[ident].value)) {
                return Object(utils["zeroPadding"])(dict[ident].value, g1.length);
            }
            else {
                return full;
            }
        }
        else
            return full;
    });
};

TimeInput.prototype._correctingInput = function () {
    var tkDict = this._makeTokenDict(this.$text.value);

    // TODO: check min, max,
};

TimeInput.prototype._correctingCurrentToken = function () {
    var token = this._tokenAt(this.$text.selectionStart);
    if (!token) return;
    var value;
    if (token.ident === 'a') {
        if (token.text !== 'a' && token.text !== 'AM' && token.text !== 'PM') {
            token.replace('a', false);
        }
    }
    else {
        value = parseInt(token.text);
        var rqMin = {
            h: 1, hh: 1,
            m: 0, mm: 0,
            H: 0, HH: 0
        }[token.ident];
        var rqMax = {
            H: 23, HH: 23,
            h: 12, hh: 12,
            m: 59, mm: 59
        }[token.ident];
        if (rqMin !== undefined) {
            if (!isNaN(value)) {
                if ((value < rqMin || value > rqMin)) {
                    value = Math.max(rqMin, Math.min(rqMax, value));
                    token.replace(Object(utils["zeroPadding"])(value, token.ident.length), false);
                    this._editingData[this.tokenMap[token.ident]] = value;
                }
            }
            else if (token.text !== token.ident) {
                token.replace(token.ident, false);
            }
        }
    }
};

TimeInput.prototype._loadValueFromInput = function () {
    var tkDick = this._makeTokenDict(this.$text.value);
    var hour = NaN;
    var minute = NaN;
    if (tkDick.H) {
        hour = Math.min(23, Math.max(0, tkDick.H.value));
    }
    else if (tkDick.h) {
        hour = Math.min(12, Math.max(1, tkDick.h.value));
        if (tkDick.a && tkDick.a.value === 'PM') {
            hour += 12;
        }
    }
    if (tkDick.m) {
        minute = Math.min(59, Math.max(0, tkDick.m.value));
    }
    this._hour = isNaN(hour) ? null : hour;
    this._minute = isNaN(minute) ? null : minute;
    this._updateNullClass();
};

TimeInput.prototype.clear = function (event) {
    this._applyValue(null, null);
    this._notifyIfChange(event);
}

TimeInput.prototype._notifyIfChange = function (event) {
    if (this._lastEmitValue === this.dayOffset) return;
    this.emit('change', {
        type: 'change',
        target: this,
        dayOffset: this.dayOffset,
        hour: this.hour,
        minute: this.minute,
        originEvent: event
    }, this);

    this._lastEmitValue = this.dayOffset;
};


TimeInput.property = {};

TimeInput.property.hour = {
    set: function (value) {
        if (typeof value == "number") {
            value = (value % 24) || 0;
        }
        else {
            value = null;
        }
        this._applyValue(value, this._minute);
        this._lastEmitValue = this.dayOffset;
    },
    get: function () {
        return this._hour;
    }
};


TimeInput.property.minute = {
    set: function (value) {
        if (typeof value == "number") {
            value = (value % 60) || 0;
        }
        else {
            value = null;
        }
        this._applyValue(this._hour, value);
        this._lastEmitValue = this.dayOffset;
    },
    get: function () {
        return this._minute;
    }
};


TimeInput.property.dayOffset = {
    set: function (value) {
        if (typeof value == "number" || (value && value.getTime)) {
            value = value || 0;
            if (value.getTime)
                value = value.getTime() - Object(datetime["beginOfDay"])(value).getTime();
            else {
                value = value % datetime["MILLIS_PER_DAY"];
            }

            this.hour = Math.floor(value / datetime["MILLIS_PER_HOUR"]);
            this.minute = Math.floor((value % datetime["MILLIS_PER_HOUR"]) / datetime["MILLIS_PER_MINUTE"]);
        }
        else {
            this.hour = null;
            this.minute = null;
        }
    },
    get: function () {
        if (this._hour === null || this._minute === null) return null;
        return this._hour * datetime["MILLIS_PER_HOUR"] + this._minute * datetime["MILLIS_PER_MINUTE"];
    }
};


TimeInput.property.disabled = {
    set: function (value) {
        value = !!value;
        this._disabled = value;
        if (value) this.addClass('as-disabled');
        else this.removeClass('as-disabled');
        this.$text.disabled = value;
    },
    get: function () {
        return this._disabled;
    }
};

TimeInput.property.format = {
    enumerable: true,
    configurable: true,
    set: function (value) {
        if (typeof value !== "string") value = "hh:mm a";
        value = value || 'hh:mm a';
        this._format = value;
        this.dayOffset = this['dayOffset'];
    },
    get: function () {
        return this._format;
    }
};

TimeInput.property.s24 = {
    get: function () {
        var t = this.format.match(new RegExp(this.tokenRegex.source, 'g'));
        return !t || t.indexOf('a') < 0;
    }
};

TimeInput.property.notNull = {
    set: function (value) {
        if (value) {
            if (this.dayOffset === null) {
                this.dayOffset = 0;
            }
            this.addClass('as-must-not-null');

        }
        else {
            this.removeClass('as-must-not-null');
        }
    },
    get: function () {
        return this.containsClass('as-must-not-null');
    }
};

TimeInput.eventHandler = {};

TimeInput.eventHandler.clickClockBtn = function () {
    this._attachPicker(this);
};


TimeInput.eventHandler.mouseUpInput = js_DateTimeInput.eventHandler.mouseUpInput;
TimeInput.eventHandler.mouseDownInput = js_DateTimeInput.eventHandler.mouseDownInput;
TimeInput.eventHandler.dblclickInput = js_DateTimeInput.eventHandler.dblclickInput;
TimeInput.eventHandler.inputBlur = js_DateTimeInput.eventHandler.inputBlur;

TimeInput.eventHandler.clickOut = function (event) {
    if (Object(EventEmitter["d" /* hitElement */])(this.share.$picker, event)) return;
    this._releasePicker();
};


TimeInput.eventHandler.pickerChange = function (event) {
    this._applyValue(event.hour, event.minute);
    this._notifyIfChange(event);
};


/***
 *
 * @param {KeyboardEvent} event
 */
TimeInput.eventHandler.keydown = function (event) {
    var token = this._tokenAt(this.$text.selectionStart);
    var endToken = this._tokenAt(this.$text.selectionEnd);
    if (!token) {
        if (event.key === 'Enter') {
            this._correctingInput();
            this._loadValueFromInput();
            this._notifyIfChange(event);
        }
        return;
    }
    var newTokenText;
    var value;
    if (event.key.startsWith('Arrow')) {
        event.preventDefault();

        switch (event.key) {
            case 'ArrowLeft':
                this._editPrevToken();
                break;
            case 'ArrowRight':
                this._editNextToken();
                break;
            case 'ArrowUp':
            case 'ArrowDown':
                switch (token.ident) {
                    case "H":
                    case "HH":
                        value = parseInt(token.text);
                        if (isNaN(value)) {
                            this._editingData.H = event.key === 'ArrowUp' ? 0 : 23;
                        }
                        else {
                            this._editingData.H = (value + (event.key === 'ArrowUp' ? 1 : 23)) % 24;
                        }

                        newTokenText = Object(utils["zeroPadding"])(this._editingData.H, token.ident.length);
                        token.replace(newTokenText, true);
                        break;
                    case "hh":
                    case 'h':
                        value = parseInt(token.text);
                        if (isNaN(value)) {
                            this._editingData.h = event.key === 'ArrowUp' ? 1 : 12;
                        }
                        else {
                            this._editingData.h = 1 + (value + (event.key === 'ArrowUp' ? 0 : 10)) % 12;
                        }
                        newTokenText = this._editingData.h + '';
                        while (newTokenText.length < token.ident.length) newTokenText = '0' + newTokenText;
                        token.replace(newTokenText, true);
                        break;
                    case "mm":
                    case 'm':
                        value = parseInt(token.text);
                        if (isNaN(value)) {
                            this._editingData.m = event.key === 'ArrowUp' ? 0 : 59;
                        }
                        else {
                            this._editingData.m = (value + (event.key === 'ArrowUp' ? 1 : 59)) % 60;
                        }
                        newTokenText = this._editingData.m + '';
                        while (newTokenText.length < token.ident.length) newTokenText = '0' + newTokenText;
                        token.replace(newTokenText, true);
                        break;
                    case 'a':
                        value = token.text;
                        this._editingData.a = value === 'PM' ? "AM" : "PM";
                        newTokenText = this._editingData.a;
                        token.replace(newTokenText, true);
                        break;
                }
                break;
        }
    }
    else if (event.key === "Delete" || event.key === 'Backspace') {
        event.preventDefault();
        if (endToken.idx !== token.idx) {
            if (this.notNull) {
                this.$text.value = Object(datetime["formatDateTime"])(Object(datetime["beginOfDay"])(new Date()), this.format);
            }
            else {
                this.$text.value = this._format;
            }
            this.$text.select();
        }
        else {
            if (this.notNull) {
                token.replace(token.ident === 'a' ? 'AM' : Object(utils["zeroPadding"])((token.ident === 'hh' || token.ident === 'h') ? 12 : 0, token.ident.length), true);
            }
            else {
                token.replace(token.ident, true);
            }

            if (event.key === "Delete") this._editNextToken();
            else this._editPrevToken();
        }
    }
    else if (event.key === "Enter" || event.key === 'Tab') {
        this._correctingInput();
        this._loadValueFromInput();
        this._notifyIfChange(event);
    }
    else if (event.ctrlKey) {
        switch (event.key) {
            case 'a':
            case 'A':
                break;
            case 'c':
            case 'C':
                break;
            case 'x':
            case 'X':
                this.domSignal.once('clear_value', function () {
                    this.$text.value = this._format;
                    this.$text.select();
                }.bind(this));
                this.domSignal.emit('clear_value');
                break;
            default:
                event.preventDefault();
        }
    }
    else if (event.key.match(/^[0-9]$/g)) {
        event.preventDefault();
        var dVal = parseInt(event.key);
        if (this._editingData.state === TimeInput_STATE_NEW) {
            switch (token.ident) {
                case 'm':
                case 'mm':
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editingData.state = TimeInput_STATE_EDITED;
                    if (dVal > 5) {
                        this._editNextToken();
                    }
                    break;
                case 'h':
                case 'hh':
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editingData.state = TimeInput_STATE_EDITED;
                    if (dVal > 1) {
                        this._editNextToken();
                    }
                    break;
                case 'H':
                case 'HH':
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editingData.state = TimeInput_STATE_EDITED;
                    if (dVal > 2) {
                        this._editNextToken();
                    }
                    break;

            }
        }
        else {
            switch (token.ident) {
                case 'm':
                case 'mm':
                    dVal = (parseInt(token.text.split('').pop()) || 0) * 10 + dVal;
                    dVal = Math.max(0, Math.min(59, dVal));
                    this._editingData.m = dVal;
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editNextToken();
                    break;
                case 'h':
                case 'hh':
                    dVal = (parseInt(token.text.split('').pop()) || 0) * 10 + dVal;
                    dVal = Math.max(1, Math.min(12, dVal));
                    this._editingData.h = dVal;
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editNextToken();
                    break;
                case 'H':
                case 'HH':
                    dVal = (parseInt(token.text.split('').pop()) || 0) * 10 + dVal;
                    dVal = Math.max(0, Math.min(23, dVal));
                    this._editingData.H = dVal;
                    token.replace(Object(utils["zeroPadding"])(dVal, token.ident.length), true);
                    this._editNextToken();
                    break;
            }
        }
    }
    else if (event.key.match(/^[aApPSCsc]$/) && token.ident === 'a') {
        event.preventDefault();
        if (event.key.match(/^[aAsS]$/)) {
            token.replace('AM', true);
            this._editingData.a = "AM";
        }
        else {
            token.replace('PM', true);
            this._editingData.a = "PM";
        }
        this._editNextToken();
    }
    else {
        event.preventDefault();
    }
};

TimeInput.prototype.share = {
    $picker: null,
    $holdingInput: null,
    $follower: null
};


TimeInput.prototype._preparePicker = function () {
    if (this.share.$picker) return;
    this.share.$picker = TimeInput_({
        tag: js_ChromeTimePicker.tag,
        class: 'as-time-input-picker'
    });
    this.share.$follower = TimeInput_({
        tag: 'follower',
        class: 'as-time-input-follower',
        child: this.share.$picker
    });
};


TimeInput.prototype._attachPicker = function () {
    this._preparePicker();
    if (this.share.$holdingInput) this.share.$holdingInput._releasePicker();
    this.share.$holdingInput = this;
    this.share.$follower.addTo(document.body);
    this.share.$follower.followTarget = this;
    this.share.$follower.addStyle('visibility', 'hidden');
    this.share.$picker.hour = this.hour || 0;
    this.share.$picker.minute = this.minute || 0;
    this.share.$picker.s24 = this.s24;
    this.share.$picker.domSignal.emit('request_scroll_into_selected')
    this.$clockBtn.off('click', this.eventHandler.clickClockBtn);
    this.share.$picker.on('change', this.eventHandler.pickerChange);
    setTimeout(function () {
        document.body.addEventListener('click', this.eventHandler.clickOut);
        this.share.$follower.removeStyle('visibility');
    }.bind(this), 5);

};

TimeInput.prototype._releasePicker = function () {
    if (this.share.$holdingInput !== this) return;
    // this.share.$calendar.off('pick', this.eventHandler.calendarPick);
    this.share.$follower.remove();
    document.body.removeEventListener('click', this.eventHandler.clickOut);
    this.share.$picker.off('change', this.eventHandler.pickerChange);

    setTimeout(function () {
        this.$clockBtn.on('click', this.eventHandler.clickClockBtn);
    }.bind(this), 5)
    this.share.$holdingInput = null;
};


ACore["d" /* default */].install(TimeInput);

/* harmony default export */ var js_TimeInput = (TimeInput);



// EXTERNAL MODULE: ./node_modules/absol-acomp/css/timepicker.css
var timepicker = __webpack_require__(226);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TimePicker.js








//todo: add this to absol
var isTouchDevice = BrowserDetector["a" /* default */].hasTouch && !BrowserDetector["a" /* default */].os.type.match(/windows|X11|Ubuntu|Linux/);
//todo: re select text after click
var TimePicker_ = ACore["d" /* default */]._;
var TimePicker_$ = ACore["d" /* default */].$;

var TimePicker_$g = Svg["a" /* default */].ShareInstance.$;
var TimePicker_g = Svg["a" /* default */].ShareInstance._;

function TimePicker() {
    this._hour = 0;
    this._minute = 0;
    this._lastDayOffset = 0;
    this._state = 'none';
    this._mode = 'CLOCK';
    this._latBound = { width: 0, height: 0 };
    var thisPicker = this;
    if (isTouchDevice)
        this.addClass('ac-time-picker-touch');
    this.$attachook = TimePicker_('attachhook').addTo(this).on('error', function () {
        Dom["b" /* default */].addToResizeSystem(this);
        this.requestUpdateSize();
        thisPicker.addStyle('font-size', thisPicker.getComputedStyleValue('font-size'));
    });
    this.$attachook.requestUpdateSize = this.updateSize.bind(this);
    /***
     *
     * @type {NumberSpanInput}
     */
    this.$hour = TimePicker_$('.ac-time-picker-hour', this)
        .on({
            focus: this.eventHandler.focusHour,
            keydown: this.eventHandler.keydownHour,
            blur: this.eventHandler.blurHour
        });
    /***
     *
     * @type {NumberSpanInput}
     */
    this.$minute = TimePicker_$('.ac-time-picker-minute', this)
        .on({
            keydown: this.eventHandler.keydownMinute,
            focus: this.eventHandler.focusMinute,
            blur: this.eventHandler.blurMinute,
        });

    this.$hourInput = TimePicker_$('.ac-time-picker-hour-input', this)
        .on({
            click: this.eventHandler.clickHourInput,
            keydown: this.eventHandler.keydownHourInput,
            blur: this.eventHandler.blurHourInput
        });

    this.$minuteInput = TimePicker_$('.ac-time-picker-minute-input', this)
        .on({
            click: this.eventHandler.clickMinuteInput,
            keydown: this.eventHandler.keydownMinuteInput,
            blur: this.eventHandler.blurMinuteInput
        });

    //only support if is none touch device
    if (isTouchDevice) {
        this.$hour.readOnly = true;
        this.$hour.on('click', this._editHourState.bind(this));
        this.$minute.readOnly = true;
        this.$minute.on('click', this._editMinuteState.bind(this));
    }

    this.$clock = TimePicker_$g('.ac-time-picker-clock', this)
        .on(isTouchDevice ? 'touchstart' : 'mousedown', this.eventHandler.mousedownClock
        );

    this._clockWidth = 400;
    this._clockHeight = 400;
    this._clockRadius = 150;
    this._clockRadiusInner = 100;
    this.$clockContent = TimePicker_$g('.ac-time-picker-clock-content', this);
    this.$clockHourCtn = TimePicker_$g('.ac-time-picker-clock-hour-ctn', this);
    this.$clockMinuteCtn = TimePicker_$g('.ac-time-picker-clock-minute-ctn', this);

    this.$hourNumbers = Array(24).fill(0).map(function (u, i) {
        var h = i;
        if (h == 0)
            h = 12;
        else if (h == 12) h = '00';
        return TimePicker_g({
            tag: 'text',
            attr: {
                'text-anchor': 'middle'
            },
            class: 'ac-time-picker-clock-hour-' + (i < 12 ? 'am' : 'pm'),
            child: { text: h + '' }
        }).addTo(thisPicker.$clockHourCtn);
    });
    this.$minuteNumbers = Array(12).fill(0).map(function (u, i) {
        return TimePicker_g({
            tag: 'text',
            attr: {
                'text-anchor': 'middle'
            },
            class: 'ac-time-picker-clock-minute',
            child: { text: i * 5 + '' }
        }).addTo(thisPicker.$clockMinuteCtn);
    });

    this.$selectCtn = TimePicker_$g('.ac-time-picker-clock-select-ctn', this);
    this.$clockCenter = TimePicker_g({
        tag: 'circle',
        class: 'ac-time-picker-clock-center',
        attr: {
            cx: "0",
            cy: '0'
        }
    }).addTo(this.$selectCtn);
    this.$clockSelectLine = TimePicker_g({
        tag: 'path',
        class: 'ac-time-picker-clock-select-line'
    }).addTo(this.$selectCtn);
    this.$clockSelectCicle = TimePicker_g({
        tag: 'circle',
        class: 'ac-time-picker-clock-select-circle',
        attr: {
            cx: 0,
            cy: 0
        }
    }).addTo(this.$selectCtn);

    this.$clockSelectCenter = TimePicker_g({
        tag: 'circle',
        class: 'ac-time-picker-clock-select-center'
    }).addTo(this.$selectCtn);
    this.$finishBtn = TimePicker_$('.ac-time-picker-finish-btn', this)
        .on('click', this.finishSelect.bind(this));
    this.$cancelBtn = TimePicker_$('.ac-time-picker-cancel-btn', this)
        .on('click', this.cancelSelect.bind(this));
    this.$keyboardBtn = TimePicker_$('.ac-time-picker-keyboard-btn', this)
        .on('click', this.timeMode.bind(this));
    this.$clockBtn = TimePicker_$('.ac-time-picker-clock-btn', this)
        .on('click', this.clockMode.bind(this));
};


TimePicker.prototype.updateSize = function () {
    // var 
    this._fontSize = this.getFontSize();
    var cBound = this.$clock.getBoundingClientRect();
    this._clockWidth = cBound.width;
    this._clockHeight = cBound.height;
    this.$clock.attr({
        width: this._clockWidth,
        height: this._clockHeight,
        viewBox: '0 0 ' + this._clockWidth + ' ' + this._clockHeight
    });

    this.$clockContent.attr('transform', 'translate(' + (this._clockWidth / 2) + ',' + (this._clockHeight / 2) + ')');
    var clockRadius = this._clockWidth / 2 - this._fontSize;
    var clockRadiusInner = clockRadius - this._fontSize * 1.5;
    this._clockRadius = clockRadius;
    this._clockRadiusInner = clockRadiusInner;
    this.$clockCenter.attr('r', this._fontSize / 5);
    this.$clockSelectCicle.attr({ r: this._fontSize * 0.7, cx: clockRadius });
    this.$clockSelectCenter.attr({ r: this._fontSize / 10, cx: clockRadius });
    this.$hourNumbers.forEach(function (elt, i) {
        var angle = Math.PI * (i - 3) / 6;
        var r = i < 12 ? clockRadius : clockRadiusInner;
        var box = elt.getBBox();
        var x = r * Math.cos(angle);
        var y = r * Math.sin(angle) + box.height / 2;
        elt.attr({
            x: x,
            y: y
        });
    });
    this.$minuteNumbers.forEach(function (elt, i) {
        var angle = Math.PI * (i - 3) / 6;
        var box = elt.getBBox();
        var x = clockRadius * Math.cos(angle);
        var y = clockRadius * Math.sin(angle) + box.height / 3;
        elt.attr({
            x: x,
            y: y
        });
    });
    this.updateSelectPosition();
    this.notifySizeChange();
};


TimePicker.prototype.updateSelectPosition = function () {
    var angle, radius;
    if (this._state == "EDIT_MINUTE") {
        angle = Math.PI * (this._minute - 15) / 30;
        radius = this._clockRadius
    }
    else if (this._state == "EDIT_HOUR") {
        angle = Math.PI * (this._hour - 3) / 6;
        if (this._hour > 0 && this._hour <= 12) {
            radius = this._clockRadius;
        }
        else {
            radius = this._clockRadiusInner;
        }
    }
    else {
        return;
    }
    this._drawSelect(radius, angle);
};

TimePicker.prototype.editHour = function () {
    this.clockMode();
    if (this.$hour.readOnly) {
        this._editHourState();
    }
    else {
        this.$hour.focus();
    }
}


TimePicker.prototype._drawSelect = function (radius, angle) {
    var x = radius * Math.cos(angle);
    var y = radius * Math.sin(angle);
    this.$clockSelectCicle.attr({
        cx: x, cy: y
    });
    this.$clockSelectCenter.attr({
        cx: x, cy: y
    });
    this.$clockSelectLine.attr('d', 'M0,0L' + x + ',' + y);
};


TimePicker.prototype.notifyChange = function (force) {
    if (this._lastDayOffset != this.dayOffset || force) {
        this.emit('change', {
            target: this,
            hour: this.hour,
            minute: this.minute,
            dayOffset: this.dayOffset,
            name: 'change'
        }, this);
        this._lastDayOffset = this.dayOffset;
    }
};


TimePicker.prototype.notifySizeChange = function () {
    var bound = this.getBoundingClientRect();
    if (this._latBound.width != bound.width || this._latBound.height != bound.height) {
        this._latBound.width = bound.width;
        this._latBound.height = bound.height;
        this.emit('sizechange', { name: 'sizechange', bound: bound, target: this }, this);
    }
};

TimePicker.tag = 'TimePicker';

TimePicker.render = function () {
    return TimePicker_({
        extendEvent: ['change', 'finish', 'cancel', 'sizechange'],
        class: ['ac-time-picker', 'ac-time-picker-clock-mode'],//clock mode is default
        child: [
            {
                class: 'ac-time-picker-set-clock',
                child: [{
                    class: 'ac-time-picker-set-clock-header',
                    child: [
                        {
                            tag: 'numberspaninput',
                            class: 'ac-time-picker-hour',
                            props: {
                                value: 0,
                                zeroInt: 2
                            }
                        },
                        {
                            tag: 'span',
                            text: ':'
                        },
                        {
                            tag: 'numberspaninput',
                            class: 'ac-time-picker-minute',
                            props: {
                                value: 0,
                                zeroInt: 2
                            }
                        }
                    ]
                },
                    TimePicker_g(
                        {
                            tag: 'svg',
                            class: 'ac-time-picker-clock',
                            child: [
                                {
                                    class: 'ac-time-picker-clock-content',
                                    child: ['.ac-time-picker-clock-select-ctn', '.ac-time-picker-clock-hour-ctn', '.ac-time-picker-clock-minute-ctn']
                                }
                            ]
                        }
                    )]
            },
            {
                class: 'ac-time-picker-set-time',
                child: [
                    {
                        class: 'ac-time-picker-set-time-header',
                        child: { text: 'Set time' }
                    },
                    {
                        class: 'ac-time-picker-set-time-label',
                        child: { text: 'Type in time' }
                    },
                    {
                        class: 'ac-time-picker-set-time-input-group',
                        child: [
                            {
                                class: 'ac-time-picker-set-time-input-hm',
                                child: [
                                    {
                                        tag: 'input',
                                        class: 'ac-time-picker-hour-input',
                                        attr: {
                                            type: 'number',
                                            placeHolder: '00',
                                            tabindex: '2',
                                        }
                                    },
                                    {
                                        tag: 'span',
                                        child: { text: ':' }
                                    },
                                    {
                                        tag: 'input',
                                        class: 'ac-time-picker-minute-input',
                                        attr: {
                                            type: 'number',
                                            placeHolder: '00',
                                            tabindex: '3'
                                        }
                                    }
                                ]
                            },
                            {
                                class: 'ac-time-picker-set-time-input-label-hm',
                                child: [
                                    { tag: 'span', child: { text: 'hour' } },
                                    { tag: 'span', style: { visibility: 'hidden' }, child: { text: ':' } },
                                    { tag: 'span', child: { text: 'minute' } }

                                ]
                            }
                        ]
                    }
                ]
            },
            {
                class: 'ac-time-picker-footer',
                child: [
                    {
                        tag: 'button',
                        class: 'ac-time-picker-keyboard-btn',
                        child: 'span.mdi.mdi-keyboard-outline'
                    },
                    {
                        tag: 'button',
                        class: 'ac-time-picker-clock-btn',
                        child: 'span.mdi.mdi-clock-outline'
                    },
                    {
                        class: 'ac-time-picker-footer-right',
                        child: [
                            {
                                tag: 'button',
                                class: 'ac-time-picker-cancel-btn',
                                attr: { tabindex: '4' },
                                child: { text: 'CANCEL' }
                            },
                            {
                                tag: 'button',
                                attr: { tabindex: '4' },
                                class: 'ac-time-picker-finish-btn',
                                child: { text: 'OK' }
                            }

                        ]
                    }]
            }
        ]
    });
};


TimePicker.prototype.clockMode = function () {
    if (this._mode == "CLOCK") return;
    this._mode = 'CLOCK';
    this.removeClass('ac-time-picker-time-mode')
        .addClass('ac-time-picker-clock-mode');
    this.$hour.value = this._hour < 10 ? '0' + this._hour : this._hour;
    this.$minute.value = this._minute < 10 ? '0' + this._minute : this._minute;
    this._editHourState();
    this.updateSize();
    this._showSelectHour(this._hour);
};


TimePicker.prototype.timeMode = function () {
    if (this._mode == "TIME") return;
    this._mode = 'TIME';
    this.addClass('ac-time-picker-time-mode')
        .removeClass('ac-time-picker-clock-mode');
    this.$hourInput.value = this._hour < 10 ? '0' + this._hour : this._hour;
    this.$minuteInput.value = this._minute < 10 ? '0' + this._minute : this._minute;
    this.editHourInput();
    this.updateSize();
};


TimePicker.prototype._editHourState = function () {
    this._state = "EDIT_HOUR";
    this._preHour = this._hour;
    this.removeClass('ac-time-picker-edit-minute')
        .addClass('ac-time-picker-edit-hour')
        .removeClass('ac-time-picker-edit-hour-input')
        .removeClass('ac-time-picker-edit-minute-input');
    this.updateSize();
};


TimePicker.prototype._editMinuteState = function () {
    this._state = "EDIT_MINUTE";
    this._preMinute = this._minute;
    this.addClass('ac-time-picker-edit-minute')
        .removeClass('ac-time-picker-edit-hour')
        .removeClass('ac-time-picker-edit-hour-input')
        .removeClass('ac-time-picker-edit-minute-input');
    this.updateSize();
};


TimePicker.prototype.editHourInput = function () {
    var thisPicker = this;
    this._state = "EDIT_HOUR_INPUT";
    this._preHour = this._hour;
    this.removeClass('ac-time-picker-edit-minute')
        .removeClass('ac-time-picker-edit-hour')
        .addClass('ac-time-picker-edit-hour-input')
        .removeClass('ac-time-picker-edit-minute-input');
    this.updateSize();
    setTimeout(function () {
        thisPicker.$hourInput.focus();
        thisPicker.$hourInput.select();
    }, 10);
};


TimePicker.prototype.editMinuteInput = function () {
    var thisPicker = this;
    this._state = "EDIT_MINUTE_INPUT";
    this._preMinute = this._minute;
    this.removeClass('ac-time-picker-edit-minute')
        .removeClass('ac-time-picker-edit-hour')
        .removeClass('ac-time-picker-edit-hour-input')
        .addClass('ac-time-picker-edit-minute-input');
    this.updateSize();
    setTimeout(function () {
        thisPicker.$minuteInput.focus();
        thisPicker.$minuteInput.select();
    }, 1)
};


TimePicker.prototype.finishSelect = function () {
    this.emit('finish', {
        target: this,
        hour: this.hour,
        minute: this.minute,
        dayOffset: this.dayOffset,
        name: 'finish'
    }, this);
};


TimePicker.prototype.cancelSelect = function () {
    this.emit('cancel', { target: this, name: 'cancel' }, this);
};


TimePicker.eventHandler = {};

TimePicker.eventHandler.focusHour = function () {
    this._editHourState();
    this.$hour.selectAll();
};


TimePicker.eventHandler.blurHour = function () {
    var newText = this.$hour.value;
    var hour = parseFloat(newText) || 0;
    if (hour < 0 || hour >= 24)
        hour = this._preHour;
    this.$hour.value = hour < 10 ? '0' + hour : hour;
    this._hour = hour;
    this._showSelectHour(hour);
    this.notifyChange();
};


TimePicker.eventHandler.focusMinute = function () {
    this._editMinuteState();
    this.$minute.selectAll();
};


TimePicker.eventHandler.blurMinute = function () {
    var newText = this.$minute.innerHTML;
    var minute = parseFloat(newText) || 0;
    if (minute < 0 || minute >= 60)
        minute = this._preMinute;
    this.$minute.value = minute < 10 ? '0' + minute : minute;
    this._minute = minute;
    this._showSelectByMinuteText();
    this.notifyChange();
};


TimePicker.eventHandler.clickHourInput = function () {
    if (this._state != 'EDIT_HOUR') this.editHourInput();
    else {
        this.$hourInput.focus();
        this.$hourInput.select();
    }
};


TimePicker.eventHandler.clickMinuteInput = function () {
    if (this._state != 'EDIT_MINUTE_INPUT') this.editMinuteInput();
    else {
        this.$minuteInput.focus();
        this.$minuteInput.select();

    }
};

TimePicker.eventHandler.blurHourInput = function () {
    var hour = parseFloat(this.$hourInput.value) || 0;
    if (hour < 0 || hour >= 24)
        hour = this._preHour;
    this.hour = hour;
};

TimePicker.eventHandler.blurMinuteInput = function () {
    var minute = parseFloat(this.$minuteInput.value) || 0;
    if (minute < 0 || minute >= 60)
        minute = this._preMinute;
    this.minute = minute;
};


TimePicker.property = {};


TimePicker.property.hour = {
    set: function (value) {
        value = (value % 24) || 0;
        this._hour = value;
        var text = (value < 10 ? '0' : '') + value + '';
        this.$hour.clearChild().addChild(TimePicker_({ text: text }));
        this.$hourInput.value = text;
        this.updateSelectPosition();
    },
    get: function () {
        return this._hour;
    }
};


TimePicker.property.minute = {
    set: function (value) {
        value = (value % 60) || 0;
        this._minute = value;
        var text = (value < 10 ? '0' : '') + value + '';
        this.$minute.value = text;
        this.$minuteInput.value = text;
        this.updateSelectPosition();
    },
    get: function () {
        return this._minute;
    }
};


TimePicker.property.dayOffset = {
    set: function (value) {
        value = value || 0;
        if (value.getTime)
            value = value.getTime() - Object(datetime["beginOfDay"])(value).getTime();
        else {
            value = value % datetime["MILLIS_PER_DAY"];
        }

        this.hour = Math.floor(value / datetime["MILLIS_PER_HOUR"]);
        this.minute = Math.floor((value % datetime["MILLIS_PER_HOUR"]) / datetime["MILLIS_PER_MINUTE"]);
    },
    get: function () {
        return this._hour * datetime["MILLIS_PER_HOUR"] + this._minute * datetime["MILLIS_PER_MINUTE"];
    }
};

TimePicker.prototype._showSelectHour = function (hour) {
    var radius;
    var angle = Math.PI * (hour - 3) / 6;
    if ((hour < 24 && hour > 12) || hour == 0) {
        radius = this._clockRadiusInner;
    }
    else if (hour <= 12) {
        radius = this._clockRadius;
    }
    else {
        return;
    }
    this._drawSelect(radius, angle);
};

TimePicker.prototype._showSelectByHourText = function () {
    var hour = parseFloat(this.$hour.innerHTML) || 0;
    if (hour < 0 || hour >= 24) return;
    this._showSelectHour(hour);
};


TimePicker.prototype._showSelectMinute = function (minute) {
    var angle = Math.PI * (minute - 15) / 30;
    this._drawSelect(this._clockRadius, angle);
}

TimePicker.prototype._showSelectByMinuteText = function () {
    var minute = parseFloat(this.$minute.innerHTML) || 0;
    if (minute < 0 || minute >= 60) return;
    this._showSelectMinute(minute);
};

/***
 *
 * @param {KeyboardEvent} event
 */
TimePicker.eventHandler.keydownHour = function (event) {
    var thisPicker = this;
    if (event.key == 'Enter' || event.key == 'Tab') {
        event.preventDefault();
        this.$hour.blur();
        this._editMinuteState();
        setTimeout(function () {
            thisPicker.$minute.focus();
            thisPicker.$minute.selectAll();
        }, 30);
    }
    else {
        setTimeout(function () {
            var newText = thisPicker.$hour.value;
            var hour = parseFloat(newText) || 0;
            if (hour < 0 || hour >= 24)
                hour = thisPicker._preHour;
            else {
                thisPicker._hour = hour;
                thisPicker._showSelectHour(hour);
            }
        }, 30);
    }
};


TimePicker.eventHandler.keydownMinute = function (event) {
    var thisPicker = this;
    if (event.key == 'Enter') {
        this.$minute.blur();
        event.preventDefault();
        setTimeout(this.finishSelect.bind(this), 30);
    }
    else if (event.key == 'Tab') {
        this.$minute.selectNone();
        this.$finishBtn.focus();
        event.preventDefault();
    }
    else {
        setTimeout(function () {
            var newText = thisPicker.$minute.value;
            var minute = parseFloat(newText) || 0;
            if (minute < 0 || minute >= 60)
                minute = thisPicker._preMinute;
            else {
                thisPicker._minute = minute;
                thisPicker._showSelectMinute(minute);
            }
        }, 30);
    }
};


TimePicker.eventHandler.keydownHourInput = function (event) {
    var thisPicker = this;
    if ((isTouchDevice && event.key == "Unidentified") || (event.key && event.key.length == 1 && !event.ctrlKey && !event.altKey)) {
        if (event.key.match(/[0-9]/)) {
            setTimeout(this.notifyChange.bind(this), 2);
        }
        else {
            event.preventDefault();
        }
    }
    else if (event.key == 'Enter') {
        event.preventDefault();
        this.$hourInput.blur();
        this.editMinuteInput();
    }
    else if (!event.key && !event.key.toLowerCase().match(/arrow|back/)) {
        var cText = this.$hourInput.value;
        setTimeout(function () {
            var newText = thisPicker.$hourInput.value;
            if (cText != newText) {
                var hour = parseFloat(newText) || 0;
                if (hour < 0 || hour >= 24)
                    hour = thisPicker._preHour;
                thisPicker.hour = hour;
                thisPicker.$hourInput.blur();
                thisPicker.editMinuteInput();
                thisPicker.notifyChange();
            }
        }, 1);
    }
};


TimePicker.eventHandler.keydownMinuteInput = function (event) {
    var thisPicker = this;
    if ((isTouchDevice && event.key == "Unidentified") || event.key.length == 1 && !event.ctrlKey && !event.altKey) {
        if ((isTouchDevice && event.key == "Unidentified") || event.key.match(/[0-9]/)) {
            setTimeout(this.notifyChange.bind(this), 2);

        }
        else {
            event.preventDefault();
        }
    }
    else if (event.key == 'Enter') {
        this.$minute.blur();
        this.eventHandler.blurMinuteInput();
        event.preventDefault();

        setTimeout(this.finishSelect.bind(this), 100);
    }
    else if (event.key == "Backspace") {

    }
    else if (event.key != 'Enter') {
        var cText = this.$minuteInput.value;
        setTimeout(function () {
            var newText = thisPicker.$minuteInput.value;
            if (cText != newText) {
                var minute = parseFloat(newText) || 0;
                if (minute < 0 || minute >= 60)
                    minute = thisPicker._preMinute;
                thisPicker.minute = minute;
                thisPicker.$minuteInput.focus();
                thisPicker.$minuteInput.select();
                thisPicker.notifyChange();
            }
        }, 1);
    }
};


TimePicker.eventHandler.dragOnClock = function (event) {
    event = (event.changedTouches && event.changedTouches[0]) || event;
    var cBound = this.$clock.getBoundingClientRect();
    var cx = (cBound.left + cBound.right) / 2;
    var cy = (cBound.top + cBound.bottom) / 2;
    var x = event.clientX - cx;
    var y = event.clientY - cy;
    var angle = Math.atan2(y, x);
    var radius = Math.sqrt(x * x + y * y);

    var index;
    if (this._state == "EDIT_HOUR") {
        angle += Math.PI * 2;
        index = Math.round(angle / (Math.PI / 6));
        var hour = (index + (12 + 3)) % 12;
        if (radius < (this._clockRadiusInner + this._clockRadius) / 2) {
            if (hour != 0) hour += 12;
        }
        else {
            if (hour == 0) hour = 12;
        }
        this._hour = hour;
        this._showSelectHour(hour);
        this.$hour.value = hour < 10 ? '0' + hour : hour;
        this.$hour.selectEnd();
    }
    else if (this._state == "EDIT_MINUTE") {
        radius = this._clockRadius;
        angle += Math.PI * 2;
        index = Math.round(angle / (Math.PI / 30));
        angle = index * (Math.PI / 30);
        var minute = (index + (60 + 15)) % 60;
        this._minute = minute;
        this.$minute.value = minute < 10 ? '0' + minute : minute;
        this._showSelectMinute(minute);
        this.$minute.selectEnd();
        this.notifyChange();
    }
    else {
        return;
    }
};


TimePicker.eventHandler.mousedownClock = function (event) {
    event.preventDefault();
    this.eventHandler.dragOnClock(event);
    document.body.addEventListener(isTouchDevice ? 'touchmove' : 'mousemove', this.eventHandler.mousemoveClock);
    document.body.addEventListener(isTouchDevice ? 'touchend' : 'mouseup', this.eventHandler.mousefinishClock);
    if (!isTouchDevice)
        document.body.addEventListener('mouseleave', this.eventHandler.mousefinishClock);
};


TimePicker.eventHandler.mousemoveClock = function (event) {
    event.preventDefault();
    this.eventHandler.dragOnClock(event);
};


TimePicker.eventHandler.mousefinishClock = function () {
    document.body.removeEventListener('mousemove', this.eventHandler.mousemoveClock);
    document.body.removeEventListener('mouseup', this.eventHandler.mousefinishClock);
    document.body.removeEventListener('mouseleave', this.eventHandler.mousefinishClock);
    if (this._state == 'EDIT_HOUR') {
        if (this.$minute.readOnly) {
            this._editMinuteState();
        }
        else {
            this.$minute.focus();
        }
    }
    else if (this._state == 'EDIT_MINUTE') {
        this.$minute.selectAll();// refocus
    }
};


ACore["d" /* default */].install('timepicker', TimePicker);
/* harmony default export */ var js_TimePicker = (TimePicker);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Tooltip.js
var Tooltip = __webpack_require__(28);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/treelist.css
var treelist = __webpack_require__(96);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TreeListItem.js




var TreeListItem_ = ACore["d" /* default */]._;
var TreeListItem_$ = ACore["d" /* default */].$;

function TreeListItem() {
    var thisTI = this;
    this.$list = TreeListItem_$('treelist', this).on('press', function (event, sender) {
        thisTI.emit('press', event, this);
    });

    this.$parent = TreeListItem_$('.absol-tree-list-item-parent', this).on('mousedown', this.eventHandler.clickParent);
    this.$text = TreeListItem_$('span.absol-tree-list-item-text', this);
    this.$desc = TreeListItem_$('span.absol-tree-list-item-desc', this);
    this.$descCtn = TreeListItem_$('.absol-tree-list-item-desc-container', this);
    this.$list.level = 1;
    OOP["a" /* default */].drillProperty(this, this.$list, 'items');
}

TreeListItem.tag = 'TreeListItem'.toLowerCase();
TreeListItem.render = function () {
    return TreeListItem_({
        extendEvent: ['press', 'clickparent'],
        class: 'absol-tree-list-item',
        child: [
            {
                class: 'absol-tree-list-item-parent',
                child: ['span.absol-tree-list-item-text',
                    {
                        class: 'absol-tree-list-item-desc-container',
                        child: 'span.absol-tree-list-item-desc'
                    }
                ]
            },
            'treelist'
        ]
    });
};


TreeListItem.eventHandler = {};
TreeListItem.eventHandler.clickParent = function (event) {
    event.preventDefault();
    var prevented = false;
    var self = this;
    this.emit('press', {
        target: self,
        preventDefault: function () {
            prevented = true;
        },
        isPrevented: function () {
            return prevented;
        },
        data: this.data
    }, this);
    if (!prevented) {
        var top = self.getTopLevelElt();
        TreeListItem_$('treelistitem', top, function (e) {
            if (e != self)
                e.active = false;
        })
        self.active = true;
    }
};

TreeListItem.prototype.getTopLevelElt = function () {
    var current = this;
    while (current) {
        var parent = current.parentNode;
        if (!parent || (!parent.classList.contains('absol-tree-list') && !parent.classList.contains('absol-tree-list-item'))) break;
        current = current.parentNode;
    }
    return current;
};


TreeListItem.property = {
    text: {
        set: function (value) {
            value = value + '';
            this.$text.innerHTML = value;
        },
        get: function () {
            return this.$text.innerHTML;
        }
    },
    desc: {
        set: function (value) {
            value = value + '';
            this.$desc.innerHTML = value;
        },
        get: function () {
            return this.$desc.innerHTML
        }
    },
    level: {
        set: function (value) {
            value = value || 0;
            if (value == this.level) return;
            this._level = value;
            this.$parent.addStyle('padding-left', this._level * 0.4 * 3 + 'em');
            this.$list.level = value + 1;
        },
        get: function () {
            return this._level || 0;
        }
    },
    active: {
        set: function (value) {
            if (value) {
                this.addClass('active');
            }
            else {
                this.removeClass('active');
            }
        },
        get: function () {
            return this.containsClass('active');
        }
    },
    data: {
        set: function (value) {
            this._data = value;
        },
        get: function () {
            return this._data;
        }
    },
    value: {
        get: function () {
            var data = this.data;
            if (typeof data == 'string') return data;
            if (typeof data.value == "undefined") {
                return data.text;
            }
            else {
                return data.value;
            }
        }
    }
};


TreeListItem.property.extendClasses = {
    set: function (value) {
        var self = this;
        this.extendClasses.forEach(function (className) {
            self.$parent.removeClass(className);
        });
        this._extendClass = [];
        if (!value) return;
        if (typeof value == 'string') {
            value = value.split(/\s+/).filter(function (c) {
                return c.length > 0
            });
        }

        if (value instanceof Array) {
            this._extendClass = value;
            this._extendClass.forEach(function (className) {
                self.$parent.addClass(className);
            });
        }
        else {
            throw new Error('Invalid extendClasses');
        }
    },
    get: function () {
        return this._extendClass || [];
    }
};


TreeListItem.property.extendStyle = {
    set: function (value) {
        this.$parent.removeStyle(this._extendStyle || {});
        this._extendStyle = value || {};
        this.$parent.addStyle(this.extendStyle);
    },
    get: function () {
        return this._extendStyle || {};
    }
};


ACore["d" /* default */].install(TreeListItem);

/* harmony default export */ var js_TreeListItem = (TreeListItem);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TreeList.js



var TreeList_ = ACore["d" /* default */]._;
var TreeList_$ = ACore["d" /* default */].$;

function TreeList() {
}

TreeList.tag = 'treelist';
TreeList.render = function () {
    return TreeList_({
        class: 'absol-tree-list',
        extendEvent: 'press'
    });
};


TreeList.prototype.realignDescription = function (extMarginLeft) {
    extMarginLeft = extMarginLeft || 0;
    var maxWidth = 0;
    var ctns = [];
    TreeList_$('.absol-tree-list-item-desc-container', this, function (elt) {
        ctns.push(elt);
        var bound = elt.getBoundingClientRect();
        maxWidth = Math.max(maxWidth, bound.width);
    });
    var fontSize = this.getFontSize();
    var cntWidth = maxWidth / fontSize + 'em';
    var extMarginRight = maxWidth / fontSize + extMarginLeft + 'em';
    ctns.forEach(function (e) {
        e.addStyle('width', cntWidth);
    });
    TreeList_$('span.absol-tree-list-item-text', this, function (elt) {
        elt.addStyle('margin-right', extMarginRight);
    });
    return this;
};


TreeList.prototype.clearItems = function () {
    this._items = [];
    this.clearChild();
};

TreeList.prototype.getAllItem = function () {
    return this._items || [];
};

TreeList.prototype.getAllItemElement = function () {
    return Array.apply(null, this.childNodes);
}

TreeList.prototype.addItem = function (item) {
    var self = this;
    var props = { level: this.level, data: item };

    if (typeof item == 'string') {
        props.text = item;
    }
    else {
        props.text = item.text;
        if (item.items) {
            props.items = item.items;
        }
        if (item.desc) {
            props.desc = item.desc;
        }
        if (item.extendClasses) {
            props.extendClasses = item.extendClasses;
        }
        if (item.extendStyle) {
            props.extendStyle = item.extendStyle;
        }
    }

    var elt = TreeList_({
        tag: 'treelistitem',
        props: props,
        on: {
            press: function (event) {
                self.emit('press', event, this);
            }
        }
    });
    this.addChild(elt);

    this._items.push(item);
    return this;
};


TreeList.property = {};
TreeList.property.items = {
    set: function (value) {
        this.clearItems();

        (value || []).forEach(this.addItem.bind(this));
    },
    get: function () {
        return this.getAllItem();
    }
};


TreeList.property.level = {
    set: function (value) {
        value = value || 0;
        if (this.level == value) return;
        this._level = value;
        this.getAllItemElement().forEach(function (e) {
            e.level = value;
        });
    },
    get: function () {
        return this._level || 0;
    }
};

ACore["d" /* default */].install(TreeList);

/* harmony default export */ var js_TreeList = (TreeList);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/selecttreemenu.css
var selecttreemenu = __webpack_require__(231);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/SelectMenu2.js
var SelectMenu2 = __webpack_require__(21);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/SelectListBox.js + 1 modules
var SelectListBox = __webpack_require__(19);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/list/treeListToList.js
/***
 *
 * @param {Array<SelectionItem>} items
 * @returns {Array<SelectionItem>}
 */
function treeListToList(items) {
    var arr = [];
    function visit(level, node) {
        Object.defineProperty(node, 'level', {
           configurable: true,
            writable: true,
            value: level
        });
        arr.push(node);
        if (node.items && node.items.length > 0) node.items.forEach(visit.bind(null, level + 1));
    }
    items.forEach(visit.bind(null, 0));
    return arr;
}
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/SelectTreeBox.js




var SelectTreeBox_ = ACore["d" /* default */]._;
var SelectTreeBox_$ = ACore["d" /* default */].$;
var SelectTreeBox_$$ = ACore["d" /* default */].$$;

/***
 * @extends SelectListBox
 * @constructor
 */
function SelectTreeBox() {
    SelectListBox["b" /* default */].call(this);
}

SelectTreeBox.tag = 'SelectTreeBox'.toLowerCase();

SelectTreeBox.render = function () {
    return SelectListBox["b" /* default */].render().addClass('as-select-tree-box');
};


Object.assign(SelectTreeBox.prototype, SelectListBox["b" /* default */].prototype);
SelectTreeBox.property = Object.assign({}, SelectListBox["b" /* default */].property);
SelectTreeBox.eventHandler = Object.assign({}, SelectListBox["b" /* default */].eventHandler);

SelectTreeBox.prototype._itemsToNodeList = function (items) {
    return treeListToList(items);
};



//todo
SelectTreeBox.prototype.searchItemByText = function (text) {
    text = text.trim();
    if (text.length == 0) return this._items;
    if (this._searchCache[text]) return this._searchCache[text];
    this._searchCache[text] = Object(search["e" /* searchTreeListByText */])(text, this._items);
    return this._searchCache[text];
};

ACore["d" /* default */].install(SelectTreeBox);

/* harmony default export */ var js_SelectTreeBox = (SelectTreeBox);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/SelectTreeMenu.js






var SelectTreeMenu_ = ACore["d" /* default */]._;
var SelectTreeMenu_$ = ACore["d" /* default */].$;


/***
 * @extends SelectMenu
 * @constructor
 */
function SelectTreeMenu() {
    this._items = [];
    this._value = null;
    this._lastValue = null;
    this.$holderItem = SelectTreeMenu_$('.absol-selectmenu-holder-item', this);
    this.$viewItem = SelectTreeMenu_$('.absol-selectmenu-holder-item selectlistitem', this);
    /***
     *
     * @type {SelectTreeBox}
     */
    this.$selectlistBox = SelectTreeMenu_({
        tag: 'selecttreebox',
        props: {
            anchor: [1, 6, 2, 5]
        },
        on: {
            preupdateposition: this.eventHandler.preUpdateListPosition
        }
    });
    this.$selectlistBox.on('pressitem', this.eventHandler.selectListBoxPressItem);
    this.$selectlistBox.followTarget = this;
    OOP["a" /* default */].drillProperty(this, this.$selectlistBox, 'enableSearch');

    this._lastValue = "NOTHING_VALUE";
    this._isFocus = false;
    this.isFocus = false;

    this.on('mousedown', this.eventHandler.click, true);
}

SelectTreeMenu.tag = 'SelectTreeMenu'.toLowerCase();

SelectTreeMenu.render = function () {
    return SelectMenu2["a" /* default */].render().addClass('as-select-tree-menu');
};

SelectTreeMenu.eventHandler = Object.assign({}, SelectMenu2["a" /* default */].eventHandler);
SelectTreeMenu.property = Object.assign({}, SelectMenu2["a" /* default */].property);


Object.assign(SelectTreeMenu.prototype, SelectMenu2["a" /* default */].prototype);


ACore["d" /* default */].install(SelectTreeMenu);

/* harmony default export */ var js_SelectTreeMenu = (SelectTreeMenu);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/widthheightresizer.css
var widthheightresizer = __webpack_require__(233);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Draggable.js
var Draggable = __webpack_require__(49);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/WidthHeightSizer.js




//can replace with other module
var WidthHeightSizer_ = ACore["d" /* default */]._;
var WidthHeightSizer_$ = ACore["d" /* default */].$;

function WidthHeightResizer() {
    var res = WidthHeightSizer_({
        extendEvent: 'sizechange',
        class: 'absol-width-height-resizer',
        child: ['.absol-width-height-resizer-content',
            '.absol-width-height-resizer-anchor-bot-right',
            '.absol-width-height-resizer-anchor-bot-left',
            '.absol-width-height-resizer-anchor-top-right',
            '.absol-width-height-resizer-anchor-top-left'
        ]
    });

    res.eventHandler = OOP["a" /* default */].bindFunctions(res, WidthHeightResizer.eventHandler);

    res.$anchorBotRight = WidthHeightSizer_$('.absol-width-height-resizer-anchor-bot-right', res);
    res.$anchorTopRight = WidthHeightSizer_$('.absol-width-height-resizer-anchor-top-right', res);

    res.$anchorBotLeft = WidthHeightSizer_$('.absol-width-height-resizer-anchor-bot-left', res);
    res.$anchorTopLeft = WidthHeightSizer_$('.absol-width-height-resizer-anchor-top-left', res);

    res.$content = WidthHeightSizer_$('.absol-width-height-resizer-content', res);

    Object(Draggable["a" /* default */])(res.$anchorBotRight).on('drag', res.eventHandler.dragBotRight).on('predrag', res.eventHandler.preDrag);
    Object(Draggable["a" /* default */])(res.$anchorTopRight).on('drag', res.eventHandler.dragTopRight).on('predrag', res.eventHandler.preDrag);
    Object(Draggable["a" /* default */])(res.$anchorBotLeft).on('drag', res.eventHandler.dragBotLeft).on('predrag', res.eventHandler.preDrag);
    Object(Draggable["a" /* default */])(res.$anchorTopLeft).on('drag', res.eventHandler.dragTopLeft).on('predrag', res.eventHandler.preDrag);
    return res;
}

['addChild', 'addChildBefore', 'addChildAfter', 'clearChild'].forEach(function (key) {
    WidthHeightResizer.prototype[key] = function () {
        return this.$content[key].apply(this.$content, arguments);
    }
});

WidthHeightResizer.tag = 'WidthHeightResizer'.toLowerCase();

WidthHeightResizer.eventHandler = {};
WidthHeightResizer.eventHandler.preDrag = function (event) {
    this._whrWidth = parseFloat(this.getComputedStyleValue('width').replace('px', ''));
    this._whrHeight = parseFloat(this.getComputedStyleValue('height').replace('px', ''));

};

WidthHeightResizer.eventHandler.dragBotRight = function (event) {
    var newEvent = { target: this, data: {} };
    if (event.moveDX != 0) {
        this.addStyle('width', this._whrWidth + event.moveDX + 'px');
        newEvent.data.changeWidth = true;
    }
    if (event.moveDY != 0) {
        this.addStyle('height', this._whrHeight + event.moveDY + 'px');
        newEvent.data.changeHeight = true;
    }
    newEvent.data.height = this.getComputedStyleValue('height');
    newEvent.data.width = this.getComputedStyleValue('width');
    this.emit('sizechange', newEvent);
};

WidthHeightResizer.eventHandler.dragTopRight = function (event) {
    var newEvent = { target: this, data: {} };
    if (event.moveDX != 0) {
        this.addStyle('width', this._whrWidth + event.moveDX + 'px');
        newEvent.data.changeWidth = true;
    }
    if (event.moveDY != 0) {
        this.addStyle('height', this._whrHeight - event.moveDY + 'px');
        newEvent.data.changeHeight = true;
    }
    newEvent.data.height = this.getComputedStyleValue('height');
    newEvent.data.width = this.getComputedStyleValue('width');
    this.emit('sizechange', newEvent);
};

WidthHeightResizer.eventHandler.dragBotLeft = function (event) {
    var newEvent = { target: this, data: {} };
    if (event.moveDX != 0) {
        this.addStyle('width', this._whrWidth - event.moveDX + 'px');
        newEvent.data.changeWidth = true;
    }
    if (event.moveDY != 0) {
        this.addStyle('height', this._whrHeight + event.moveDY + 'px');
        newEvent.data.changeHeight = true;
    }
    newEvent.data.height = this.getComputedStyleValue('height');
    newEvent.data.width = this.getComputedStyleValue('width');
    this.emit('sizechange', newEvent);
};

WidthHeightResizer.eventHandler.dragTopLeft = function (event) {
    var newEvent = { target: this, data: {} };
    if (event.moveDX != 0) {
        this.addStyle('width', this._whrWidth - event.moveDX + 'px');
        newEvent.data.changeWidth = true;
    }
    if (event.moveDY != 0) {
        this.addStyle('height', this._whrHeight - event.moveDY + 'px');
        newEvent.data.changeHeight = true;
    }
    newEvent.data.height = this.getComputedStyleValue('height');
    newEvent.data.width = this.getComputedStyleValue('width');
    this.emit('sizechange', newEvent);
};

ACore["d" /* default */].creator.widthheightresizer = WidthHeightResizer;

/* harmony default export */ var WidthHeightSizer = (WidthHeightResizer);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/modal.css
var modal = __webpack_require__(235);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/Modal.js



var Modal_$ = ACore["d" /* default */].$;
var Modal_ = ACore["d" /* default */]._;

function Modal() {
    this._contentAlign = [];
    this.contentAlign = 'middle center';
    this.$content = Modal_$('.as-modal-content', this);
}


Modal.tag = 'modal';
Modal.render = function () {
    return Modal_({ class: 'as-modal', child: '.as-modal-content' });
};

['findChildBefore', 'findChildAfter', 'removeChild', 'clearChild', 'addChild'].forEach(function (key) {
    Modal.prototype[key] = function () {
        this.$content[key].apply(this.$content, arguments);
    }
});

Modal.prototype.getChildren = function (){
  return this.$content.children;
};


Modal.property = {};
Modal.property.show = {
    set: function (value) {
        if (value)
            this.removeClass('as-hidden');
        else
            this.addClass('as-hidden');
    },
    get: function () {
        return !this.containsClass('as-hidden');
    }
};

Modal.property.contentAlign = {
    set: function (value) {
        var thisM = this;
        this._contentAlign.forEach(function (name) {
            thisM.removeClass('as-' + name);
        })
        value = value || '';
        if (typeof value === 'string') {
            this._contentAlign = value.split(/\s+/);
        }
        else if (value instanceof Array) {
            this._contentAlign = value;
        }
        else {
            throw new Error("Invalid contentAlign!");
        }
        var thisM = this;
        this._contentAlign.forEach(function (name) {
            thisM.addClass('as-' + name);
        })
    },
    get: function () {
        return this._contentAlign.join(' ');
    }
}


ACore["d" /* default */].install(Modal);

/* harmony default export */ var js_Modal = (Modal);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/trackbar.css
var trackbar = __webpack_require__(237);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TrackBar.js





var TrackBar_ = ACore["d" /* default */]._;
var TrackBar_$ = ACore["d" /* default */].$;

/***
 * @extends Hanger
 * @constructor
 */
function TrackBar() {
    this.$bar = TrackBar_$('.absol-trackbar', this);
    this.$button = TrackBar_$('.absol-trackbar-button', this);
    this.$line = TrackBar_$('.absol-trackbar-line', this);
    this.on('predrag', this.eventHandler.predrag)
        .on('drag', this.eventHandler.drag);
    this.leftValue = 0;
    this.rightValue = 1;
    this._dragValue = 0;
}

TrackBar.tag = 'trackbar';

TrackBar.render = function () {
    return TrackBar_({
        tag: 'hanger',
        extendEvent: 'change',
        class: 'absol-trackbar',
        child: [{ class: 'absol-trackbar-line', child: '.absol-trackbar-button' }, 'attachhook'],

    });
};

TrackBar.prototype._updateValue = function () {
    var left = Object(Math_int["map"])(this.value, this.leftValue, this.rightValue, 0, 100);
    this.$button.addStyle('left', left + '%');
}

TrackBar.eventHandler = {};

TrackBar.eventHandler.predrag = function (event) {
    if (event.target === this) {
        event.cancel();
    }
    else {
        event.preventDefault();
        var lineBound = this.$line.getBoundingClientRect();
        var newValue = this.leftValue + (this.rightValue - this.leftValue) * (event.clientX - lineBound.left) / lineBound.width;
        newValue = Math.max(this.leftValue, Math.min(this.rightValue, newValue));
        if (newValue !== this.value) {
            this.value = newValue;
            event.trackbarValue = this.value;
            this._dragValue = this.value;
            this.emit('change', event);
        }
    }
};

TrackBar.eventHandler.drag = function (event) {
    var lineWidth = this.$line.getBoundingClientRect().width;
    var d = event.currentPoint.sub(event.startingPoint);
    var delta = d.x / lineWidth * (this.rightValue - this.leftValue);
    var newValue = Math.max(this.leftValue, Math.min(this.rightValue, this._dragValue + delta));
    if (newValue != this.value) {
        this.value = newValue;
        event.trackbarValue = this.value;
        this.emit('change', event);
    }
};


TrackBar.property = {};

TrackBar.property.value = {
    set: function (value) {
        value = parseFloat(value + '');
        if (isNaN(value)) value = 0;
        this._value = value;
        this._updateValue();
    },

    get: function () {
        return Math.max(this.leftValue, Math.min(this.rightValue, this._value));
    }
};


TrackBar.property.leftValue = {
    set: function (value) {
        value = parseFloat(value + '');
        if (isNaN(value)) value = 0;
        this._leftValue = value;
        this._updateValue();
    },
    get: function () {
        return this._leftValue || 0;
    }
};

TrackBar.property.rightValue = {
    set: function (value) {
        value = parseFloat(value + '');
        if (isNaN(value)) value = 1;
        this._rightValue = value;
        this._updateValue();
    },
    get: function () {
        return this._rightValue || 1;
    }
};

TrackBar.property.disabled = {
    get: function () {
        return this.containsClass('as-disabled');
    },
    set: function (value) {
        if (value) {
            this.addClass('as-disabled');
        }
        else {
            this.removeClass('as-disabled');
        }
    }
};

ACore["d" /* default */].install(TrackBar);

/* harmony default export */ var js_TrackBar = (TrackBar);


// EXTERNAL MODULE: ./node_modules/absol-acomp/css/trackbarinput.css
var trackbarinput = __webpack_require__(239);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TrackBarInput.js




var TrackBarInput_ = ACore["d" /* default */]._;
var TrackBarInput_$ = ACore["d" /* default */].$;

/***
 *
 * @extends {AElement}
 * @constructor
 */
function TrackBarInput() {
    var thisTI = this;
    this.$trackbar = TrackBarInput_$('trackbar', this);
    this.$input = TrackBarInput_$('flexiconinput', this);

    absol.OOP.drillProperty(this, this.$input, ['unit', 'icon']);


    this.$trackbar.on('change', function () {
        thisTI.$input.value = thisTI.value + '';
        thisTI.emit('change', thisTI.value);
    });

    this.$input.on('keyup', this.eventHandler.inputChange);
    this.inputTextWidth = 2;
    this.valueFixed = undefined;
    return this;
}


TrackBarInput.tag = 'TrackBarInput'.toLowerCase();

TrackBarInput.render = function () {
    return TrackBarInput_({
        class: 'absol-trackbar-input',
        extendEvent: 'change',
        child: [
            'trackbar',
            'flexiconinput'
        ]
    });
};

TrackBarInput.prototype.init = function (props) {
    props = props || {};
    props.leftValue = props.leftValue || 0;
    props.value = props.value || props.leftValue;
    Object.assign(this, props);
    this.value = props.value;
};

TrackBarInput.prototype._calInputTextWidth = function () {
    var l = Math.max(this.leftValue.toFixed(this.valueFixed || 0).length, this.rightValue.toFixed(this.valueFixed || 0).length, 2);
    if (this.valueFixed > 0) {
        l -= 0.8;
    }
    this.inputTextWidth = l;
};

// absol.OOP.drillProperty(this, this.$trackbar, ['leftValue', 'rightValue']);


TrackBarInput.property = {};

TrackBarInput.property.leftValue = {
    set: function (value) {
        this.$trackbar.leftValue = value;
        this._calInputTextWidth();
    },
    get: function () {
        return this.$trackbar.leftValue;
    }
};

TrackBarInput.property.rightValue = {
    set: function (value) {
        this.$trackbar.rightValue = value;
        this._calInputTextWidth();
    },
    get: function () {
        return this.$trackbar.rightValue;
    }
};


TrackBarInput.property.value = {
    set: function (value) {
        this.$trackbar.value = value || 0;
        this.$input.value = this.value + '';
    },
    get: function () {
        return parseFloat((this.valueFixed === undefined ? this.$trackbar.value : this.$trackbar.value.toFixed(this.valueFixed)) + '');
    }
};

TrackBarInput.property.valueFixed = {
    set: function (value) {
        if (value === undefined || value === null) value = undefined;
        this._valueFixed = value;
        this.$input.value = this.value + '';
        this._calInputTextWidth();
    },
    get: function () {
        return this._valueFixed;
    }
};

TrackBarInput.property.inputTextWidth = {
    set: function (value) {
        if (typeof value == 'number') {
            this._inputTextWidth = value;
            this.addStyle('--input-width', 3 + (value - 2) * 0.42 + 0.3 + 'em');
        }
        else {
            this._inputTextWidth = value;
            this.addStyle('--input-width', value);
        }
    },
    get: function () {
        return this._inputTextWidth;
    }
};

TrackBarInput.property.disabled = {
    get: function () {
        return this.containsClass('as-disabled');
    },
    set: function (value) {
        if (value) {
            this.addClass('as-disabled');
        }
        else {
            this.removeClass('as-disabled');
        }
        this.$input.disabled = !!value;
        this.$trackbar.disabled = !!value;
    }
};

TrackBarInput.eventHandler = {};


TrackBarInput.eventHandler.inputChange = function (event) {
    var newValue = parseFloat(this.$input.value);
    if (!isNaN(newValue)) {
        newValue = Math.max(this.leftValue, Math.min(this.rightValue, newValue));
        this.$trackbar.value = newValue;
        this.emit('change', this.value);
    }
};

/* harmony default export */ var js_TrackBarInput = (TrackBarInput);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/buttonrange.css
var buttonrange = __webpack_require__(241);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/ButtonRange.js






var ButtonRange_ = ACore["d" /* default */]._;
var ButtonRange_$ = ACore["d" /* default */].$;


var ChevronLeft = '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" id="Layer_1" x="0px" y="0px" viewBox="0 0 410.258 410.258" style="enable-background:new 0 0 410.258 410.258;" xml:space="preserve">\n' +
    '<polygon points="298.052,24 266.052,0 112.206,205.129 266.052,410.258 298.052,386.258 162.206,205.129 "/>\n' +
    '</svg>';

var ChevronRight = '<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"\n' +
    '\t viewBox="0 0 410.258 410.258" style="enable-background:new 0 0 410.258 410.258;" xml:space="preserve">\n' +
    '<polygon points="144.206,0 112.206,24 248.052,205.129 112.206,386.258 144.206,410.258 298.052,205.129 "/>\n' +
    '</svg>'

/***
 * @extends AElement
 * @constructor
 */
function ButtonRange() {
    this._dict = {};
    this._pool = [];
    this._items = [];
    this.$lastActiveBtn = null;
    this._value = undefined;
    this._lastValue = this._value;
    this.$scroller = ButtonRange_$('.as-button-range-scroller', this)
        .on('wheel', this.eventHandler.wheel);
    this.$prevBtn = ButtonRange_$('.as-button-range-left-btn', this)
        .on('click', this.prevValue.bind(this));
    this.$nextBtn = ButtonRange_$('.as-button-range-right-btn', this)
        .on('click', this.nextValue.bind(this));
    this._scrollTimeout = -1;
    this._scrollToSelected = this._scrollToSelected.bind(this);
    this.$attachhook = ButtonRange_$('attachhook', this).on('error', this.eventHandler.attached);
    this.autoWidth = false;
}

ButtonRange.tag = 'buttonrange';
ButtonRange.render = function () {
    return ButtonRange_({
        extendEvent: ['change'],
        class: 'as-button-range',
        child: [
            {
                class: 'as-button-range-scroller',
            },
            {
                class: 'as-button-range-left-ctn',
                child: {
                    tag: 'button',
                    class: 'as-button-range-left-btn',
                    child: ChevronLeft
                }
            },
            {
                class: 'as-button-range-right-ctn',
                child: {
                    tag: 'button',
                    class: 'as-button-range-right-btn',
                    child: ChevronRight
                }
            },
            'attachhook'
        ]
    });
};

ButtonRange.prototype._updateUnderlinePosition = function () {
    if (!this.$lastActiveBtn) return;
    var scrollerFirstBound = this.$scroller.firstChild.getBoundingClientRect();
    if (scrollerFirstBound.width === 0) return;
    var activeBound = this.$lastActiveBtn.getBoundingClientRect();
    this.addStyle({
        '--underline-left': activeBound.left - scrollerFirstBound.left + 'px',
        '--underline-width': activeBound.width + 'px'
    });

};

ButtonRange.prototype.updateSize = function () {
    if (this.autoWidth) {
        if (this.$scroller.childNodes.length > 0) {
            var left = this.$scroller.firstChild.getBoundingClientRect().left;
            var right = this.$scroller.lastChild.getBoundingClientRect().right;
            if (left < right) {
                var fontSize = this.getFontSize() || 14;
                this.addStyle('width', (right - left + 2) / fontSize + 2 + 'em')
            }
        }
    }
    this._updateUnderlinePosition();
    this._scrollToSelected();
};

ButtonRange.prototype._newButton = function () {
    var button = ButtonRange_({
        tag: 'button',
        class: 'as-button-range-item',
        child: { text: 'null' }
    });
    button.on('click', this.eventHandler.clickItem.bind(this, button));
    return button;
};

ButtonRange.prototype._requestButton = function (items) {
    var button;
    if (this._pool.length > 0) {
        button = this._pool.pop();
    }
    else {
        button = this._newButton();
    }
    return button;
};

ButtonRange.prototype._assignButton = function (button, data) {
    button._data = data;
    button.childNodes[0].data = data.text;
};

ButtonRange.prototype._releaseButton = function (button) {
    this._pool.push(button);
};

ButtonRange.prototype._requireButton = function (n) {
    var child;
    while (this.$scroller.childNodes.length > n) {
        child = this.$scroller.lastChild;
        this._releaseButton(child);
        this.$scroller.removeChild(child);
    }

    while (this.$scroller.childNodes.length < n) {
        this.$scroller.addChild(this._requestButton());
    }
};

ButtonRange.prototype._assignButtonList = function (items) {
    var item;
    for (var i = 0; i < items.length; ++i) {
        item = this._getFullFormat(items[i]);
        this._assignButton(this.$scroller.childNodes[i], item);
        this._dict[item.ident] = {
            elt: this.$scroller.childNodes[i],
            data: item
        }
    }
};

ButtonRange.prototype._scrollToSelected = function () {
    if (this._scrollTimeout >= 0) return;
    if (!this.$lastActiveBtn) return;
    var scrollerBound = this.$scroller.getBoundingClientRect();
    if (scrollerBound.width === 0) return;
    var activeBound = this.$lastActiveBtn.getBoundingClientRect();
    var dx, speed;
    if (activeBound.left < scrollerBound.left - 1) {
        dx = activeBound.left - scrollerBound.left;
        if (dx < -500) dx = -500;
        speed = Math.sqrt(-dx * 2 + 4);
        this.$scroller.scrollLeft -= speed;
    }
    else if (activeBound.right - 1 > scrollerBound.right) {
        dx = activeBound.right - scrollerBound.right;
        if (dx > 500) dx = 500;
        speed = Math.sqrt(dx * 2 + 4);
        this.$scroller.scrollLeft += speed;
    }
    else {
        return;
    }
    var thisBR = this;
    this._scrollTimeout = setTimeout(function () {
        thisBR._scrollTimeout = -1;
        thisBR._scrollToSelected();
    }, 20);
};

ButtonRange.prototype.nextValue = function (userAction) {
    var currentIndex = this._findActiveIndex();
    var nextIndex;
    var nextValue;
    if (currentIndex < 0) {
        nextIndex = 0;
    }
    else {
        nextIndex = Math.min(this._items.length - 1, currentIndex + 1);
    }
    if (nextIndex >= 0) {
        nextValue = this._getFullFormat(this._items[nextIndex]).value;
        this.value = nextValue;
        if (userAction) this.notifyChange();
    }
};


ButtonRange.prototype.prevValue = function (userAction) {
    var currentIndex = this._findActiveIndex();
    var prevIndex;
    var prevValue;
    if (currentIndex < 0) {
        prevIndex = 0;
    }
    else {
        prevIndex = Math.max(0, currentIndex - 1);
    }
    if (prevIndex >= 0 && prevIndex < this._items.length && prevIndex != currentIndex) {
        prevValue = this._getFullFormat(this._items[prevIndex]).value;
        this.value = prevValue;
        if (userAction) this.notifyChange();
    }
};

ButtonRange.prototype._findActiveIndex = function () {
    var item;
    var value = this._value;
    for (var i = 0; i < this._items.length; ++i) {
        item = this._items[i];
        if (item === value || (item && item.value === value))
            return i;
    }
    return -1;
}


ButtonRange.prototype._getFullFormat = function (item) {
    var res = {};
    if ((typeof item == 'string') || (typeof item == 'number') || (typeof item == 'boolean') || (item === null) || (item === undefined)) {
        res.ident = item + '';
        res.value = item;
        res.text = item + '';
    }
    else if (item && (typeof item == 'object')) {
        res.value = item.value;
        res.ident = res.value + '';
        res.text = item.text;
    }
    return res;
};

ButtonRange.prototype.notifyChange = function () {
    this.emit('change', { target: this, value: this.value, type: 'change' }, this);
}


ButtonRange.property = {};

/**
 * @type {ButtonRange}
 */
ButtonRange.property.items = {
    set: function (items) {
        items = items || [];
        this._items = items;
        this._requireButton(items.length);
        this._assignButtonList(items);
        if (items.length > 0) {
            if (!this._dict[this._value + '']) {
                this._value = this._getFullFormat(items[0]).value;
            }
        }
        this.value = this._value;
        this.updateSize();
    },
    get: function () {
        return this._items;
    }
};

ButtonRange.property.value = {
    set: function (value) {
        this._value = value;
        this._lastValue = this._value;
        if (this.$lastActiveBtn) {
            this.$lastActiveBtn.removeClass('as-active');
            this.$lastActiveBtn = null;
        }
        var hodler = this._dict[value + ''];
        if (hodler) {
            hodler.elt.addClass('as-active');
            this.$lastActiveBtn = hodler.elt;
        }
        var activeIndex = this._findActiveIndex();
        this.$prevBtn.disabled = activeIndex === 0;
        this.$nextBtn.disabled = activeIndex === this._items.length - 1;
        this._updateUnderlinePosition();
        this._scrollToSelected();
    },
    get: function () {
        return this._value;
    }
};


ButtonRange.eventHandler = {};

ButtonRange.eventHandler.clickItem = function (item, event) {
    if (this._lastValue != item._data.value) {
        this.value = item._data.value;
        this.notifyChange();
    }
};

ButtonRange.eventHandler.attached = function () {
    if (this.style.width === 'auto') this.autoWidth = true;
    Dom["b" /* default */].addToResizeSystem(this.$attachHook);
    this.updateSize();
};


ButtonRange.eventHandler.wheel = function (event) {
    var prevLeft = this.$scroller.scrollLeft;
    if (event.deltaY < 0) {
        this.$scroller.scrollLeft -= 100;
    }
    else if (event.deltaY > 0) {
        this.$scroller.scrollLeft += 100;
    }
    if (prevLeft !== this.$scroller.scrollLeft)
        event.preventDefault();
};


ACore["d" /* default */].install(ButtonRange);

/* harmony default export */ var js_ButtonRange = (ButtonRange);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/dropzone.css
var dropzone = __webpack_require__(243);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/DropZone.js






var DropZone_ = ACore["d" /* default */]._;
var DropZone_$ = ACore["d" /* default */].$;

/***
 * @extends AElement
 * @constructor
 */
function DropZone() {
    this.defineEvent(['fileenter', 'fileleave', 'filedrop']);
    this.addClass('as-drop-zone');
    this.on('dragover', this.eventHandler.dragZoneFileOver)
        .on('drop', this.eventHandler.dropZoneFileDrop);
    this._fileOverTimeout = -1;
}

DropZone.tag = 'dropzone';

DropZone.render = function () {
    return DropZone_('div');
};

DropZone.eventHandler = {};
DropZone.eventHandler.dragZoneFileOver = function (event) {
    event.preventDefault();
    if (this._fileOverTimeout > 0) {
        clearTimeout(this._fileOverTimeout);
    } else {
        this.addClass('as-drag-over');
        this.emit('fileenter', event, this);
    }
    this._fileOverTimeout = setTimeout(this.eventHandler.dragZoneFileOverEnd, 100);
};

/***
 *
 * @param {DragEvent} event
 */
DropZone.eventHandler.dropZoneFileDrop = function (event) {
    if (this._fileOverTimeout > 0) {
        clearTimeout(this._fileOverTimeout);
        this._fileOverTimeout = -1;
    }
    event.preventDefault();
    this.removeClass('as-drag-over');


    event._files = null;
    if (!event.hasOwnProperty('files'))
        Object.defineProperty(event, 'files', {
            get: function () {
                if (this._files) return this._files;
                var files = [];
                var file;
                if (event.dataTransfer.items) {
                    for (var i = 0; i < event.dataTransfer.items.length; i++) {
                        if (event.dataTransfer.items[i].kind === 'file') {
                            file = event.dataTransfer.items[i].getAsFile();
                            files.push(file);
                        }
                    }
                } else {
                    // Use DataTransfer interface to access the file(s)
                    for (var i = 0; i < event.dataTransfer.files.length; i++) {
                        files.push(event.dataTransfer.files[i]);
                    }
                }
                this._files = files;
                return this._files;
            }
        });

    this.emit('filedrop', event, this);
};

DropZone.eventHandler.dragZoneFileOverEnd = function () {
    this._fileOverTimeout = -1;
    this.removeClass('as-drag-over');
    this.emit('fileleave', {type: 'fileleave'}, this);
};

ACore["d" /* default */].install(DropZone);

/* harmony default export */ var js_DropZone = (DropZone);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/radioinput.css
var radioinput = __webpack_require__(245);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/RadioInput.js




//new tech, not working version

var RadioInput_ = ACore["d" /* default */]._;
var RadioInput_$ = ACore["d" /* default */].$;

/***
 * @extends Element
 * @constructor
 */
function RadioInput() {
    this.$input = RadioInput_$('input', this)
        .on('change', this.notifyChange.bind(this));
    this.checked = false;
    this.disabled = false;
    this.on('click', this.eventHandler.click);
    this.onchange = null;
}

RadioInput.tag = "RadioInput".toLowerCase();

RadioInput.render = function (data) {
    return RadioInput_({
            tag: 'label',
            extendEvent: 'change',
            class: 'as-radio-input',
            child: [
                {
                    elt: data && data.$input,
                    tag: 'input',
                    class: 'as-radio-input-value',
                    attr: {
                        type: 'radio'
                    }
                },
                {
                    class: ['as-radio-input-check-mark']
                }
            ]
        }
    )
};

/***
 * as normal, change event will be fired when radio change by system
 */
RadioInput.prototype.notifyChange = function () {
    var event = { checked: this.checked };
    this.emit('change', event, this);
};

RadioInput.prototype._updateCheckedClass = function () {
    if (this.checked) {
        this.addClass('as-checked');
    }
    else {
        this.removeClass('as-checked');
    }
};


RadioInput.property = {};

RadioInput.property.disabled = {
    set: function (value) {
        if (value) {
            this.addClass('as-disabled');
        }
        else {
            this.removeClass('as-disabled');
        }
        this.$input.disabled = !!value;
    },
    get: function () {
        this.$input.disabled;
    }
};

/***
 *
 * @type {RadioInput}
 */
RadioInput.property.checked = {
    set: function (value) {
        this.$input.checked = !!value;
        this._updateCheckedClass();
    },
    get: function () {
        return this.$input.checked;
    }
}

RadioInput.attribute = {
    checked: {
        set: function (value) {
            if (value === 'false' || value === null) {
                this.checked = false;
            }
            else {
                this.checked = true;
            }
        },
        get: function () {
            return this.checked ? 'true' : 'false'
        },
        remove: function () {
            this.checked = false;
        }
    },
    disabled: {
        set: function (value) {
            if (value === 'false' || value === null) {
                this.disabled = false;
            }
            else {
                this.disabled = true;
            }
        },
        get: function () {
            return this.disabled ? 'true' : 'false'
        },
        remove: function () {
            this.disabled = false;
        }
    }
};

/***
 *
 * @type {RadioInput}
 */
RadioInput.eventHandler = {};

RadioInput.eventHandler.click = function () {
    this._updateCheckedClass();
};


ACore["d" /* default */].install(RadioInput);


RadioInput.autoReplace = function () {
    var placeHolders = Array.prototype.slice.call(document.getElementsByTagName(this.tag));
    var ph;
    var attOfPH;
    var attrs;
    var style;
    var classList;
    var attNode;
    var attrName, attrValue;
    var props;
    for (var i = 0; i < placeHolders.length; ++i) {
        ph = placeHolders[i];
        attOfPH = ph.attributes;
        classList = [];
        style = {};
        attrs = {};
        props = {};
        for (var j = 0; j < attOfPH.length; ++j) {
            attNode = attOfPH[j];
            attrName = attNode.nodeName;
            attrValue = attNode.nodeValue;
            if (attrName == 'style') {
                attrValue.trim().split(';').reduce(function (style, prop) {
                    var p = prop.split(':');
                    if (p.length == 2) {
                        style[p[0].trim()] = p[1].trim();
                    }
                    return style;
                }, style);
            }
            else if (attrName == 'class') {
                classList = attrValue.trim().split(/\s+/);
            }
            else if (attrName == 'onchange') {
                props.onchange = new Function('event', 'sender', attrValue);
            }
            else {
                attrs[attrName] = attrValue;
            }
        }
        var newElt = RadioInput_({
            tag: this.tag,
            attr: attrs,
            class: classList,
            style: style,
            props: props
        });
        RadioInput_$(ph).selfReplace(newElt);
    }
};

RadioInput.initAfterLoad = function (){
    Dom["b" /* default */].documentReady.then(function (){
        RadioInput.autoReplace();
    })
};


/* harmony default export */ var js_RadioInput = (RadioInput);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/OnScreenWidget.js
var OnScreenWidget = __webpack_require__(74);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/ribbonsplitbutton.css
var ribbonsplitbutton = __webpack_require__(249);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/RibbonSplitButton.js






var RibbonSplitButton_ = ACore["d" /* default */]._;
var RibbonSplitButton_$ = ACore["d" /* default */].$;


/***
 * @extends AElement
 * @constructor
 */
function RibbonSplitButton() {
    this.$icon = null;
    this._icon = null;
    this.$text = RibbonSplitButton_$('.as-ribbon-split-button-text', this);
    this.$textNode = this.$text.firstChild;
    this.$primaryBtn = RibbonSplitButton_$('.as-ribbon-split-button-primary', this)
        .on('click', this.eventHandler.clickPrimaryBtn);
    this.$extendBtn = RibbonSplitButton_$('.as-ribbon-split-button-extend', this);
    this._menuHolder = null;
}

RibbonSplitButton.tag = 'RibbonSplitButton'.toLowerCase();

RibbonSplitButton.render = function () {
    return RibbonSplitButton_({
        extendEvent: ['press', 'select'],
        attr: {
            'tabindex': '0'
        },
        class: ['as-ribbon-split-button', 'as-no-dropdown'],
        child: {
            class: 'as-ribbon-split-button-content',
            child: [
                {
                    tag: 'button',
                    attr: {
                        'tabindex': '-1'
                    },
                    class: 'as-ribbon-split-button-primary',
                    child: { tag: 'span', class: 'as-ribbon-split-button-text', child: { text: '' } }
                },
                {
                    tag: 'button',
                    attr: {
                        'tabindex': '-1'
                    },
                    class: 'as-ribbon-split-button-extend',
                    child: 'span.mdi.mdi-chevron-down'
                }
            ]
        }
    });
};

RibbonSplitButton.property = {};

RibbonSplitButton.property.items = {
    set: function (items) {
        var thisB = this;
        this._items = items || [];
        if (this._items && this._items.length > 0) {
            if (!this._menuHolder) {
                this.removeClass('as-no-dropdown');
                this._menuHolder = QuickMenu["a" /* default */].toggleWhenClick(this.$extendBtn || this, {
                    getMenuProps: function () {
                        return {
                            extendStyle: {
                                'min-width': thisB.getBoundingClientRect().width + 'px'
                            },
                            items: thisB._items
                        }
                    },
                    getFlowedElement: function () {
                        return thisB;
                    },
                    anchor: [1, 2, 6, 5],
                    onSelect: function (item) {
                        thisB.emit('select', { item: Object(utils["cleanMenuItemProperty"])(item), type: 'select', target: thisB });
                    }
                });
            }
        }
        else {
            if (this._menuHolder) {
                this.addClass('as-no-dropdown');
                this._menuHolder.remove();
                this._menuHolder = null;
            }
        }
    },
    get: function () {
        return this._items;
    }
};

RibbonSplitButton.property.text = {
    set: function (value) {
        value = value || '';
        this.$textNode.data = value;
    },
    get: function () {
        return this.$textNode.data;
    }
};


RibbonSplitButton.property.icon = {
    set: function (icon) {
        icon = icon || null;
        this._icon = icon;
        if (this.$icon) this.$primaryBtn.removeChild(this.$icon);
        if (icon) {
            this.$icon = RibbonSplitButton_(icon);
            this.$primaryBtn.addChildBefore(this.$icon, this.$text);
            if (this.$icon.addClass) this.$icon.addClass('as-ribbon-split-button-icon');
        }
        else {
            this.$icon = null;
        }
    },
    get: function () {
        return this._icon;
    }
};


RibbonSplitButton.eventHandler = {};

RibbonSplitButton.eventHandler.clickPrimaryBtn = function () {
    this.emit('press', { type: 'press', target: this, item: Object(utils["cleanMenuItemProperty"])(this) })
}

ACore["d" /* default */].install(RibbonSplitButton);

/* harmony default export */ var js_RibbonSplitButton = (RibbonSplitButton);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/ribbonbutton.css
var ribbonbutton = __webpack_require__(251);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/RibbonButton.js





var RibbonButton_ = ACore["d" /* default */]._;
var RibbonButton_$ = ACore["d" /* default */].$;


/***
 * @extends AElement
 * @constructor
 */
function RibbonButton() {
    this.$icon = null;
    this._icon = null;
    this.$text = RibbonButton_$('.as-ribbon-button-text', this);
    this.$textNode = this.$text.firstChild;
    this._menuHolder = null;
}

RibbonButton.tag = 'RibbonButton'.toLowerCase();

RibbonButton.render = function () {
    return RibbonButton_({
        tag: 'button',
        extendEvent: ['select'],
        attr: {
            'tabindex': '0'
        },
        class: ['as-ribbon-button', 'as-no-dropdown'],
        child: [
            {
                tag: 'span', class: 'as-ribbon-button-text',
                child: { text: '' }
            },
            'span.mdi.mdi-chevron-down'
        ]
    });
};

RibbonButton.property = Object.assign({}, js_RibbonSplitButton.property);


RibbonButton.property.icon = {
    set: function (icon) {
        icon = icon || null;
        this._icon = icon;
        if (this.$icon) this.removeChild(this.$icon);
        if (icon) {
            this.$icon = RibbonButton_(icon);
            this.addChildBefore(this.$icon, this.$text);
            if (this.$icon.addClass) this.$icon.addClass('as-ribbon-button-icon');
        }
        else {
            this.$icon = null;
        }
    },
    get: function () {
        return this._icon;
    }
};


RibbonButton.eventHandler = {};

ACore["d" /* default */].install(RibbonButton);

/* harmony default export */ var js_RibbonButton = (RibbonButton);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/timeselectinput.css
var timeselectinput = __webpack_require__(253);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TimeSelectInput.js











var TimeSelectInput_ = ACore["d" /* default */]._;
var TimeSelectInput_$ = ACore["d" /* default */].$;


/***
 * @extends AElement
 * @constructor
 */
function TimeSelectInput() {
    /***
     *
     * @type {SelectListBox}
     */
    this.$selectlistBox = TimeSelectInput_({
        tag: 'selectlistbox',
        props: {
            anchor: [1, 6, 2, 5]
        },
        on: {
            preupdateposition: this.eventHandler.preUpdateListPosition
        }
    });
    this.$text = TimeSelectInput_$('.as-time-select-input-text', this)
        .on('change', this.eventHandler.textChange)
        .on('keyup', this.eventHandler.textKeyUp)
        .on('keydown', this.eventHandler.textKeyDown);


    this.$toggleBtn = TimeSelectInput_$('absol-selectmenu-btn', this);
    this.$selectlistBox.on('pressitem', this.eventHandler.selectListBoxPressItem);
    this.$selectlistBox.followTarget = this;
    this._makeTimeList(0, datetime["MILLIS_PER_DAY"], datetime["MILLIS_PER_MINUTE"] * 15);
    this._hour = 0;
    this._minute = 0;
    this._lastDayOffset = 0;
    this.dayOffset = 0;
    this.on('click', this.eventHandler.click);

}

TimeSelectInput.tag = 'TimeSelectInput'.toLowerCase();

TimeSelectInput.render = function () {
    return TimeSelectInput_({
        class: 'as-time-select-input',
        extendEvent: 'change',
        attr: {
            tabindex: 0
        },
        child: [
            {
                tag: 'input',
                class: 'as-time-select-input-text',
                attr: {
                    type: 'text'
                }
            },
            {
                tag: 'button',
                class: 'absol-selectmenu-btn',
                child: ['dropdown-ico']
            }
        ]
    });
};


TimeSelectInput.prototype._makeTimeList = function (start, end, step) {
    var items = [];
    for (var t = 0; t < end; t += step) {
        items.push({
            text: this._mil2Text(t),
            value: t
        });
    }
    this.$selectlistBox.items = items;
    this.addStyle('--list-min-width', this.$selectlistBox._estimateWidth + 'px');
};

TimeSelectInput.prototype.textRegx = /^((1[0-2])|[1-9]):([0-5][0-9]) (AM|PM)$/;

TimeSelectInput.prototype._mil2Text = function (mil) {
    if (mil < 0) {
        mil = mil + Math.ceil(-mil / datetime["MILLIS_PER_DAY"]) * datetime["MILLIS_PER_DAY"];
    }
    var min = Math.floor(mil / (datetime["MILLIS_PER_MINUTE"]));
    var hour = Math.floor(min / 60) % 24;
    min = min % 60;
    return (hour % 12 == 0 ? 12 : (hour % 12)) + ':' + (min < 10 ? '0' : '') + min + ' ' + (hour < 12 ? 'AM' : 'PM');
};

/***
 *
 * @param {string} s
 * @private
 */
TimeSelectInput.prototype._text2mil = function (s) {
    s = s.toLowerCase();
    var nums = s.match(/[0-9]+/g) || [0, 0];
    while (nums.length < 2) {
        nums.push(0);
    }
    var h = Object(utils["positiveIntMod"])(parseInt(nums[0]), 24);
    var m = Object(utils["positiveIntMod"])(parseInt(nums[1]), 60);
    var pm = s.indexOf('pm') > 0 || h > 12;
    if (pm) {
        if (h < 12) h += 12;
    }
    else {
        if (h == 12) h = 0;
    }
    return h * datetime["MILLIS_PER_HOUR"] + m * datetime["MILLIS_PER_MINUTE"];
};


TimeSelectInput.prototype.isActive = function () {
    return document.activeElement == this || AElement["a" /* default */].prototype.isDescendantOf.call(document.activeElement, this)
        || AElement["a" /* default */].prototype.isDescendantOf.call(document.activeElement, this.$selectlistBox);
};

TimeSelectInput.prototype._updateValueText = function () {
    this.$text.value = this._mil2Text(this.dayOffset);
};

TimeSelectInput.prototype.notifyCanBeChange = function () {
    var dayOffset = this.dayOffset;
    if (this._lastDayOffset !== dayOffset) {
        this.emit('change', {
            type: 'change',
            lastDayOffset: this._lastDayOffset,
            dayOffset: dayOffset,
            target: this
        }, this);
        this._lastDayOffset = dayOffset;
    }
};


TimeSelectInput.property = {};

TimeSelectInput.property.isFocus = {
    get: function () {
        return this.containsClass('as-focus');
    },
    set: function (value) {
        value = !!value;
        if (this.isFocus == value) return;
        if (value) {
            this.addClass('as-focus');
        }
        else {
            this.removeClass('as-focus');
        }
        var thisI = this;
        if (value) {
            document.body.appendChild(this.$selectlistBox);
            this.$selectlistBox.domSignal.$attachhook.emit('attached');
            var bound = this.getBoundingClientRect();
            this.$selectlistBox.addStyle('min-width', bound.width + 'px');
            this.$selectlistBox.refollow();
            this.$selectlistBox.updatePosition();
            setTimeout(function () {
                if (thisI.enableSearch) {
                    thisI.$selectlistBox.$searchInput.focus();
                }
                TimeSelectInput_$(document.body).on('click', thisI.eventHandler.bodyClick);
            }, 1);
            this.$selectlistBox.viewListAtFirstSelected();
        }
        else {
            TimeSelectInput_$(document.body).off('click', thisI.eventHandler.bodyClick);
            this.$selectlistBox.selfRemove();
            this.$selectlistBox.unfollow();
            this.$selectlistBox.resetSearchState();
        }
    }
};


TimeSelectInput.property.hour = {
    set: function (value) {
        this._hour = Object(utils["positiveIntMod"])(value, 24);
        this._lastDayOffset = this.dayOffset;
        this._updateValueText();
    },
    get: function () {
        return this._hour;
    }
};

TimeSelectInput.property.minute = {
    set: function (value) {
        this._minute = Object(utils["positiveIntMod"])(value, 60);
        this._lastDayOffset = this.dayOffset;
        this._updateValueText();
    },
    get: function () {
        return this._minute;
    }
};

TimeSelectInput.property.dayOffset = js_TimeInput.property.dayOffset;
TimeSelectInput.property.disabled = {
    set: function (value) {
        this.$text.disabled = !!value;
        if (value) {
            this.addClass('as-disabled');
        }
        else {
            this.removeClass('as-disabled');
        }
    }
    ,
    get: function () {
        return this.containsClass('as-disabled');
    }
};


/***
 *
 * @type {{}|TimeSelectInput}
 */
TimeSelectInput.eventHandler = {};

TimeSelectInput.eventHandler.selectListBoxPressItem = function (event) {
    var lastValue = this._lastDayOffset;
    var value = event.value;
    var text = this._mil2Text(value);
    this.dayOffset = value;
    this.$selectlistBox.values = [value];
    this.focus();
    setTimeout(function () {
        this.isFocus = false;
    }.bind(this), 100);
    this._lastDayOffset = lastValue;// restore last value after set dayOffset
    this.notifyCanBeChange();
};

TimeSelectInput.eventHandler.preUpdateListPosition = function () {
    var bound = this.getBoundingClientRect();
    var screenSize = Object(Dom["d" /* getScreenSize */])();
    var availableTop = bound.top - 5;
    var availableBot = screenSize.height - 5 - bound.bottom;
    this.$selectlistBox.addStyle('--max-height', Math.max(availableBot, availableTop) + 'px');
    var outBound = Object(Dom["f" /* traceOutBoundingClientRect */])(this);
    if (bound.bottom < outBound.top || bound.top > outBound.bottom || bound.right < outBound.left || bound.left > outBound.right) {
        this.isFocus = false;
    }
};

TimeSelectInput.eventHandler.textChange = function () {
    setTimeout(function () {
        if (!this.textRegx.test(this.$text.value)) {
            this.$text.value = this._mil2Text(this.dayOffset);
        }
    }.bind(this), 10);
};

/***
 *
 * @param {KeyboardEvent} event
 */
TimeSelectInput.eventHandler.textKeyDown = function (event) {
    if (event.key == 'Enter') {
        this.isFocus = false;
        this.$text.blur();
        this.notifyCanBeChange();
    }
};


TimeSelectInput.eventHandler.textKeyUp = function (event) {
    var s = this.$text.value;
    var mil = this._text2mil(s);
    this._hour = Math.floor(mil / datetime["MILLIS_PER_HOUR"]);
    this._minute = Math.floor(mil / datetime["MILLIS_PER_MINUTE"]) % 60;
    this.$selectlistBox.values = [mil];
    this.$selectlistBox.viewListAtFirstSelected();
};

TimeSelectInput.eventHandler.click = function (event) {
    if (!EventEmitter["b" /* default */].hitElement(this.$text, event)) {
        this.isFocus = !this.isFocus;
        setTimeout(function () {
            if (this.isFocus && this.$text != document.activeElement) {
                this.$text.select();
            }
        }.bind(this), 1)
    }
    else {
        if (!this.isFocus) this.isFocus = true;
    }
};

TimeSelectInput.eventHandler.bodyClick = function (event) {
    if (EventEmitter["b" /* default */].hitElement(this, event) || EventEmitter["b" /* default */].hitElement(this.$selectlistBox, event)) return;
    this.isFocus = false;
};


ACore["d" /* default */].install(TimeSelectInput);

/* harmony default export */ var js_TimeSelectInput = (TimeSelectInput);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Snackbar.js
var Snackbar = __webpack_require__(62);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/MultiSelectMenu.js
var MultiSelectMenu = __webpack_require__(34);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/countdownclock.css
var countdownclock = __webpack_require__(97);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/CountdownClock.js






var CountdownClock_ = ACore["d" /* default */]._;
var CountdownClock_$ = ACore["d" /* default */].$;


/***
 * @extends AElement
 * @constructor
 */
function CountdownClock() {
    var thisC = this;
    this.$attachhook = CountdownClock_('attachhook').addTo(this)
        .on('attached', function () {
            ResizeSystem["a" /* default */].add(this);
            this.requestUpdateSize();
            if (thisC.autoStart) {
                thisC.start();
            }
        });

    this.$attachhook.requestUpdateSize = this._updateBorder.bind(this);
    this._tick = this._tick.bind(this);
    this.$border = CountdownClock_$(".as-countdown-clock-border", this);
    this.$min = CountdownClock_$(".as-countdown-clock-min", this);
    this.$sec = CountdownClock_$(".as-countdown-clock-sec", this);
    this._prevText = -1;
    this._startTime = new Date().getTime();
    this._totalSecond = 60;
    this._remainSecond = 0;

    this.totalSecond = 60;
    this.remainSecond = 0;
    this._intvId = -1;

}

CountdownClock.tag = 'CountdownClock'.toLowerCase();

CountdownClock.render = function () {
    return CountdownClock_({
        extendEvent: ['finish', 'update'],
        class: 'as-countdown-clock',
        child: [
            {
                class: 'as-countdown-clock-text',
                child: [
                    { tag: 'span', class: 'as-countdown-clock-min', child: { text: 0 } },
                    { text: ':' },
                    { tag: 'span', class: 'as-countdown-clock-sec', child: { text: '60' } }
                ]
            },
            {
                class: 'as-countdown-clock-border-wrapper',
                child: {
                    class: 'as-countdown-clock-border'
                }
            }
        ]
    });
};


CountdownClock.prototype._makePolygon = function (end) {
    var n = Math.ceil(Math.max(end / 0.2, 2));
    var fan = Array(n).fill(0).map(function (u, i) {
        var angle = -Math.PI / 2 + end * i / n;
        return [Object(Math_int["numberAutoFixed"])(50 + 60 * Math.cos(angle), 5) + '%', Object(Math_int["numberAutoFixed"])(50 + 60 * Math.sin(angle), 5) + '%'].join(' ')
    });
    fan.push('50% 50%');
    return 'polygon('+fan.join(', ')+')';

};


CountdownClock.prototype._setBorderValue = function (val) {
    if (val >= 1 || !isFinite(val)) {
        this.$border.removeStyle("clip-path");
        return;
    }
    var bound = this.$border.getBoundingClientRect();
    var angle = val * Math.PI * 2;
    this.$border.addStyle("-webkit-clip-path", this._makePolygon(angle));
    this.$border.addStyle("clip-path", this._makePolygon(angle));

};

CountdownClock.prototype._updateBorder = function () {
    this._setBorderValue(this._remainSecond / Math.max(0.001, this._totalSecond));
};

CountdownClock.prototype._updateText = function () {
    if (this._prevText === this.remainSecond) return;
    var remainSecond = this.remainSecond;
    var min = Math.floor(remainSecond / 60);
    var sec = remainSecond % 60;
    this.$sec.innerHTML = (sec < 10 ? "0" : "") + sec;
    this.$min.innerHTML = min;
}

CountdownClock.prototype._tick = function () {
    var now = new Date().getTime();
    var prevSec = this.remainSecond;
    this.remainSecond = Math.max(0, Math.ceil(this.totalSecond - (now - this._startTime) / 1000));
    if (prevSec !== this.remainSecond) {
        this._updateText();
        this.emit('update', { target: this, type: 'update' }, this);
        if (this.remainSecond === 0) {
            clearInterval(this._intvId);
            this._intvId = -1;
            this.emit('finish', { target: this, type: 'finish' }, this);
        }
    }

};

CountdownClock.prototype.start = function () {
    if (this.remainSecond == 0) this.remainSecond = this.totalSecond;
    this._startTime = new Date().getTime() - (this.totalSecond - this.remainSecond) * 1000;
    this.resume();
};

CountdownClock.prototype.resume = function () {
    if (this._intvId > 0) return;
    this._intvId = setInterval(this._tick, 200);
};

CountdownClock.prototype.pause = function () {
    if (this._intvId > 0) {
        clearInterval(this._intvId);
        this._intvId = -1;
    }
};

CountdownClock.prototype.stop = function () {
    this.pause();
    this.remainSecond = 0;
};

CountdownClock.prototype.reset = function () {
    this.remainSecond = this.totalSecond;
    this._startTime = new Date().getTime();
}


CountdownClock.property = {};

CountdownClock.property.totalSecond = {
    set: function (value) {
        if (!(value >= 0)) {
            value = 0;
        }
        this._totalSecond = value;
        this._updateBorder();
    },
    get: function () {
        return this._totalSecond;
    }
};


CountdownClock.property.remainSecond = {
    set: function (value) {
        if (!(value >= 0)) {
            value = 0;
        }
        this._remainSecond = value;
        this._updateBorder();
        this._updateText();
    },
    get: function () {
        return this._remainSecond;
    }
}


ACore["d" /* default */].install(CountdownClock);

/* harmony default export */ var js_CountdownClock = (CountdownClock);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Toast.js
var Toast = __webpack_require__(35);

// CONCATENATED MODULE: ./node_modules/absol-acomp/assets/icon/spinner.tpl
/* harmony default export */ var spinner = ("<svg class=\"as-spinner-ico\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" style=\"margin:auto;background:#fff;display:block;\" width=\"200px\" height=\"200px\" viewBox=\"0 0 100 100\" preserveAspectRatio=\"xMidYMid\">\n    <g><circle cx=\"73.801\" cy=\"68.263\" fill=\"#e15b64\" r=\"4\">\n        <animateTransform attributeName=\"transform\" type=\"rotate\" calcMode=\"spline\" values=\"0 50 50;360 50 50\" times=\"0;1\" keySplines=\"0.5 0 0.5 1\" repeatCount=\"indefinite\" dur=\"1.4925373134328357s\" begin=\"0s\"></animateTransform>\n    </circle><circle cx=\"68.263\" cy=\"73.801\" fill=\"#f47e60\" r=\"4\">\n        <animateTransform attributeName=\"transform\" type=\"rotate\" calcMode=\"spline\" values=\"0 50 50;360 50 50\" times=\"0;1\" keySplines=\"0.5 0 0.5 1\" repeatCount=\"indefinite\" dur=\"1.4925373134328357s\" begin=\"-0.062s\"></animateTransform>\n    </circle><circle cx=\"61.481\" cy=\"77.716\" fill=\"#f8b26a\" r=\"4\">\n        <animateTransform attributeName=\"transform\" type=\"rotate\" calcMode=\"spline\" values=\"0 50 50;360 50 50\" times=\"0;1\" keySplines=\"0.5 0 0.5 1\" repeatCount=\"indefinite\" dur=\"1.4925373134328357s\" begin=\"-0.125s\"></animateTransform>\n    </circle><circle cx=\"53.916\" cy=\"79.743\" fill=\"#abbd81\" r=\"4\">\n        <animateTransform attributeName=\"transform\" type=\"rotate\" calcMode=\"spline\" values=\"0 50 50;360 50 50\" times=\"0;1\" keySplines=\"0.5 0 0.5 1\" repeatCount=\"indefinite\" dur=\"1.4925373134328357s\" begin=\"-0.187s\"></animateTransform>\n    </circle><circle cx=\"46.084\" cy=\"79.743\" fill=\"#849b87\" r=\"4\">\n        <animateTransform attributeName=\"transform\" type=\"rotate\" calcMode=\"spline\" values=\"0 50 50;360 50 50\" times=\"0;1\" keySplines=\"0.5 0 0.5 1\" repeatCount=\"indefinite\" dur=\"1.4925373134328357s\" begin=\"-0.25s\"></animateTransform>\n    </circle><circle cx=\"38.519\" cy=\"77.716\" fill=\"#6492ac\" r=\"4\">\n        <animateTransform attributeName=\"transform\" type=\"rotate\" calcMode=\"spline\" values=\"0 50 50;360 50 50\" times=\"0;1\" keySplines=\"0.5 0 0.5 1\" repeatCount=\"indefinite\" dur=\"1.4925373134328357s\" begin=\"-0.312s\"></animateTransform>\n    </circle><circle cx=\"31.737\" cy=\"73.801\" fill=\"#637cb5\" r=\"4\">\n        <animateTransform attributeName=\"transform\" type=\"rotate\" calcMode=\"spline\" values=\"0 50 50;360 50 50\" times=\"0;1\" keySplines=\"0.5 0 0.5 1\" repeatCount=\"indefinite\" dur=\"1.4925373134328357s\" begin=\"-0.375s\"></animateTransform>\n    </circle><circle cx=\"26.199\" cy=\"68.263\" fill=\"#6a63b6\" r=\"4\">\n        <animateTransform attributeName=\"transform\" type=\"rotate\" calcMode=\"spline\" values=\"0 50 50;360 50 50\" times=\"0;1\" keySplines=\"0.5 0 0.5 1\" repeatCount=\"indefinite\" dur=\"1.4925373134328357s\" begin=\"-0.437s\"></animateTransform>\n    </circle><animateTransform attributeName=\"transform\" type=\"rotate\" calcMode=\"spline\" values=\"0 50 50;0 50 50\" times=\"0;1\" keySplines=\"0.5 0 0.5 1\" repeatCount=\"indefinite\" dur=\"1.4925373134328357s\"></animateTransform></g>\n</svg>");
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/Icons.js


function SpinnerIco(){
    return ACore["d" /* default */]._(spinner);
}

SpinnerIco.tag = 'SpinnerIco'.toLowerCase();

ACore["d" /* default */].install(SpinnerIco);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/emojipickertooltip.css
var emojipickertooltip = __webpack_require__(264);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/EmojiAnims.js
var EmojiAnims = __webpack_require__(33);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/pageindicator.css
var pageindicator = __webpack_require__(266);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/PageIndicator.js



var PageIndicator_ = ACore["d" /* default */]._;
var PageIndicator_$ = ACore["d" /* default */].$;

/***
 * @extends AElement
 * @constructor
 */
function PageIndicator() {
    this._idx = -1;
    this.length = 0;
    this.idx = -1;

}


PageIndicator.tag = 'PageIndicator'.toLowerCase();

PageIndicator.render = function () {
    return PageIndicator_({
        class: 'as-page-indicator',
        child: []
    });
};

PageIndicator.property = {};

PageIndicator.property.length = {
    set: function (value) {
        value = value || 0;
        value = Math.max(0, value);
        while (this.childNodes.length < value) {
            this.addChild(PageIndicator_('button.as-page-indicator-item'));
        }
        while (this.childNodes.length > value) {
            this.removeChild(this.childNodes[this.childNodes.length - 1]);
        }
        this.idx = this._idx;//update
    },
    get: function () {
        return this.childNodes.length;
    }
};

PageIndicator.property.idx = {
    set: function (value) {
        var activeElt = this.childNodes[this._idx];
        if (activeElt) activeElt.removeClass('as-active');
        this._idx = value;
        activeElt = this.childNodes[this._idx];
        if (activeElt) activeElt.addClass('as-active');
    },
    get: function () {
        return this._idx;
    }
};


ACore["d" /* default */].install(PageIndicator);

/* harmony default export */ var js_PageIndicator = (PageIndicator);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/EmojiPickerTooltip.js














var EmojiPickerTooltip_ = ACore["d" /* default */]._;
var EmojiPickerTooltip_$ = ACore["d" /* default */].$;
var isMobile = BrowserDetector["a" /* default */].isMobile;

/***
 * @augments Tooltip
 * @augments AElement
 * @augments Hanger
 * @constructor
 */
function EmojiPickerTooltip() {
    if (isMobile) {
        EmojiPickerTooltip_({
            tag: Hanger["a" /* default */].tag,
            elt: this,
            on: {
                predrag: this.eventHandler.preDragTT,
                dragstart: this.eventHandler.dragStartTT,
                drag: this.eventHandler.dragTT,
                dragend: this.eventHandler.dragEndTT
            }
        })
    }
    this.$iconList = EmojiPickerTooltip_$('.as-emoji-picker-tooltip-icon-list', this);
    this.$leftBtn = EmojiPickerTooltip_$('.as-emoji-picker-tooltip-left-btn', this)
        .on('click', this.eventHandler.clickLeft);
    this.$scroller = EmojiPickerTooltip_$('.as-emoji-picker-tooltip-scroller', this);

    this.$rightBtn = EmojiPickerTooltip_$('.as-emoji-picker-tooltip-right-btn', this)
        .on('click', this.eventHandler.clickRight);
    this.$removeBtn = EmojiPickerTooltip_$('.as-emoji-picker-tooltip-remove-btn', this)
        .on('click', this.eventHandler.clickRemove);
    this.$pageIndicatior = EmojiPickerTooltip_$('pageindicator', this);
    this._iconButtonCache = {};
    this._icons = [];
    this.icons = EmojiPickerTooltip.defaultIcons;
}

EmojiPickerTooltip.tag = 'EmojiPickerTooltip'.toLowerCase();


EmojiPickerTooltip.defaultIcons = [';(', '(sarcastic)', ':O', '(cwl)', '(heart)', '(y)', '(n)', '(rock)', '(facepalm)', '(xd)', ':$', '(waiting)', '(headbang)', '(ghost)', '(clap)', '(punch)', '(ok)', '(angry)'];
EmojiPickerTooltip.emojiDict = EmojiAnims["a" /* default */].reduce(function (ac, cr) {
    ac[cr[0]] = {
        imageFileName: cr[1],
        text: cr[0],
        desc: cr[2]
    };
    return ac;
}, {});

EmojiPickerTooltip.render = function () {
    return EmojiPickerTooltip_({
        tag: 'tooltip',
        extendEvent: ['pick'],
        class: ['as-emoji-picker-tooltip'].concat(isMobile ? ['as-mobile'] : []),
        child: [
            {
                tag: 'button',
                class: 'as-emoji-picker-tooltip-left-btn',
                child: 'span.mdi.mdi-chevron-left'
            },
            {
                class: 'as-emoji-picker-tooltip-scroller',
                child: {
                    class: 'as-emoji-picker-tooltip-icon-list',
                }
            },
            {
                tag: 'button',
                class: 'as-emoji-picker-tooltip-right-btn',
                child: 'span.mdi.mdi-chevron-right'
            },
            {
                tag: 'button',
                attr: {
                    title: 'Remove Emoji'
                },
                class: 'as-emoji-picker-tooltip-remove-btn',
                child: 'span.mdi.mdi-close'
            },
            {
                tag: 'pageindicator',
                class: 'as-emoji-picker-tooltip-page-indicator',
                props: {
                    length: 3,
                    idx: 0
                }
            }
        ]


    }, true);
};

/*var */


EmojiPickerTooltip.prototype._makeIconBtn = function (iconText) {

    var icon = EmojiPickerTooltip.emojiDict[iconText];
    var url = EmojiPicker["a" /* default */].assetRoot + '/anim/x40/' + icon.imageFileName;
    var spriteElt = EmojiPickerTooltip_({
        tag: 'sprite',
        class: 'as-emoji-picker-tooltip-icon',
        attr: {
            title: icon.desc
        },
        props: {
            src: url,
            loop: true,
            fps: 30,
            debug: true
        },
        on: {
            ready: function () {
                this.frames = {
                    type: 'grid',
                    col: 1,
                    row: this.texture.naturalHeight / this.texture.naturalWidth
                };
                this.frameIndex = 0;
            }
        }
    });
    var buttonElt = EmojiPickerTooltip_({
        tag: 'button',
        class: 'as-emoji-picker-tooltip-icon-btn',
        child: spriteElt,
        on: {
            click: this.eventHandler.clickIconBtn.bind(null, icon)
        }
    });

    buttonElt.on('mouseenter', function () {
        spriteElt.play();
    }).on('mouseleave', function () {
        spriteElt.stop();
        spriteElt.frameIndex = 0;
    });

    return buttonElt;

};

EmojiPickerTooltip.prototype._updateIconList = function () {
    this.$iconList.clearChild();
    var iconText;
    for (var i = 0; i < this._icons.length; ++i) {
        iconText = this._icons[i];
        this._iconButtonCache[iconText] = this._iconButtonCache[iconText] || this._makeIconBtn(iconText);
        this.$iconList.addChild(this._iconButtonCache[iconText])
    }
};

EmojiPickerTooltip.property = {};

EmojiPickerTooltip.property.icons = {
    set: function (icons) {
        this._icons = icons || [];
        this._updateIconList();
        this.viewOffset = 0;
        this.$pageIndicatior.length = Math.ceil(this._icons.length / 6);
    },
    get: function () {
        return this._icons;
    }
};

EmojiPickerTooltip.property.viewOffset = {
    set: function (value) {
        this._viewOffset = Math.max(0, Math.min(value, this._icons.length - 6));
        this.$iconList.addStyle('left', -(100 * this._viewOffset / 6) + '%');
        this.$leftBtn.disabled = this._viewOffset === 0;
        this.$rightBtn.disabled = this._viewOffset === this._icons.length - 6;
        this.$pageIndicatior.idx = Math.floor(this._viewOffset / 6);
    },
    get: function () {
        return this._viewOffset;
    }
};

EmojiPickerTooltip.eventHandler = {};

EmojiPickerTooltip.eventHandler.clickLeft = function () {
    this.viewOffset -= 6;
};


EmojiPickerTooltip.eventHandler.clickRight = function () {
    this.viewOffset += 6;
};

EmojiPickerTooltip.eventHandler.clickIconBtn = function (icon) {
    if (this._preventClick) return;
    this.emit('pick', Object.assign({ type: 'pick', icon: icon, target: this }, icon), this);
};

EmojiPickerTooltip.eventHandler.clickRemove = function () {
    this.emit('pick', Object.assign({ type: 'pressremove', icon: "REMOVE", target: this }), this);
};

EmojiPickerTooltip.eventHandler.preDragTT = function (event) {
    var scrollerBound = this.$scroller.getBoundingClientRect();
    var listBound = this.$iconList.getBoundingClientRect();
    this._scrollData = {
        left: listBound.left - scrollerBound.left,
        scrollerWidth: scrollerBound.width,
        newLeft: listBound.left - scrollerBound.left
    };
};

EmojiPickerTooltip.eventHandler.dragStartTT = function () {
    this.addClass('as-scrolling');
    this._preventClick = true;

};

EmojiPickerTooltip.eventHandler.dragTT = function (event) {
    event.preventDefault();
    var dx = event.currentPoint.sub(event.startingPoint).x;
    var newLeft = Math.min(0, Math.max(-this._scrollData.scrollerWidth * 2, this._scrollData.left + dx));
    this._scrollData.newLeft = newLeft;
    this.$iconList.addStyle('left', newLeft + 'px');
};

EmojiPickerTooltip.eventHandler.dragEndTT = function (event) {
    event.preventDefault();
    this.removeClass('as-scrolling');
    var dOffset = (this._scrollData.left - this._scrollData.newLeft) / this._scrollData.scrollerWidth;
    if (dOffset > 0.25) {
        dOffset = 1;
    }
    else if (dOffset < -0.25) {
        dOffset = -1;
    }
    else {
        dOffset = 0;
    }
    this.viewOffset += dOffset * 6;
    setTimeout(function () {
        this._preventClick = false;
    }.bind(this), 5)
};

ACore["d" /* default */].install(EmojiPickerTooltip);

EmojiPickerTooltip._session = Math.random() * 10000000000 >> 0;

function prepare() {
    if (EmojiPickerTooltip.$holder) return;
    EmojiPickerTooltip.$holder = EmojiPickerTooltip_('.absol-tooltip-root-holder')
    EmojiPickerTooltip.$tooltip = EmojiPickerTooltip_('emojipickertooltip.top').addTo(EmojiPickerTooltip.$holder)
        .on('pick', function (event) {
            EmojiPickerTooltip._listener && EmojiPickerTooltip._listener(event.icon);
        });
    /***
     *
     * @type {PositionTracker|undefined}
     */
    EmojiPickerTooltip.$element = undefined;
    EmojiPickerTooltip.$content = undefined;
    EmojiPickerTooltip._orientation = 'auto';
    EmojiPickerTooltip._session = Math.random() * 10000000000 >> 0;
    EmojiPickerTooltip._listener = undefined;
    EmojiPickerTooltip._scrollOutListener = undefined;
    EmojiPickerTooltip.$tooltip.$arrow.updateSize = EmojiPickerTooltip.updatePosition;
}


EmojiPickerTooltip.updatePosition = function () {
    if (!EmojiPickerTooltip.$element) return;
    var outBound = Rectangle["a" /* default */].fromClientRect(Object(Dom["f" /* traceOutBoundingClientRect */])(EmojiPickerTooltip.$element));
    var eBound = Rectangle["a" /* default */].fromClientRect(EmojiPickerTooltip.$element.getBoundingClientRect());
    if (!outBound.isCollapse(eBound, 0)) {
        EmojiPickerTooltip._scrollOutListener && EmojiPickerTooltip._scrollOutListener();
    }
    Object(Tooltip["b" /* updateTooltipPosition */])(EmojiPickerTooltip);
};

EmojiPickerTooltip.updatePosition = EmojiPickerTooltip.updatePosition.bind(EmojiPickerTooltip);


EmojiPickerTooltip.show = function (element, menuListener, orientation) {
    prepare();
    if (EmojiPickerTooltip.$element) {
        EmojiPickerTooltip.$element.stopTrackPosition();
        EmojiPickerTooltip.$element.off('positionchange', EmojiPickerTooltip.updatePosition);
    }
    if (!element.startTrackPosition) {
        EmojiPickerTooltip_({
            tag: PositionTracker["a" /* default */].tag,
            elt: element
        })
    }
    element.startTrackPosition();
    EmojiPickerTooltip.$element = element;
    EmojiPickerTooltip.$element.on('positionchange', EmojiPickerTooltip.updatePosition);
    EmojiPickerTooltip._listener = menuListener;
    EmojiPickerTooltip._session = Math.random() * 10000000000 >> 0;
    EmojiPickerTooltip._orientation = orientation || 'auto';
    EmojiPickerTooltip.$holder.addTo(document.body);
    ResizeSystem["a" /* default */].add(EmojiPickerTooltip.$tooltip.$arrow);
    EmojiPickerTooltip.$tooltip.viewOffset = 0;
    EmojiPickerTooltip.$tooltip.addClass('top')
        .removeClass('left')
        .removeClass('right')
        .removeClass('bottom')
        .removeClass('ne')
        .removeClass('nw')
        .removeClass('auto');
    EmojiPickerTooltip.updatePosition();

    return EmojiPickerTooltip._session;
};


EmojiPickerTooltip.close = function (token) {
    if (EmojiPickerTooltip._session !== token) return;
    if (EmojiPickerTooltip.$element) {
        EmojiPickerTooltip.$element.stopTrackPosition();
        EmojiPickerTooltip.$element.off('positionchange', EmojiPickerTooltip.updatePosition);
    }
    EmojiPickerTooltip.$element = undefined;
    EmojiPickerTooltip._listener = undefined;
    EmojiPickerTooltip._session = Math.random() * 10000000000 >> 0;
    EmojiPickerTooltip.$holder.remove();
};


EmojiPickerTooltip.toggleWhenClick = function (trigger, adaptor) {
    var res = {
        trigger: trigger,
        adaptor: adaptor,
        currentSession: undefined,
    };

    function clickHandler(event) {
        if (res.currentSession === EmojiPickerTooltip._session) return;

        res.currentSession = EmojiPickerTooltip.show(res.adaptor.getFlowedElement ? res.adaptor.getFlowedElement() : trigger,
            res.adaptor.onSelect,
            res.adaptor.orientation || 'auto'
        );
        if (res.adaptor.onOpen) res.adaptor.onOpen();

        var finish = function (event) {
            if (event && (Object(EventEmitter["d" /* hitElement */])(EmojiPickerTooltip.$tooltip.$leftBtn, event) || Object(EventEmitter["d" /* hitElement */])(EmojiPickerTooltip.$tooltip.$rightBtn, event))
                || (event && event.target && event.target.classList.contains('absol-tooltip-content'))) return;
            document.body.removeEventListener('click', finish, false);
            EmojiPickerTooltip.close(res.currentSession);
            if (adaptor.onClose) adaptor.onClose();
            res.currentSession = undefined;
            if (EmojiPickerTooltip._scrollOutListener === EmojiPickerTooltip) EmojiPickerTooltip._scrollOutListener = undefined;
        };
        EmojiPickerTooltip._scrollOutListener = finish;

        setTimeout(function () {
            document.body.addEventListener('click', finish, false);
        }, 10);
    }

    res.remove = function () {
        trigger.removeEventListener('click', clickHandler, false);
        trigger.classList.remove('as-emoji-picker-tooltip-trigger');
    };

    trigger.addEventListener('click', clickHandler, false);
    trigger.classList.add('as-emoji-picker-tooltip-trigger');
    return res;
};

/* harmony default export */ var js_EmojiPickerTooltip = (EmojiPickerTooltip);


// EXTERNAL MODULE: ./node_modules/absol-acomp/css/emojicounter.css
var emojicounter = __webpack_require__(268);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/emojiuserlisttooltip.css
var emojiuserlisttooltip = __webpack_require__(270);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/EmojiUserListTooltip.js






var EmojiUserListTooltip_ = ACore["d" /* default */]._;
var EmojiUserListTooltip_$ = ACore["d" /* default */].$;

/***
 * @augments ToolTip
 * @augments AElement
 * @constructor
 */
function EmojiUserListTooltip() {
    this._text = null;
    this._users = [];
    this.$sprite = EmojiUserListTooltip_({
        tag: 'sprite',
        class: 'as-emoji-user-list-tooltip-emoji',
        props: {
            fps: 30,
            loop: true
        },
        on: {
            ready: function () {
                this.frames = {
                    type: 'grid',
                    col: 1,
                    row: this.texture.naturalHeight / this.texture.naturalWidth
                };
            }
        }
    });
    this.appendChild(this.$sprite);

    this.text = '(heart)'
    this.user = [];
}

EmojiUserListTooltip.tag = 'EmojiUserListTooltip'.toLowerCase();

EmojiUserListTooltip.render = function () {
    return EmojiUserListTooltip_({
        tag: 'tooltip',
        class: 'as-emoji-user-list-tooltip'
    }, true);
};


EmojiUserListTooltip.prototype._updateUsers = function () {
    var thisT = this;
    this.$content.clearChild();
    this._users.forEach(function (user) {
        var elt = EmojiUserListTooltip_({
            class: 'as-emoji-user-list-tooltip-user',
            child: [
                {
                    class: 'as-emoji-user-list-tooltip-avatar',
                    style: {
                        backgroundImage: 'url(' + user.avatar + ')'
                    }
                },
                {
                    class: 'as-emoji-user-list-tooltip-name',
                    child: { text: user.name }
                }
            ]
        });
        if (user.onclick) {
            elt.addClass('as-clickable');
            elt.on('click', user.onclick.bind(user));
        }
        thisT.$content.addChild(elt);
    })
};

EmojiUserListTooltip.prototype.playEmoji = function () {
    this.$sprite.afterReady().then(this.$sprite.play.bind(this.$sprite));
};

EmojiUserListTooltip.prototype.stopEmoji = function () {
    this.$sprite.stop();
};

EmojiUserListTooltip.property = {};

EmojiUserListTooltip.property.users = {
    set: function (users) {
        this._users = users || [];
        this._updateUsers();
    },
    get: function () {
        return this._users;
    }
};

EmojiUserListTooltip.property.text = {
    set: function (value) {
        if (value === this._text) return;
        var icon = js_EmojiPickerTooltip.emojiDict[value];
        if (!value) return;
        var url = EmojiPicker["a" /* default */].assetRoot + '/anim/x60/' + icon.imageFileName;
        this._text = value;
        this.$sprite.src = url;
    },
    get: function () {
        return this._text;
    }
};

ACore["d" /* default */].install(EmojiUserListTooltip);


/* harmony default export */ var js_EmojiUserListTooltip = (EmojiUserListTooltip);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/EmojiCounter.js










var EmojiCounter_$ = ACore["d" /* default */].$;
var EmojiCounter_ = ACore["d" /* default */]._;

var EmojiCounter_isMobile = BrowserDetector["a" /* default */].isMobile;

/***
 * @extends AElement
 * @constructor
 */
function EmojiCounter() {
    /***
     *
     * @type {Sprite}
     */
    this.$sprite = EmojiCounter_$('sprite', this);
    this.$num = EmojiCounter_$('.as-emoji-counter-num', this);
    this.$numText = this.$num.firstChild;
    this._text = '(heart)';
    this.text = this._text;
    this._count = 0;
    this.count = 0;
    this._checkInterval = -1;
    if (EmojiCounter_isMobile) {
        this.attr('tabindex', '1');
        this.on('focus', this.eventHandler.mouseEnter);
    }
    else {
        this.on('mouseenter', this.eventHandler.mouseEnter);
    }
    this._tooltipSession = null;
    this._tooltipFinishTimeout = -1;
}

EmojiCounter.tag = 'EmojiCounter'.toLowerCase();

EmojiCounter.render = function () {
    var icon = js_EmojiPickerTooltip.emojiDict['(heart)'];
    var url = EmojiPicker["a" /* default */].assetRoot + '/anim/x40/' + icon.imageFileName;
    return EmojiCounter_({
            class: 'as-emoji-counter',
            child: [
                {
                    tag: 'sprite',
                    class: 'as-emoji-counter-sprite',
                    props: {
                        src: url,
                        loop: true,
                        fps: 30,
                        debug: true
                    },
                    on: {
                        ready: function () {
                            this.frames = {
                                type: 'grid',
                                col: 1,
                                row: this.texture.naturalHeight / this.texture.naturalWidth
                            };
                            this.frameIndex = 0;
                        }
                    }
                },
                {
                    tag: 'span',
                    class: 'as-emoji-counter-num',
                    child: { text: '0' }
                }
            ]
        }
    );
};


EmojiCounter.property = {};

EmojiCounter.property.text = {
    set: function (value) {
        var icon = js_EmojiPickerTooltip.emojiDict[value];
        if (!icon) return;
        if (this._text === value) return;
        this.$sprite.src = EmojiPicker["a" /* default */].assetRoot + '/anim/x40/' + icon.imageFileName;
        this._text = value;
    },
    get: function () {
        return this._text;
    }
};

EmojiCounter.property.count = {
    set: function (value) {
        this.$numText.data = value + '';
        if (value === 1 && this._count != 1) {
            this.$numText.remove();
        }
        else if (value != 1 && this._count == 1) {
            this.$num.addChild(this.$numText);
        }
        if (value == 0) this.addClass('as-zero');
        else this.removeClass('as-zero');
        this._count = value;
    },
    get: function () {
        return this._count;
    }
}

ACore["d" /* default */].install(EmojiCounter);

EmojiCounter.eventHandler = {};

EmojiCounter.eventHandler.loop = function () {
    if (!this.isDescendantOf(document.body))
        this.eventHandler.finishHover();
    if (this.getBoundingClientRect().width === 0)
        this.eventHandler.finishHover();
};

EmojiCounter.eventHandler.mouseEnter = function () {
    if (this._tooltipFinishTimeout > 0) {
        clearTimeout(this._tooltipFinishTimeout);
    }
    if (this._checkInterval > 0) return;
    this.$sprite.play();
    this._checkInterval = setInterval(this.eventHandler.loop, 1000);
    this.on('mouseleave', this.eventHandler.finishHover);

    if (this.users && this.users.length > 0) {
        EmojiCounter_prepare();
        EmojiCounter._session = Math.random() * 10000000000 >> 0;
        this._tooltipSession = EmojiCounter._session;
        EmojiCounter.$element = this;
        EmojiCounter.$holder.addTo(this);
        EmojiCounter.$tooltip.text = this.text;
        EmojiCounter.$tooltip.users = this.users;
        EmojiCounter.$tooltip.playEmoji();
        Object(Tooltip["b" /* updateTooltipPosition */])(EmojiCounter);
    }
};

EmojiCounter.eventHandler.finishHover = function () {
    if (this._tooltipFinishTimeout > 0) {
        clearTimeout(this._tooltipFinishTimeout);
    }

    this._tooltipFinishTimeout = setTimeout(function () {
        this._tooltipFinishTimeout = -1;
        this.$sprite.stop();
        this.off('mouseleave', this.eventHandler.finishHover);
        if (this._checkInterval > 0) {
            clearInterval(this._checkInterval);
            this._checkInterval = -1;
        }
        if (this._tooltipSession === EmojiCounter._session) {
            EmojiCounter._session = Math.random() * 10000000000 >> 0;
            EmojiCounter.$holder.remove();
            EmojiCounter.$tooltip.stopEmoji();
        }
    }.bind(this), 500);
};

function EmojiCounter_prepare() {
    if (EmojiCounter.$holder) return;
    EmojiCounter.$holder = EmojiCounter_('.absol-tooltip-root-holder');
    EmojiCounter.$tooltip = EmojiCounter_('EmojiUserListTooltip.top'.toLowerCase()).addTo(EmojiCounter.$holder);
    EmojiCounter._scrollOutListener = undefined;
    EmojiCounter._orientation = 'top';
    EmojiCounter._session = Math.random() * 10000000000 >> 0;
    js_EmojiPickerTooltip._listener = undefined;
    EmojiCounter.$element = null;
    EmojiCounter.$tooltip.$arrow.updateSize = EmojiCounter.updatePosition;
}


EmojiCounter.updatePosition = function () {
    if (!EmojiCounter.$element) return;
    var outBound = Rectangle["a" /* default */].fromClientRect(Object(Dom["f" /* traceOutBoundingClientRect */])(EmojiCounter.$element));
    var eBound = Rectangle["a" /* default */].fromClientRect(EmojiCounter.$element.getBoundingClientRect());
    if (!outBound.isCollapse(eBound, 0)) {
        js_EmojiPickerTooltip._scrollOutListener && EmojiCounter._scrollOutListener();
    }
    Object(Tooltip["b" /* updateTooltipPosition */])(EmojiCounter);
};


EmojiCounter.updatePosition = EmojiCounter.updatePosition.bind(EmojiCounter);


/* harmony default export */ var js_EmojiCounter = (EmojiCounter);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/EmojiCounterList.js



var EmojiCounterList_ = ACore["d" /* default */]._;
var EmojiCounterList_$ = ACore["d" /* default */].$;

/***
 * @extends AElement
 * @constructor
 */
function EmojiCounterList() {
    this._counters = [];
    this.counters = [];
}

EmojiCounterList.tag = 'EmojiCounterList'.toLowerCase();

EmojiCounterList.render = function () {
    return EmojiCounterList_({
        class: 'as-emoji-counter-list'
    });
};

EmojiCounterList.iconOrdering = js_EmojiPickerTooltip.defaultIcons.reduce(function (ac, cr, idx) {
    ac[cr] = idx + 1;
    return ac;
}, {});

EmojiCounterList.prototype._updateCounters = function () {
    var newCounters = this._counters;
    var newCounterNameArr = Object.keys(newCounters);
    newCounterNameArr.sort(function (a, b) {
        return (EmojiCounterList.iconOrdering[a] || 1000) - (EmojiCounterList.iconOrdering[b] || 1000);
    })

    var counterElements = Array.prototype.filter.call(this.childNodes, function (e) {
        return e.containsClass && e.containsClass('as-emoji-counter');
    });

    var newCounterElements = [];
    var elt, name;
    var oe, on;
    while (counterElements.length > 0 || newCounterNameArr.length > 0) {
        elt = counterElements[0];
        name = newCounterNameArr[0];

        if (elt && name) {
            if (elt.text === name) {
                newCounterElements.push(elt);
                counterElements.shift();
                newCounterNameArr.shift();
            }
            else {
                oe = EmojiCounterList.iconOrdering[elt.text];
                on = EmojiCounterList.iconOrdering[name];
                if (oe < on) {
                    newCounterElements.push(elt);
                    counterElements.shift();
                }
                else {
                    newCounterElements.push(name);
                    newCounterNameArr.shift();
                }
            }
        }
        else if (elt) {
            newCounterElements.push(elt);
            counterElements.shift();
        }
        else {
            newCounterElements.push(name);
            newCounterNameArr.shift();
        }
    }

    var cElt, prevElt;
    while (newCounterElements.length > 0) {
        cElt = newCounterElements.pop();
        if (typeof cElt === "string") {
            cElt = EmojiCounterList_({
                tag: 'emojicounter',
                props: {
                    text: cElt,
                    users: newCounters[cElt].users || [],
                    count: newCounters[cElt].count
                }
            });
            if (!prevElt) {
                this.addChild(cElt);
            }
            else {
                this.addChildBefore(cElt, prevElt);
            }
            prevElt = cElt;
        }
        else {
            if (newCounters[cElt.text]) {
                cElt.count = newCounters[cElt.text].count;
                cElt.users = newCounters[cElt.text].users || [];
                prevElt = cElt;
            }
            else {
                cElt.remove();
            }
        }

    }

};

EmojiCounterList.property = {};

EmojiCounterList.property.counters = {
    set: function (counters) {
        this._counters = Object.keys(counters || {}).reduce(function (ac, key) {
            var counter = counters[key];
            if (typeof counter === "object") {
                if (counter.count > 0 && js_EmojiPickerTooltip.emojiDict[key]) {
                    ac[key] = counter;
                }
            }
            return ac;
        }, {})
        this._updateCounters();
    },
    get: function () {
        return this._counters;
    }
}

ACore["d" /* default */].install(EmojiCounterList);

/* harmony default export */ var js_EmojiCounterList = (EmojiCounterList);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/rotatedtext.css
var rotatedtext = __webpack_require__(272);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/RotatedText.js




/***
 * @extends AElement
 * @constructor
 */
function RotatedText() {
    this.$attachHook = Object(ACore["a" /* $ */])('attachhook', this);
    this.$attachHook.requestUpdateSize = this.eventHandler.positionChange;
    this.$attachHook.on('attached', this.eventHandler.attached);
    this.$anchor = Object(ACore["a" /* $ */])('.as-rotated-text-anchor', this);
    this.$content = Object(ACore["a" /* $ */])('.as-rotated-text-content', this);
    this.$contentText = this.$content.firstChild;
    this.$trackElts = [];
    this._angle = 0;
    this.angle = 0;
    this.text = '';
    this._trackInterval = -1;

}

RotatedText.tag = 'RotatedText';

RotatedText.render = function () {
    return Object(ACore["c" /* _ */])({
        tag: 'span',
        class: 'as-rotated-text',
        child: [
            'attachhook',
            {
                class:'as-rotated-text-anchor',
                child: {
                    tag: 'span',
                    class: 'as-rotated-text-content',
                    child: { text: '' }
                }
            }
        ]
    });
};

RotatedText.prototype._trackPosition = function () {
    this._cancelTrackPosition();
    var parent = this.parentElement;
    while (parent) {
        parent.addEventListener('scroll', this.eventHandler.positionChange);
        this.$trackElts.push(parent);
        parent = parent.parentElement;
    }
    document.addEventListener('scroll', this.eventHandler.positionChange);
    this.$trackElts.push(document);
    this._trackInterval = setInterval(this.eventHandler.intervalCheck, 3000);
};


RotatedText.prototype._cancelTrackPosition = function () {
    if (this._trackInterval >= 0) {
        clearInterval(this._trackInterval);
        this._trackInterval = -1;
    }
    while (this.$trackElts.length > 0) {
        this.$trackElts.pop().removeEventListener('scroll', this.eventHandler.positionChange);
    }
};


RotatedText.property = {};

RotatedText.property.text = {
    get: function () {
        return this.$contentText.data;
    },
    set: function (value) {
        value = value || '';
        value = value + '';
        this.$contentText.data = value;
    }
};

RotatedText.property.angle = {
    set: function (value) {
        value = value || 0;
        var matched;
        if (typeof value === 'number') {
            this._angle = value;
            this.$content.addStyle('transform', 'rotate(' + value + 'deg)');
        }
        else if (value.match) {
            matched = value.match(/([0-9.+\-e]+)deg/);
            if (matched) {
                value = parseFloat(matched[1]);
                if (isFinite(value)) {
                    this._angle = value;
                    this.$content.addStyle('transform', 'rotate(' + this._angle + 'deg)');
                }
                return;
            }
            matched = value.match(/([0-9.+\-e]+)rad/);
            if (matched) {
                value = parseFloat(matched[1]);
                if (isFinite(value)) {
                    this._angle = value * 180 / Math.PI;
                    this.$content.addStyle('transform', 'rotate(' + this._angle + 'deg)');
                }
            }

        }

    },
    get: function () {
        return this._angle;
    }
};

RotatedText.eventHandler = {};

RotatedText.eventHandler.attached = function () {
    ResizeSystem["a" /* default */].add(this);
    this.eventHandler.positionChange();
    this.$content.addStyle('transform-origin',Math.round(0.3 * this.$content.getFontSize())  + 'px 50%');
    this._trackPosition();
};

RotatedText.eventHandler.detached = function () {
    this._cancelTrackPosition();
};

RotatedText.eventHandler.intervalCheck = function () {
    if (!this.isDescendantOf(document.body)) {
        this.eventHandler.detached();
    }
}

RotatedText.eventHandler.positionChange = function () {
    var bound = this.getBoundingClientRect();
    this.$anchor.addStyle({
        top: Math.round(bound.top) + 'px',
        left: Math.round(bound.left) + 'px'
    });
};

ACore["d" /* default */].install(RotatedText);

/* harmony default export */ var js_RotatedText = (RotatedText);



// EXTERNAL MODULE: ./node_modules/absol-acomp/css/verticaltreediagram.css
var verticaltreediagram = __webpack_require__(274);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/VerticalTreeDiagram.js





function VerticalTreeDiagramNode() {
    this.$childCtn = Object(ACore["a" /* $ */])('.as-vertical-tree-diagram-child-ctn', this);
    this.$name = Object(ACore["a" /* $ */])('.as-vertical-tree-diagram-node-name', this);
    OOP["a" /* default */].drillProperty(this, this.$name.firstChild, 'name', 'data');
    this.name = "UndefinedNodeName";
}

VerticalTreeDiagramNode.tag = 'VerticalTreeDiagramNode'.toLowerCase();


VerticalTreeDiagramNode.render = function () {
    return Object(ACore["c" /* _ */])({
        class: 'as-vertical-tree-diagram-node',
        child: [
            {
                class: 'as-vertical-tree-diagram-node-name-ctn',
                child: {
                    class: 'as-vertical-tree-diagram-node-name',
                    child: { text: "" }
                }
            },
            {
                class: 'as-vertical-tree-diagram-child-ctn'
            }
        ]
    });
};

['addChild', 'removeChild', 'clearChild', 'addChildBefore', 'addChildAfter',
    'findChildBefore', 'findChildAfter'
].forEach(function (name) {
    VerticalTreeDiagramNode.prototype[name] = function () {
        this.$childCtn[name].apply(this.$childCtn, arguments);
        if (this.$childCtn.childNodes.length > 0) {
            this.addClass('as-has-child');
            if (this.$childCtn.childNodes.length === 1) {
                this.addClass('as-has-1-child');
            }
            else {
                this.removeClass('as-has-1-child');
            }
        }
        else {
            this.removeClass('as-has-child');
            this.removeClass('as-has-1-child');
        }
    };
});


function VerticalTreeDiagram(data) {
    this.data = data || {};
}

VerticalTreeDiagram.tag = 'VerticalTreeDiagram'.toLowerCase();

VerticalTreeDiagram.render = function () {
    return Object(ACore["c" /* _ */])(VerticalTreeDiagramNode.tag, true);
}

VerticalTreeDiagram.property = {};

VerticalTreeDiagram.property.data = {
    set: function (data) {
        data = data || {};
        this._data = data;

        function makeNode(nodeData) {
            return Object(ACore["c" /* _ */])({
                tag: VerticalTreeDiagramNode.tag,
                props: {
                    name: nodeData.name
                },
                child: (nodeData.child && nodeData.child.length > 0 && nodeData.child.map(makeNode)) || []
            });
        }

        this.name = data.name + '';
        this.clearChild();
        if (data.child)
            this.addChild(data.child.map(makeNode));
    },
    get: function () {
        return this._data;
    }
};

ACore["d" /* default */].install(VerticalTreeDiagramNode);
ACore["d" /* default */].install(VerticalTreeDiagram);

/* harmony default export */ var js_VerticalTreeDiagram = (VerticalTreeDiagram);


// EXTERNAL MODULE: ./node_modules/absol-acomp/css/tokenfield.css
var tokenfield = __webpack_require__(276);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TokenField.js










/***
 * @extends AElement
 * @constructor
 */
function TokenField() {
    this.on('click', this.eventHandler.click);
    this.$input = Object(ACore["a" /* $ */])('input', this)
        .on('keydown', this.eventHandler.inputKeyDown)
        .on('focus', this.eventHandler.inputInteract)
        .on('click', this.eventHandler.inputInteract)
        .on('keydown', this.eventHandler.inputInteract);
    this.$attachhook = Object(ACore["a" /* $ */])('attachhook', this)
        .on('attached', function () {
            ResizeSystem["a" /* default */].add(this);
            this.requestUpdateSize();
        });
    this.$attachhook.requestUpdateSize = this.updateSize.bind(this);


    /***
     *
     * @type {SelectListBox}
     */
    this.$selectlistBox = Object(ACore["c" /* _ */])({
        tag: 'selectlistbox',
        props: {
            anchor: [1, 6, 2, 5]
        },
        on: {
            preupdateposition: this.eventHandler.preUpdateListPosition
        }
    });
    this.$selectlistBox.on('pressitem', this.eventHandler.selectListBoxPressItem);
    this.$selectlistBox.followTarget = this;

    this.autocomplete = null;
    this.separator = ' ';
    this.placeHolder = '';
}

TokenField.tag = 'TokenField'.toLowerCase();

TokenField.render = function () {
    return Object(ACore["c" /* _ */])({
        class: 'as-token-field',
        extendEvent: ['change'],
        child: [
            {
                tag: 'input',
                class: 'as-token-field-input-text',
                attr: { type: 'text', tabindex: '1' }
            },
            'attachhook'
        ]
    });
};

TokenField.prototype._makeItem = function (text) {
    var itemElt = Object(ACore["c" /* _ */])({
        tag: SelectBoxItem["a" /* default */].tag,
        class: 'as-token-field-item',
        attr: { tabindex: 1 },
        props: {
            data: {
                text: text,
                value: text
            }
        }
    });

    itemElt.on({
        keydown: this.eventHandler.itemKeyDown.bind(this, itemElt),
        close: this.eventHandler.itemClose.bind(this, itemElt),
        focus: this.eventHandler.itemFocus.bind(this, itemElt)
    });

    return itemElt;
};

TokenField.prototype._appendItem = function (itemElt) {
    this.addChildBefore(itemElt, this.$input);
};


TokenField.prototype._updateInputWidth = function () {
    var lastItem = this.findChildBefore(this.$input);
    if (lastItem) {
        var lastItemBound = lastItem.getBoundingClientRect();
        var bound = this.getBoundingClientRect();
        var aRight = bound.right - 4 - lastItemBound.right;
        if (aRight > 60) {
            this.$input.addStyle('width', aRight + 'px');
        }
        else {
            this.$input.addStyle('width', '100%');
        }
    }
    else {
        this.$input.addStyle('width', '100%');
    }
};

TokenField.prototype._isSeparatorKey = function (key) {
    if (key === 'Enter') return true;
    if (this.separator === ' ') return key === ' ';
    if (this.separator === '\n') return key === 'Enter';
    if (this.separator === '\t') return key === 'Tab';
    return key === this.separator;
};

TokenField.prototype.updateSize = function () {
    this._updateInputWidth();
};

TokenField.prototype._notifyChange = function (data) {
    this.emit('change', Object.assign({ type: 'change', target: this }, data), this);
};

TokenField.prototype._searchInList = function () {
    if (this._searchTimeout > 0) {
        clearTimeout(this._searchTimeout);
    }
    this._searchTimeout = setTimeout(function () {
        var text = this.$input.value;
        if (this.$selectlistBox.isDescendantOf(document.body)) {
            this.$selectlistBox.$searchInput.value = text;
            this.$selectlistBox.eventHandler.searchModify();
            if (this.$selectlistBox._displayItems.length === 0) {
                this.$selectlistBox.addStyle('visibility', 'hidden');
            }
            else {
                this.$selectlistBox.removeStyle('visibility');
            }
        }
    }.bind(this), 100);
}

TokenField.eventHandler = {};
TokenField.property = {};


TokenField.property.separator = {
    set: function (value) {
        if (typeof value !== "string") value = ' ';
        this._separator = value;
    },
    get: function () {
        return this._separator;
    }
};

TokenField.property.placeHolder = {
    set: function (value) {
        this.$input.attr('placeholder', value || '');
    },
    get: function () {
        return this.$input.attr('placeholder');
    }
};

TokenField.property.items = {
    set: function (items) {
        items = items || [];
        while (this.firstChild && this.firstChild && this.firstChild.containsClass('as-token-field-item')) {
            this.firstChild.remove();
        }
        for (var i = 0; i < items.length; ++i) {
            this._appendItem(this._makeItem(items[i]));
        }
    },
    get: function () {
        return Array.prototype.slice.call(this.childNodes).filter(function (elt) {
            return elt.containsClass && elt.containsClass('as-token-field-item');
        }).map(function (elt) {
            return elt.data.value;
        });
    }
};

TokenField.property.autocomplete = {
    set: function (value) {
        this._autocomplete = value || null;
        if (this._autocomplete) {
            this.$selectlistBox.items = this._autocomplete.map(function (it) {
                return {
                    value: it + '',
                    text: it + ''
                };
            });
        }
        else {
            this.$selectlistBox.items = [];
        }
    },
    get: function () {
        return this._autocomplete;
    }
}


TokenField.eventHandler.inputKeyDown = function (event) {
    if (this._isSeparatorKey(event.key)) {
        var text = this.$input.value;
        if (text.length > 0) {
            this.$input.value = '';
            var newItem = this._makeItem(text);
            this._appendItem(newItem);
            this.updateSize();
            this._notifyChange({ action: 'add', item: text, itemElt: newItem });
            this.eventHandler.inputOut();
        }
        event.preventDefault();
    }
    else if (event.key.startsWith('Arrow') || event.key === 'Backspace') {
        if (this.$input.selectionStart === 0 && this.$input.selectionEnd === 0) {
            if (event.key === 'ArrowLeft' || event.key === 'Backspace') {
                event.preventDefault();
                var prevChild = this.findChildBefore(this.$input);
                if (prevChild) prevChild.focus();
            }
            else if (event.key === 'ArrowUp') {
                var item, itemBound;
                var inputBound = this.$input.getBoundingClientRect();
                var anchorPos = new Vec2["a" /* default */](inputBound.left + 5, inputBound.top + inputBound.height / 2);
                var minDis = Infinity;
                var dis;
                var aboveItem;
                for (var i = 0; i < this.childNodes.length; ++i) {
                    item = this.childNodes[i];
                    if (item.containsClass && item.containsClass('as-token-field-item')) {
                        itemBound = item.getBoundingClientRect();
                        if (itemBound.bottom < inputBound.top) {
                            dis = new Vec2["a" /* default */](itemBound.left + itemBound.width / 2, itemBound.top + itemBound.height / 2)
                                .sub(anchorPos)
                                .abs();
                            if (dis < minDis) {
                                minDis = dis
                                aboveItem = item;
                            }
                        }
                    }
                }
                if (aboveItem) {
                    aboveItem.focus();
                    event.preventDefault();
                }
            }
        }
        else {
            this._searchInList();
        }
    }
    else {
        this._searchInList();
    }
};


TokenField.eventHandler.inputInteract = function (event) {
    var lt = this._lastInteractTime;
    this._lastInteractTime = new Date().getTime();
    if (lt && (this._lastInteractTime - lt < 100)) {
        return;
    }
    if (this.$selectlistBox.isDescendantOf(document.body)) return;
    this.$selectlistBox.addTo(document.body);
    this.$selectlistBox.domSignal.$attachhook.emit('attached');
    this._searchInList();
    var bound = this.getBoundingClientRect();
    this.$selectlistBox.addStyle('min-width', bound.width + 'px');
    this.$selectlistBox.refollow();
    this.$selectlistBox.updatePosition();

    setTimeout(document.addEventListener.bind(document, 'click', this.eventHandler.inputOut), 100)
};

TokenField.eventHandler.inputOut = function (event) {
    if (event && (Object(EventEmitter["d" /* hitElement */])(this.$selectlistBox, event) || Object(EventEmitter["d" /* hitElement */])(this.$input, event))) return;
    document.removeEventListener('click', this.eventHandler.inputOut);
    this.$selectlistBox.remove();
    this._lastInteractTime = new Date().getTime();
};


TokenField.eventHandler.itemKeyDown = function (itemElt, event) {
    var nextElt;
    if (event.key === 'Delete' || event.key === 'Backspace') {
        if (event.key === 'Delete') {
            nextElt = this.findChildAfter(itemElt);
        }
        else {
            nextElt = this.findChildBefore(itemElt) || this.$input;
        }

        itemElt.remove();
        this._notifyChange({ item: itemElt.data.value, action: 'remove', itemElt: itemElt });
        if (nextElt === this.$input) {
            this.$input.focus();
            Object(Text["setCaretPosition"])(this.$input, 0);
        }
        else {
            nextElt.focus();
        }
    }
    else if (event.key === 'ArrowLeft') {
        nextElt = this.findChildBefore(itemElt);
        if (nextElt) nextElt.focus();
    }
    else if (event.key === 'ArrowRight') {
        nextElt = this.findChildAfter(itemElt);
        if (nextElt === this.$input) {
            this.$input.focus();
            Object(Text["setCaretPosition"])(this.$input, 0);
        }
        else {
            nextElt.focus();
        }
    }
    else if (event.key === 'ArrowUp' || event.key === 'ArrowDown') {
        var currentItemBound = itemElt.getBoundingClientRect();
        var center = new Vec2["a" /* default */](currentItemBound.left + currentItemBound.width / 2, currentItemBound.top + currentItemBound.height / 2);
        var childElt, itemBound, dis;
        var minDis = Infinity;
        var i;
        if (event.key === 'ArrowUp') {
            for (i = 0; i < this.childNodes.length; ++i) {
                childElt = this.childNodes[i];
                if (childElt.containsClass && childElt.containsClass('as-token-field-item') || childElt === this.$input) {
                    itemBound = childElt.getBoundingClientRect();
                    if (itemBound.bottom < currentItemBound.top) {
                        dis = new Vec2["a" /* default */](itemBound.left + itemBound.width / 2, itemBound.top + itemBound.height / 2)
                            .sub(center)
                            .abs();
                        if (dis < minDis) {
                            minDis = dis
                            nextElt = childElt;
                        }
                    }
                }
            }
        }
        else {
            for (i = 0; i < this.childNodes.length; ++i) {
                childElt = this.childNodes[i];
                if (childElt.containsClass && childElt.containsClass('as-token-field-item') || childElt === this.$input) {
                    itemBound = childElt.getBoundingClientRect();
                    if (itemBound.top > currentItemBound.bottom) {
                        dis = new Vec2["a" /* default */](itemBound.left + itemBound.width / 2, itemBound.top + itemBound.height / 2)
                            .sub(center)
                            .abs();
                        if (dis < minDis) {
                            minDis = dis
                            nextElt = childElt;
                        }
                    }
                }
            }
        }
        if (nextElt) {
            nextElt.focus();
        }
    }
};

TokenField.eventHandler.itemFocus = function (itemElt) {
    this.eventHandler.inputOut();
};


TokenField.eventHandler.itemClose = function (itemElt) {
    itemElt.remove();
    this._notifyChange({ action: 'remove', item: itemElt.data.value, itemElt: itemElt });
    this.$input.focus();
};

TokenField.eventHandler.click = function (event) {
    if (event.target === this)
        this.$input.focus();
};

TokenField.eventHandler.preUpdateListPosition = function () {
    var bound = this.getBoundingClientRect();
    var screenSize = Object(Dom["d" /* getScreenSize */])();
    var availableTop = bound.top - 5;
    var availableBot = screenSize.height - 5 - bound.bottom;
    this.$selectlistBox.addStyle('--max-height', Math.max(availableBot, availableTop) + 'px');
    var outBound = Object(Dom["f" /* traceOutBoundingClientRect */])(this);
    if (bound.bottom < outBound.top || bound.top > outBound.bottom || bound.right < outBound.left || bound.left > outBound.right) {
        // this.isFocus = false;
        //
    }
};

TokenField.eventHandler.selectListBoxPressItem = function (event) {
    var text = event.data.value;
    var newItem = this._makeItem(text);
    this._appendItem(newItem);
    this.updateSize();
    this._notifyChange({ action: 'add', item: text, itemElt: newItem });
    this.eventHandler.inputOut();
    this.$input.focus();
    this.$input.value = '';
}

ACore["d" /* default */].install(TokenField);

/* harmony default export */ var js_TokenField = (TokenField);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/dvexptree.css
var dvexptree = __webpack_require__(278);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/DVExpTree.js





/***
 * @extends ExpTree
 * @constructor
 */
function DVExpTree() {
    this.injectInput();

}

DVExpTree.tag = 'DVExpTree'.toLowerCase();

DVExpTree.render = function () {
    return Object(ACore["c" /* _ */])({
        tag: ExpTree["c" /* default */].tag,
        extendEvent: ['radiochange', 'indexclick'],
        class: 'as-dv-exp-tree'
    }, true);
};

DVExpTree.prototype.injectInput = function () {
    this.$radio = Object(ACore["c" /* _ */])({
        tag: 'radiobutton',
        on: {
            change: this.eventHandler.radioChange
        }
    });
    this.$node.insertBefore(this.$radio, this.$node.$extIcon);
    this.$index = Object(ACore["c" /* _ */])({
        tag: 'span',
        class: 'as-dv-exp-tree-index',
        on: {
            click: this.eventHandler.indexClick
        }
    });
    this.$node.insertBefore(this.$index, this.$node.$desc);
    this.$node.on('click', this.eventHandler.clickInNode);
};


DVExpTree.property = {};

DVExpTree.property.radioName = {
    enumerable: true,
    set: function (value) {
        if (!value) {
            this.removeClass('as-has-radio');
            this.$radio.name = undefined;
        }
        else {
            this.addClass('as-has-radio');
            this.$radio.name = value + '';
        }
    },
    get: function () {
        return this.$radio.name;
    }
};

DVExpTree.property.radioValue = {
    enumerable: true,
    set: function (value) {
        this.$radio.value = value;
    },
    get: function () {
        return this.$radio.value;
    }
};

DVExpTree.property.radioChecked = {
    enumerable: true,
    set: function (value) {
        this.$radio.checked = value;
    },
    get: function () {
        return this.$radio.checked;
    }
};


DVExpTree.property.hasIndex = {
    enumerable: true,
    set: function (value) {
        if (value)
            this.addClass('as-has-index-input');
        else
            this.removeClass('as-has-index-input');
    },
    get: function () {
        return this.containsClass('as-has-index-input');
    }
};

DVExpTree.property.indexValue = {
    enumerable: true,
    set: function (value) {
        this.$index.innerHTML = value;
    },
    get: function () {
        return this.$index.innerHTML;
    }
};

DVExpTree.eventHandler = {};

DVExpTree.eventHandler.radioChange = function (event) {
    this.emit('radiochange', Object.assign({}, event, { target: this, radioElt: this.$radio }), this);
};

DVExpTree.eventHandler.indexClick = function (event) {
    this.emit('indexclick', Object.assign({}, event, { target: this, indexInput: this.$index }), this);
};


DVExpTree.eventHandler.clickInNode = function (event) {
    if (Object(EventEmitter["d" /* hitElement */])(this.$index, event) || Object(EventEmitter["d" /* hitElement */])(this.$radio, event) || Object(EventEmitter["d" /* hitElement */])(this.$node.$toggleIcon, event)) return;
    if (Object(EventEmitter["d" /* hitElement */])(this.$node, event) && this.radioName)
        this.$radio.click();
};

ACore["d" /* default */].install(DVExpTree);


/* harmony default export */ var js_DVExpTree = (DVExpTree);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/checklistitem.css
var checklistitem = __webpack_require__(280);

// EXTERNAL MODULE: ./node_modules/absol/src/AppPattern/Ref.js
var Ref = __webpack_require__(75);

// CONCATENATED MODULE: ./node_modules/absol/src/AppPattern/Attributes.js
/***
 *
 * @param {Object} node
 * @constructor
 */


/***
 * @typedef {{get?:function, set?: function, descriptor?: Object|function, export?: function}} AttributeHandler
 */


/***
 *
 * @param {Object} node
 * @constructor
 */
function Attributes(node) {
    Object.defineProperty(this, '$$node', {
        enumerable: false,
        configurable: true,
        writable: false,
        value: node
    })
    Object.defineProperty(this, '_definedProperties', {
        enumerable: false,
        writable: false,
        value: {}
    });

    Object.defineProperty(this, '_definedComputedHandlers', {
        enumerable: false,
        writable: false,
        value: {}
    });
}

Object.defineProperty(Attributes.prototype, 'loadAttributeHandlers', {
    enumerable: false,
    configurable: true,
    writable: false,
    value: function (newHandlers) {
        var self = this;
        var definedHandlers = this._definedProperties;
        var definedComputedHandlers = this._definedComputedHandlers;
        Object.keys(this._definedProperties).forEach(function (key) {
            if (!newHandlers[key]) {
                delete definedHandlers[key];
                delete definedComputedHandlers[key];
                delete self[key];

            }
        });
        Object.keys(newHandlers).forEach(function (key) {
            if (definedHandlers[key] !== newHandlers[key]) {
                self.defineProperty(key, newHandlers[key]);
            }
        });
    }
});

Object.defineProperty(Attributes.prototype, 'defineProperty', {
    enumerable: false,
    configurable: true,
    writable: false,
    value: function (name, handler) {
        var self = this;
        this._definedProperties[name] = handler;
        var hadValue = !!(name in this);
        var privateValueRef = new Ref["a" /* default */](this[name]);
        var objectDescriptor = {
            enumerable: true, configurable: true,
            set: function (value) {
                if (handler.set)
                    privateValueRef.set(handler.set.apply(self.$$node, Array.prototype.slice.call(arguments).concat([privateValueRef])));
                else privateValueRef.set(value);
            },
            get: function () {
                if (handler.get)
                    return handler.get.apply(self.$$node, Array.prototype.slice.call(arguments).concat([privateValueRef]));
                else
                    return privateValueRef.get();
            }
        };


        Object.defineProperty(this, name, objectDescriptor);
        this._definedComputedHandlers[name] = objectDescriptor;
        objectDescriptor.ref = privateValueRef;
        if (hadValue) this[name] = privateValueRef.get();
    }
});

Object.defineProperty(Attributes.prototype, 'getProperty', {
    enumerable: false,
    configurable: true,
    writable: false,
    value: function (name) {
        var args = Array.prototype.slice.call(arguments, 1);
        var handler = this._definedComputedHandlers[name];
        if (handler) {
            return handler.get.apply(this, args);
        }
        else return this[name];
    }
});

Object.defineProperty(Attributes.prototype, 'setProperty', {
    enumerable: false,
    configurable: true,
    writable: false,
    value: function (name, value) {
        var args = Array.prototype.slice.call(arguments, 1);
        var handler = this._definedComputedHandlers[name];
        if (handler) {
            return handler.set.apply(this, args);
        }
        else
            this[name] = value;
    }
});


Object.defineProperty(Attributes.prototype, 'export', {
    enumerable: false,
    configurable: true,
    value: function () {
        var self = this;
        return Object.keys(this).reduce(function (ac, key) {
            var value;
            var handler = self._definedProperties[key];
            var computedHandler = self._definedComputedHandlers[key];
            var exporter = handler && handler.export;
            if (exporter) {
                value = exporter.call(self.$$node, computedHandler.ref);
            }
            else {
                value = self[key]
            }
            if (value !== undefined) ac[key] = value;
            return ac;
        }, {});
    }
});


Object.defineProperty(Attributes.prototype, 'getPropertyDescriptor', {
    enumerable: false,
    configurable: true,
    writable: false,
    value: function (name) {
        var handler = this._definedProperties[name];
        if (handler && (typeof handler.descriptor === "function")) return handler.descriptor.call(this.$$node);
        var value = this[name];
        return (handler && handler.descriptor) || { type: typeof value };
    }
});

/* harmony default export */ var AppPattern_Attributes = (Attributes);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/SelectListItem.js
var SelectListItem = __webpack_require__(46);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/CheckListItem.js










function measureMaxCheckboxTextWidth(items) {
    var maxTextWidth = 0;
    var maxText = 0;
    var maxEst = 0;
    var maxLv = 0;
    var est;
    var text;
    var item;
    for (var i = 0; i < items.length; ++i) {
        item = items[i];
        if (item.text) {
            text = item.text;
            est = Object(utils["estimateWidth14"])(text) + 14 * 1.25 * (item.level || 0);
            if (est > maxEst) {
                maxEst = est;
                maxText = text;
                maxLv = item.level || 0;
            }
        }
    }
    if (maxText)
        maxTextWidth = 18 + 14 * (1.25 + 0.35) * maxLv + Object(utils["measureText"])(maxText, '14px Arial, Helvetica, sans-serif').width + 14;//padding left, right 7px, checkbox 18px
    return maxTextWidth;
}

function measureCheckListHeight(items) {
    var border = 0;
    var n = items.length - 1;
    return items.length * 25 + border;
}


function measureCheckListSize(items) {
    var descWidth = Object(SelectList["c" /* measureMaxDescriptionWidth */])(items);
    var textWidth = measureMaxCheckboxTextWidth(items);
    var width = textWidth;
    if (descWidth > 0) {
        width += descWidth + 14;
    }
    var height = measureCheckListHeight(items);
    return {
        width: width,
        height: height,
        descWidth: descWidth,
        textWidth: textWidth
    };
}


/***
 * @extends SelectListItem
 * @constructor
 */
function CheckListItem() {
    this.$text = Object(ACore["a" /* $ */])('span.absol-selectlist-item-text', this);
    this.$textValue = this.$text.childNodes[0];
    this.$descCtn = Object(ACore["a" /* $ */])('.absol-selectlist-item-desc-container', this);
    this.$desc = Object(ACore["a" /* $ */])('span.absol-selectlist-item-desc', this.$descCtn);
    this.$descValue = this.$desc.childNodes[0];
    this.$checkbox = Object(ACore["a" /* $ */])(CheckboxButton["a" /* default */].tag, this)
        .on('change', this.eventHandler.checkboxChange);
    this._viewData = new AppPattern_Attributes(this);
    this._viewData.loadAttributeHandlers(this.viewHandlers);
    OOP["a" /* default */].drillProperty(this, this._viewData, 'extendClasses');
    OOP["a" /* default */].drillProperty(this, this._viewData, 'extendStyle');
    this.level = 0;
    this.selected = false;
    this.on('click', this.eventHandler.clickText);
}

CheckListItem.tag = 'CheckListItem'.toLowerCase();

CheckListItem.render = function () {
    return Object(ACore["c" /* _ */])({
        extendEvent: ['select'],
        class: ['as-check-list-item', "absol-selectlist-item"],
        child: [
            {
                tag: CheckboxButton["a" /* default */].tag,
                class: 'as-check-list-item-checkbox'
            },
            {
                tag: 'span',
                class: 'absol-selectlist-item-text',
                child: {text: ''}
            },
            {
                class: 'absol-selectlist-item-desc-container',
                child: {
                    tag: 'span',
                    class: 'absol-selectlist-item-desc',
                    child: {text: ''}
                }
            }
        ]
    });
};


CheckListItem.property = {
    text: SelectListItem["a" /* default */].property.text,
    value: SelectListItem["a" /* default */].property.value
};

CheckListItem.property.data = {
    set: function (value) {
        this._data = value;
        var viewData = {};
        if (typeof value === 'string') {
            viewData.text = value
        } else {
            Object.assign(viewData, value);
        }
        Object.assign(this._viewData, viewData);
    },
    get: function () {
        return this._data;
    }
};

CheckListItem.property.selected = {
    set: function (value) {
        this.$checkbox.checked = !!value;
    },
    get: function () {
        return this.$checkbox.checked;
    }
};

CheckListItem.property.level = {
    set: function (value) {
        value = value || 0;
        this._level = value;
        this.$checkbox.addStyle('margin-left', value * 1.25 + 'em');
    },
    get: function () {
        return this._level;
    }
};


CheckListItem.prototype.viewHandlers = {};
CheckListItem.prototype.viewHandlers.text = {
    set: function (value) {
        this.$textValue.data = value;
    },
    get: function () {
        return this.$textValue.data;
    }
};

CheckListItem.prototype.viewHandlers.desc = {
    set: function (value) {
        this.$descValue.data = value;
    },
    get: function () {
        return this.$descValue.data;
    }
};

CheckListItem.prototype.viewHandlers.extendClasses = {
    set: function (value, ref) {
        var prevVal = ref.get() || [];
        var i;
        for (i = 0; i < prevVal.length; ++i) {
            this.removeClass(prevVal[i]);
        }

        var newVal = [];
        if (typeof value == 'string') value = value.trim().split(/\s+/);
        value = value || [];
        for (i = 0; i < value.length; ++i) {
            newVal.push(value[i]);
            this.addClass(value[i]);
        }
        return newVal;
    }
};

CheckListItem.prototype.viewHandlers.extendStyle = {
    /***
     *
     * @param value
     * @param {Ref} ref
     */
    set: function (value, ref) {
        this.removeStyle(ref.get() || {});
        this._extendStyle = Object.assign({}, value || {});
        this.addStyle(this._extendStyle);
    },
    get: function () {
        return this._extendClasses;
    }
};


CheckListItem.eventHandler = {};

CheckListItem.eventHandler.clickText = function (event) {
    if (Object(EventEmitter["d" /* hitElement */])(this.$checkbox, event)) return;
    this.$checkbox.checked = !this.$checkbox.checked;
    this.emit('select', {
        target: this,
        type: 'select',
        originalEvent: event.originalEvent || event.originEvent || event,
        selected: this.selected
    });
};

CheckListItem.eventHandler.checkboxChange = function (event) {
    this.emit('select', {
        target: this,
        type: 'select',
        originalEvent: event.originalEvent || event.originEvent || event,
        selected: this.selected
    });
};

ACore["d" /* default */].install(CheckListItem);

/* harmony default export */ var js_CheckListItem = (CheckListItem);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/checklistbox.css
var checklistbox = __webpack_require__(282);

// EXTERNAL MODULE: ./node_modules/absol/src/Code/noop.js
var noop = __webpack_require__(13);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/CheckListBox.js








var itemPool = [];


function makeItem() {
    return Object(ACore["c" /* _ */])({
        tag: js_CheckListItem,
        on: {
            select: function (event) {
                this.$parent.eventHandler.itemSelect(this, event)
            }
        }
    });
}

function requireItem($parent) {
    var item;
    if (itemPool.length > 0) {
        item = itemPool.pop();
    } else {
        item = makeItem();
    }
    item.$parent = $parent;
    return item;
}

function releaseItem(item) {
    item.$parent = null;
    item.selected = false;
    itemPool.push(item);
}


/***
 * @extends SelectListBox
 * @constructor
 */
function CheckListBox() {
    this._initDomHook();
    this._initControl();
    this._initScroller();
    this._initFooter();
    this._initProperty();
    this.domSignal.on('viewListAtValue', this.viewListAtValue.bind(this));
}

CheckListBox.tag = 'CheckListBox'.toLowerCase();

CheckListBox.render = function () {
    return Object(ACore["c" /* _ */])({
        tag: Follower["a" /* default */].tag,
        extendEvent: ['change', 'cancel'],
        attr: {
            tabindex: 0
        },
        class: ['as-select-list-box', 'as-check-list-box'],
        child: [
            {
                class: 'as-select-list-box-search-ctn',
                child: 'searchtextinput'
            },
            {
                class: ['as-bscroller', 'as-select-list-box-scroller'],
                child: [
                    {
                        class: 'as-select-list-box-content',
                        child: Array(this.prototype.preLoadN).fill('.as-select-list-box-page')
                    }
                ]
            },
            {
                class: 'as-select-list-box-footer',
                child: [
                    {
                        tag: 'checkbox',
                        class: 'as-select-list-box-check-all',
                        props: {
                            checked: false,
                            text: 'Check All'
                        }
                    },
                    {
                        class: 'as-select-list-box-footer-right',
                        child: {
                            tag: 'a',
                            class: 'as-select-list-box-cancel-btn',
                            child: {text: 'Cancel'}
                        }
                    }
                ]
            },
            'attachhook.as-dom-signal'
        ]
    });
};

Object.assign(CheckListBox.prototype, SelectListBox["b" /* default */].prototype);
CheckListBox.property = Object.assign({}, SelectListBox["b" /* default */].property);
CheckListBox.eventHandler = Object.assign({}, SelectListBox["b" /* default */].eventHandler);
CheckListBox.prototype.itemHeight = 25;
CheckListBox.prototype.footerMinWidth = 110;


CheckListBox.prototype._initFooter = function () {
    this.$checkAll = Object(ACore["a" /* $ */])('.as-select-list-box-check-all', this)
        .on('change', this.eventHandler.checkAllChange);
    this.$cancelBtn = Object(ACore["a" /* $ */])('.as-select-list-box-cancel-btn', this)
        .on('click', this.eventHandler.clickCancelBtn);
};


CheckListBox.prototype._requireItem = function (pageElt, n) {
    var itemElt;
    while (pageElt.childNodes.length > n) {
        itemElt = pageElt.lastChild;
        itemElt.selfRemove();
        releaseItem(itemElt);
    }
    while (pageElt.childNodes.length < n) {
        itemElt = requireItem(this);
        pageElt.addChild(itemElt);
    }
};


CheckListBox.prototype.viewListAtFirstSelected = noop["a" /* default */];

CheckListBox.prototype.viewListAtValue = function (value) {
    if (!this.isDescendantOf(document.body)) {
        this.domSignal.emit('viewListAtValue', value);
        return;
    }
    if (this._displayValue == SelectListBox["a" /* VALUE_HIDDEN */]) {
        return false;
    }


    var itemHolders = this._displayItemHolderByValue[value + ''];
    if (itemHolders) {
        this.domSignal.once('scrollIntoValue', function () {
            var holder = itemHolders[0];
            this.viewListAt(holder.idx);
            var itemElt = Object(ACore["a" /* $ */])('.as-check-list-item', this.$listScroller, function (elt) {
                return elt.value === value;
            });
            if (itemElt) {
                var scrollBound = this.$listScroller.getBoundingClientRect();
                var itemBound = itemElt.getBoundingClientRect();
                this.$listScroller.scrollTop += itemBound.top - scrollBound.top;
            }
        }.bind(this));
        this.domSignal.emit('scrollIntoValue');
        return true;
    } else return false;

};


CheckListBox.property.values = {
    set: function (value) {
        SelectListBox["b" /* default */].property.values.set.apply(this, arguments);
        this.$checkAll.checked = this._values.length === this.items.length;
    },
    get: SelectListBox["b" /* default */].property.values.get
};

/***
 * @this CheckListBox
 * @param event
 */
CheckListBox.eventHandler.checkAllChange = function (event) {
    var checked = this.$checkAll.checked;
    if (checked) {
        this._values = this.items.map(function (cr) {
            return typeof cr === "object" ? cr.value : cr;
        });
        this._valueDict = this._values.reduce(function (ac, value) {
            ac[value + ''] = true;
            return ac;
        }, {});
    } else {
        this._values = [];
        this._valueDict = {};
    }
    this._updateSelectedItem();
    this.emit('change', {
        target: this,
        type: 'change',
        originalEvent: event.originalEvent || event.originEvent || event,
        action: checked ? 'check_all' : "uncheck_all"
    }, this);
};


/***
 * @this CheckListBox
 * @param itemElt
 * @param event
 */
CheckListBox.eventHandler.itemSelect = function (itemElt, event) {
    var selected = itemElt.selected;
    var value = itemElt.value;
    var itemData = itemElt.data;
    var idx;
    if (selected) {
        this._values.push(value);
        this._valueDict[value + ''] = true;
    } else {
        idx = this._values.indexOf(value);
        delete this._valueDict[value + ''];
        if (idx >= 0) {
            this._values.splice(idx, 1);
        } else {
            console.error("Violation data");
        }
    }
    this.emit('change', {
        target: this,
        type: 'change',
        originalEvent: event.originalEvent || event.originEvent || event,
        action: selected ? 'check' : 'uncheck',
        value: value,
        itemData: itemData
    }, this);
};


/***
 * @this CheckListBox
 * @param event
 */
CheckListBox.eventHandler.clickCancelBtn = function (event) {
    this.emit('cancel', {type: 'cancel', target: this, originalEvent: event}, this);
};

ACore["d" /* default */].install(CheckListBox);


/* harmony default export */ var js_CheckListBox = (CheckListBox);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/MultiCheckMenu.js









/***
 * @extends MultiSelectMenu
 * @constructor
 */
function MultiCheckMenu() {
    this.addClass('as-multi-check-menu');

    this.on('click', this.eventHandler.click);
    /***
     * @type {CheckListBox}
     */
    this.$selectlistBox = Object(ACore["c" /* _ */])({
        tag: js_CheckListBox.tag,
        props: {
            anchor: [1, 6, 2, 5]
        },
        on: {
            preupdateposition: this.eventHandler.preUpdateListPosition,
            change: this.eventHandler.selectListBoxChange,
            cancel: this.eventHandler.selectListBoxCancel
        }
    });


    this.$itemCtn = Object(ACore["a" /* $ */])('.as-multi-select-menu-item-ctn', this);
    this.$attachhook = Object(ACore["a" /* $ */])('attachhook', this)
        .on('attached', this.eventHandler.attached);

    OOP["a" /* default */].drillProperty(this, this.$selectlistBox, 'enableSearch');
    this._isFocus = false;
    this.$items = [];
    this._tempValues = [];
    this._values = [];
    this.items = [];
    this.values = [];
    this.$selectlistBox.followTarget = this;
    this.disableClickToFocus = false;
    this.orderly = true;
    this.itemFocusable = false;
    this._activeValue = undefined;
}


MultiCheckMenu.tag = 'MultiCheckMenu'.toLowerCase();

MultiCheckMenu.render = MultiSelectMenu["a" /* default */].render;

Object.assign(MultiCheckMenu.prototype, MultiSelectMenu["a" /* default */].prototype);
MultiCheckMenu.property = Object.assign({}, MultiSelectMenu["a" /* default */].property);
MultiCheckMenu.eventHandler = Object.assign({}, MultiSelectMenu["a" /* default */].eventHandler);




MultiCheckMenu.eventHandler.click = function (event) {
    if ((event.target === this || event.target === this.$itemCtn) && !this.isFocus) {
        this.isFocus = true;
    }
};


MultiCheckMenu.eventHandler.bodyClick = function (event) {
    var isRemovedItem = !AElement["a" /* default */].prototype.isDescendantOf.call(event.target, document.body)
        && (event.target.classList.contains('absol-selectbox-item-close')
            || (event.target.parentElement && event.target.parentElement.classList.contains('absol-selectbox-item-close')));
    if (this.isFocus
        && !EventEmitter["b" /* default */].hitElement(this.$selectlistBox, event)
        && (!isRemovedItem)
        && (!Object(EventEmitter["d" /* hitElement */])(this.$itemCtn, event) || event.target === this.$itemCtn)
    ) {
        this.eventHandler.selectListBoxPressItem(event);
        this.isFocus = false;
    }
};


MultiCheckMenu.eventHandler.selectListBoxChange = function (event) {
    var idx;
    switch (event.action) {
        case 'check':
            idx = this._tempValues.indexOf(event.value);
            if (idx < 0) {
                this._tempValues.push(event.value);
            }
            break;
        case 'uncheck':
            idx = this._tempValues.indexOf(event.value);
            if (idx >= 0) {
                this._tempValues.splice(idx, 1);
            }
            break;
        case 'check_all':
            this._tempValues = this.items.map(function (item) {
                return Object(SelectListItem["d" /* getValueOfListItem */])(item);
            })
            break;
        case 'uncheck_all':
            this._tempValues = [];
            break;
    }

    setTimeout(function () {
        this.viewItemsByValues(this._tempValues);
        var bound = this.getBoundingClientRect();
        this.$selectlistBox.addStyle('min-width', bound.width + 'px');
        this.$selectlistBox.refollow();
        this.$selectlistBox.updatePosition();
    }.bind(this), 1);
};

MultiCheckMenu.eventHandler.selectListBoxCancel = function (event) {
    this.viewItemsByValues(this._values);
    this.isFocus = false;
    this.$selectlistBox.values = this._values;
};




MultiCheckMenu.property.isFocus = {
    set: function (value) {
        if (!this._isFocus && value) {
            this._tempValues = this._values.slice();
            this.$selectlistBox.values = this._values;
            this.activeValue = null;
        }
        var thisSM = this;
        if (!this.items || this.items.length === 0) value = false;//prevent focus
        if (this._isFocus === value) return;
        this._isFocus = !!value;
        if (this._isFocus) {
            thisSM.off('click', this.eventHandler.click);
            document.body.appendChild(this.$selectlistBox);
            this.$selectlistBox.domSignal.$attachhook.emit('attached');
            var bound = this.getBoundingClientRect();
            this.$selectlistBox.addStyle('min-width', bound.width + 'px');
            this.$selectlistBox.refollow();
            this.$selectlistBox.updatePosition();
            setTimeout(function () {
                if (thisSM.enableSearch) {
                    thisSM.$selectlistBox.$searchInput.focus();
                } else {
                    thisSM.$selectlistBox.focus();
                }
                document.addEventListener('mousedown', thisSM.eventHandler.bodyClick);
            }, 100);
            this.$selectlistBox.viewListAtFirstSelected();
        } else {
            document.removeEventListener('mousedown', thisSM.eventHandler.bodyClick);

            document.addEventListener('mouseup', function mup() {
                setTimeout(function () {
                    thisSM.on('click', thisSM.eventHandler.click);
                    document.removeEventListener('mouseup', mup);
                }, 5);
            });
            this.$selectlistBox.selfRemove();
            this.$selectlistBox.unfollow();
            this.$selectlistBox.resetSearchState();
        }
    },
    get: MultiSelectMenu["a" /* default */].property.isFocus.get
};

/***
 * call after close checklistbox
 * @param event
 */
MultiCheckMenu.eventHandler.selectListBoxPressItem = function (event) {
    var prevValues = this._values;
    var prevDict = prevValues.reduce(function (ac, cr) {
        ac[cr + ''] = cr;
        return ac;
    }, {});
    this.$selectlistBox.updatePosition();
    var curValues = this.$selectlistBox.values;
    var changed = false;
    var curDict = curValues.reduce(function (ac, cr) {
        ac[cr + ''] = cr;
        return ac;
    }, {});
    this._values = curValues.slice();
    prevValues.forEach(function (value) {
        if ((value + '') in curDict) return;
        var holders = this.$selectlistBox.findItemsByValue(value);
        if (!holders || holders.length === 0) return;
        var item = holders[0].item;
        this.emit('remove', Object.assign({}, event, {
            type: 'remove',
            target: this,
            value: item.value,
            data: item,
            itemData: item
        }), this);
        changed = true;
    }.bind(this));

    curValues.forEach(function (value) {
        if ((value + '') in prevDict) return;
        var holders = this.$selectlistBox.findItemsByValue(value);
        if (!holders || holders.length === 0) return;
        var item = holders[0].item;
        this.emit('add', Object.assign({}, event, {
            type: 'add',
            target: this,
            value: item.value,
            data: item,
            itemData: item
        }), this);
        changed = true;
    }.bind(this));
    this._updateItems();
    this.isFocus = false;
    if (changed)
        this.emit('change', Object.assign({}, event, {
            type: 'change',
            action: 'submit',
            target: this,
            values: this.values
        }), this);
};


MultiCheckMenu.eventHandler.pressCloseItem = function (item, event) {
    var value = item.value;
    var data = item.data;
    var currentValues;
    var index;
    if (this.isFocus) {
        currentValues = this.$selectlistBox.values;
        index = currentValues.indexOf(value);
        if (index >= 0) {
            currentValues.splice(index, 1);
        }
        this.$selectlistBox.values = currentValues;
        this.$selectlistBox.updatePosition();
        this.viewItemsByValues(this.$selectlistBox.values);
    } else {
        index = this._values.indexOf(value);
        if (index >= 0) {
            this._values.splice(index, 1);
            this._updateItems();

            this.emit('remove', Object.assign({}, event, {
                type: 'change',
                target: this,
                data: data,
                value: value,
                itemData: data
            }), this);
            this.emit('change', Object.assign({}, event, {
                type: 'change',
                action: 'remove',
                target: this,
                data: data,
                value: value,
                itemData: data
            }), this);
        }
    }
};


MultiCheckMenu.eventHandler.pressItem = function (item, event) {
    var value = item.value;
    if (this.itemFocusable && !this.isFocus) {
        var prevActiveValue = this.activeValue;
        if (value !== prevActiveValue) {
            this.activeValue = value;
            this.emit('activevaluechange', {
                target: this,
                originEvent: event,
                prevActiveValue: prevActiveValue,
                activeValue: value
            }, this);
        }
    } else if (this.isFocus) {
        this.$selectlistBox.viewListAtValue(value);
    }
};
ACore["d" /* default */].install(MultiCheckMenu);

/* harmony default export */ var js_MultiCheckMenu = (MultiCheckMenu);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/chrometime24picker.css
var chrometime24picker = __webpack_require__(284);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/ChromeTime24Picker.js








/**
 *
 * @param {number} leftOffset
 */
function calcMinHMTime(leftOffset) {
    var h = Math.floor(leftOffset / datetime["MILLIS_PER_HOUR"]);
    var m = Math.floor(leftOffset / datetime["MILLIS_PER_MINUTE"]) % 60;
    if (leftOffset % datetime["MILLIS_PER_MINUTE"] > 0) {
        if (m === 59) {
            h++;
            m = 0;
        } else {
            m++;
        }
    }
    var offset = h * datetime["MILLIS_PER_HOUR"] + m * datetime["MILLIS_PER_MINUTE"];
    return {m: m, h: h, offset: offset};
}

/***
 * @extends AElement
 * @constructor
 */
function ChromeTime24Picker() {
    this.$lists = Object(ACore["b" /* $$ */])('.as-chrome-time-picker-list', this);
    Object(ACore["b" /* $$ */])('.as-chrome-time-picker-scroller', this).forEach(js_ChromeTimePicker.prototype._makeScroller.bind(this));
    this.$hours = Object(ACore["b" /* $$ */])('.as-chrome-time-picker-h24 .as-chrome-time-picker-btn', this);
    this.$minutes = Object(ACore["b" /* $$ */])('.as-chrome-time-picker-m60 .as-chrome-time-picker-btn', this);
    this.$lists[0].on('click', this.eventHandler.clickHour24List);
    this.$lists[1].on('click', this.eventHandler.clickMinList);
    this.$domSignal = Object(ACore["c" /* _ */])('attachhook').addTo(this);
    this.domSignal = new DomSignal["a" /* default */](this.$attachhook);
    this.domSignal.on('scrollToSelectedMinute', this._scrollToSelectedMinute.bind(this))
        .on('scrollToSelectedHour', this._scrollToSelectedHour.bind(this));
    this._dayOffset = 0;
    this._value = 0;
    this.dayOffset = new Date();
    this.value = 2 * datetime["MILLIS_PER_MINUTE"];
}


ChromeTime24Picker.tag = 'ChromeTime24Picker'.toLowerCase();


ChromeTime24Picker.render = function () {
    return Object(ACore["c" /* _ */])({
        extendEvent: 'change',
        class: ['as-chrome-time-24-picker', 'as-chrome-time-picker'],
        child: [
            {
                class: ['as-chrome-time-picker-scroller', 'as-chrome-time-24-picker-hour'],
                child: [
                    {tag: 'button', class: 'as-chrome-time-picker-scroller-up', child: 'span.mdi.mdi-chevron-up'},
                    {tag: 'button', class: 'as-chrome-time-picker-scroller-down', child: 'span.mdi.mdi-chevron-down'},
                    {
                        class: ['as-chrome-time-picker-viewport', 'as-chrome-time-picker-h24'],
                        child: {
                            class: 'as-chrome-time-picker-list',
                            child: Array(24).fill(0).map(function (u, i) {
                                return {
                                    tag: 'button',
                                    class: 'as-chrome-time-picker-btn',
                                    child: [
                                        {
                                            tag: 'span',
                                            child: {text: i + ''}
                                        },
                                        {
                                            tag: 'span',
                                            class: 'as-chrome-time-24-picker-tomorrow-text',
                                            child: {text: ' (Hôm sau)'}
                                        }
                                    ],
                                    props: {
                                        __hour__: i
                                    }
                                }
                            })
                        }
                    }
                ]

            },
            {
                class: 'as-chrome-time-picker-scroller',
                child: [
                    {tag: 'button', class: 'as-chrome-time-picker-scroller-up', child: 'span.mdi.mdi-chevron-up'},
                    {tag: 'button', class: 'as-chrome-time-picker-scroller-down', child: 'span.mdi.mdi-chevron-down'},
                    {
                        class: ['as-chrome-time-picker-viewport', 'as-chrome-time-picker-m60'],
                        child: {
                            class: 'as-chrome-time-picker-list',
                            child: Array(60).fill(0).map(function (u, i) {
                                return {
                                    tag: 'button',
                                    class: 'as-chrome-time-picker-btn',

                                    child: {
                                        tag: 'span',
                                        child: {text: i + ''}
                                    },
                                    props: {
                                        __min__: i
                                    }
                                }
                            })
                        }
                    }
                ]
            }
        ]

    });
};

ChromeTime24Picker.prototype._updateHourNumbers = function () {
    var mH = calcMinHMTime(this.dayOffset).h;
    for (var i = 0; i < this.$hours.length; ++i) {
        this.$hours[i].firstChild.firstChild.data = (mH + i) % 24;
        if (mH + i >= 24) {
            this.$hours[i].addClass('as-in-tomorrow');
        } else {
            this.$hours[i].removeClass('as-in-tomorrow');
        }
    }
};

ChromeTime24Picker.prototype._updateMinuteNumbers = function () {
    var minHM = calcMinHMTime(this.dayOffset);
    var h = minHM.h;
    var m = minHM.m;
    var vH = Math.floor((this.dayOffset + this.value) / datetime["MILLIS_PER_HOUR"]);
    for (var i = 0; i < this.$minutes.length; ++i) {
        if (vH === h && i < m) {
            this.$minutes[i].disabled = true;

        } else {
            this.$minutes[i].disabled = false;
        }
    }
};

ChromeTime24Picker.prototype._updateSelectedHour = function () {
    var h = Math.floor(this.dayOffset / datetime["MILLIS_PER_HOUR"]);
    var vH = Math.floor((this.dayOffset + this.value) / datetime["MILLIS_PER_HOUR"]);
    var d = vH - h;
    for (var i = 0; i < this.$hours.length; ++i) {
        if (i === d) {
            this.$hours[i].addClass('as-selected');
            this.$selectedHour = this.$hours[i];
        } else {
            this.$hours[i].removeClass('as-selected');
        }
    }
    this._scrollToSelectedHour();
};

ChromeTime24Picker.prototype._updateSelectedMinute = function () {
    var vM = Math.floor((this.dayOffset + this.value) / datetime["MILLIS_PER_MINUTE"]) % 60;
    for (var i = 0; i < this.$minutes.length; ++i) {
        if (vM === i) {
            this.$minutes[i].addClass('as-selected');
            this.$selectedMinute = this.$minutes[i];
        } else {
            this.$minutes[i].removeClass('as-selected');
        }
    }
    this._scrollToSelectedMinute();
};

ChromeTime24Picker.prototype._update = function () {
    this._updateHourNumbers();
    this._updateMinuteNumbers();
    this._updateSelectedHour();
    this._updateSelectedMinute();
};

ChromeTime24Picker.prototype._scrollToSelectedHour = function () {
    if (this.isDescendantOf(document.body)) {
        if (this.$selectedHour) {
            Object(utils["vScrollIntoView"])(this.$selectedHour);
        }
    } else {
        this.domSignal.emit('scrollToSelectedHour');
    }
};

ChromeTime24Picker.prototype._scrollToSelectedMinute = function () {
    if (this.isDescendantOf(document.body)) {
        if (this.$selectedMinute) {
            Object(utils["vScrollIntoView"])(this.$selectedMinute);
        }
    } else {
        this.domSignal.emit('scrollToSelectedMinute');
    }
};

ChromeTime24Picker.prototype.notifyChange = function () {
    this.emit('change', {type: 'change'}, this);
};


ChromeTime24Picker.property = {};

ChromeTime24Picker.property.dayOffset = {
    /***
     *
     * @param {number|Date} value
     */
    set: function (value) {
        if (typeof value === "number") {
            value = Math.max(0, value % datetime["MILLIS_PER_DAY"]);//10p
        } else if (value instanceof Date) {
            value = Math.max(0, (value.getTime() - Object(datetime["beginOfDay"])(value).getTime()) % datetime["MILLIS_PER_DAY"]);
        } else value = 0;
        this._dayOffset = value;
        this._update();
    },
    get: function () {
        return this._dayOffset;
    }
};


ChromeTime24Picker.property.value = {
    /***
     * @this ChromeTime24Picker
     * @param value
     */
    set: function (value) {
        this._value = value;
        this._update();
    },
    get: function () {
        return this._value;
    }
};

ChromeTime24Picker.property.hour = {
    get: function () {
        return Math.floor((this.dayOffset + this.value) / datetime["MILLIS_PER_HOUR"]);
    }
};


ChromeTime24Picker.property.minute = {
    get: function () {
        return Math.floor((this.dayOffset + this.value) / datetime["MILLIS_PER_MINUTE"]) % 60;
    }
};


ChromeTime24Picker.eventHandler = {};

ChromeTime24Picker.eventHandler.clickHour24List = function (event) {
    var minHM = calcMinHMTime(this.dayOffset);
    var h = minHM.h;
    var vM = Math.floor((this.dayOffset + this.value) / datetime["MILLIS_PER_MINUTE"]) % 60;
    var hour;
    var minChanged = false;
    var prevValue = this._value;
    if ('__hour__' in event.target) hour = event.target.__hour__;
    if ('__hour__' in event.target.parentElement) hour = event.target.parentElement.__hour__;
    if (hour !== undefined) {
        if (hour === 0 && minHM.m > vM) {
            vM = minHM.m;
            minChanged = true;
        }
        this._value = (h + hour) * datetime["MILLIS_PER_HOUR"] + vM * datetime["MILLIS_PER_MINUTE"] - this.dayOffset;
        this._updateSelectedHour();
        this._updateMinuteNumbers();
        if (minChanged) this._updateSelectedMinute();
        if (prevValue !== this._value)
            this.notifyChange(event);
    }
};


ChromeTime24Picker.eventHandler.clickMinList = function (event) {
    var vH = Math.floor((this.dayOffset + this.value) / datetime["MILLIS_PER_HOUR"]);
    var min;
    var prevValue = this._value;
    if ('__min__' in event.target) min = event.target.__min__;
    if ('__min__' in event.target.parentElement) min = event.target.parentElement.__min__;
    if (min !== undefined) {
        this._value = vH * datetime["MILLIS_PER_HOUR"] + min * datetime["MILLIS_PER_MINUTE"] - this.dayOffset;
        this._updateSelectedMinute();
        this.notifyChange(event);
        if (prevValue !== this._value)
            this.notifyChange(event);
    }
};

ACore["d" /* default */].install(ChromeTime24Picker);

/* harmony default export */ var js_ChromeTime24Picker = (ChromeTime24Picker);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/Time24Input.js






/**
 * @extends AElement
 * @constructor
 */
function Time24Input() {
    this.$clockBtn = Object(ACore["a" /* $ */])('.as-time-input-icon-btn', this)
        .on('click', this.eventHandler.clickClockBtn);
    this.$text = Object(ACore["a" /* $ */])('.as-time-input-text', this);
    this.$clearBtn = Object(ACore["a" /* $ */])('button.as-time-input-clear-btn', this)
        .on('click', this.clear.bind(this));
    this._dayOffset = 0;
    this._value = 0;
    this._format = 'HH:mm';
    this.dayOffset = this._dayOffset;
    this.value = this._value;
    this.format = this._format;
    this.notNull = true;
}

Time24Input.tag = 'Time24Input'.toLowerCase();

Time24Input.render = function () {
    return Object(ACore["c" /* _ */])({
        class: ['ac-time-input', 'as-time-24-input'],
        extendEvent: ['change'],
        child: [
            {
                tag: 'input',
                class: 'as-time-input-text',
                attr: {
                    readOnly: 'true',
                    type: 'text'
                }
            },
            {
                tag: 'button',
                class: 'as-time-input-clear-btn',
                child: 'span.mdi.mdi-close-circle'
            },
            {
                tag: 'button',
                class: 'as-time-input-icon-btn',
                child: 'span.mdi.mdi-clock-outline'
            }
        ]
    });
};


Time24Input.prototype._updateText = function () {
    var text;
    if (Object(utils["isRealNumber"])(this._value) && Object(utils["isRealNumber"])(this._dayOffset)) {
        text = Object(datetime["formatDateTime"])(new Date(Object(datetime["beginOfDay"])(new Date).getTime() + this._value + this._dayOffset), this._format);
        if (this._value + this._dayOffset >= datetime["MILLIS_PER_DAY"]) text += ' (Hôm sau)';
        this.removeClass('as-value-null');
    } else {
        text = this._format;
        this.addClass('as-value-null');
    }
    this.$text.value = text;
};


Time24Input.prototype._notifyChange = function (event) {
    this.emit('change', {type: 'change', originalEvent: event.originalEvent || event.originEvent || event}, this);
};


Time24Input.prototype.clear = function (event) {
    if (this._value !== null && !this.notNull){
        this.value = null;
        this._notifyChange(event);
    }
};


Time24Input.prototype.share = {
    $picker: null,
    /***
     * @type Time24Input
     */
    $holdingInput: null,
    $follower: null
};


Time24Input.prototype._preparePicker = function () {
    if (this.share.$picker) return;
    this.share.$picker = Object(ACore["c" /* _ */])({
        tag: js_ChromeTime24Picker.tag
    });
    this.share.$follower = Object(ACore["c" /* _ */])({
        tag: 'follower',
        class: 'as-chrome-time-24-picker-follower',
        child: this.share.$picker
    });
};

Time24Input.prototype._attachPicker = function () {
    this._preparePicker();
    if (this.share.$holdingInput) {
        this.share.$holdingInput._releasePicker();
    }
    this.share.$holdingInput = this;
    this.share.$follower.addTo(document.body);
    this.share.$follower.followTarget = this;
    this.share.$follower.addStyle('visibility', 'hidden');
    this.share.$picker.on('change', this.eventHandler.pickerChange);
    this.$clockBtn.off('click', this.eventHandler.clickClockBtn);
    this.share.$picker.dayOffset = Object(utils["isRealNumber"])(this._dayOffset) ? this._dayOffset : 0;
    this.share.$picker.value = Object(utils["isRealNumber"])(this._value) ? this._value : 0;

    setTimeout(function () {
        document.body.addEventListener('click', this.eventHandler.clickOut);
        this.share.$follower.removeStyle('visibility');
    }.bind(this), 5);
};


Time24Input.prototype._releasePicker = function () {
    if (this.share.$holdingInput !== this) return;
    this.share.$picker.off('change', this.eventHandler.pickerChange);
    this.share.$follower.remove();
    this.share.$follower.followTarget = null;
    this.share.$holdingInput = null;
    document.body.removeEventListener('click', this.eventHandler.clickOut);
    setTimeout(function () {
        this.$clockBtn.on('click', this.eventHandler.clickClockBtn);
    }.bind(this), 10)
};

Time24Input.property = {};

Time24Input.property.dayOffset = {
    set: function (value) {
        this._dayOffset = Object(utils["isRealNumber"])(value) ? value : null;
        this._updateText();
    },
    get: function () {
        return this._dayOffset;
    }
};

Time24Input.property.value = {
    set: function (value) {
        this._value = Object(utils["isRealNumber"])(value) ? value : (this.notNull ? 0 : null);
        this._updateText();
    },
    get: function () {
        return this._value;
    }
};

Time24Input.property.displayTime = {
    get: function () {
        if (Object(utils["isRealNumber"])(this._value) && Object(utils["isRealNumber"])(this._dayOffset)) {
            return this._value + this._dayOffset;
        } else {
            return null;
        }
    }
};


Time24Input.property.notNull = {
    set: function (value) {
        if (value) {
            if (this.value === null) {
                this.value = 0;
            }
            this.addClass('as-must-not-null');

        } else {
            this.removeClass('as-must-not-null');
        }
    },
    get: function () {
        return this.containsClass('as-must-not-null');
    }
};

Time24Input.property.disabled = {
    set: function (value) {
        value = !!value;
        this._disabled = value;
        if (value) this.addClass('as-disabled');
        else this.removeClass('as-disabled');
        this.$text.disabled = value;
    },
    get: function () {
        return this._disabled;
    }
};


Time24Input.property.format = {
    set: function (value) {
        this._format = value || 'HH:mm';
        this._updateText();
    },
    get: function () {
        return this._format;
    }
}


Time24Input.eventHandler = {};

Time24Input.eventHandler.pickerChange = function (event) {
    if (this.dayOffset === null) this.dayOffset = 0;
    this.value = this.share.$picker.value;
    this._notifyChange(event);
};

Time24Input.eventHandler.clickOut = function (event) {
    if (Object(EventEmitter["d" /* hitElement */])(this.share.$follower, event)) return;
    this._releasePicker();
};


Time24Input.eventHandler.clickClockBtn = function () {
    this._attachPicker();
};


ACore["d" /* default */].install(Time24Input);

/* harmony default export */ var js_Time24Input = (Time24Input);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/timerange24input.css
var timerange24input = __webpack_require__(286);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TimeRange24Input.js







/***
 * @extends AElement
 * @constructor
 */
function TimeRange24Input() {
    /***
     *
     * @type {TimeInput}
     */
    this.$offset = Object(ACore["a" /* $ */])(js_TimeInput.tag, this);
    this.$offset.on('change', this.eventHandler.offsetChange);
    /***
     *
     * @type {Time24Input}
     */
    this.$duration = Object(ACore["a" /* $ */])(js_Time24Input.tag, this);
    this.$duration.on('change', this.eventHandler.durationChange);
}

TimeRange24Input.tag = 'TimeRange24Input'.toLowerCase();


TimeRange24Input.render = function () {
    return Object(ACore["c" /* _ */])({
        extendEvent: ['change'],
        class: 'as-time-range-24-input',
        child: [{
            tag:
            js_TimeInput.tag,
            props: {
                format: 'HH:mm'
            }
        },
            js_Time24Input.tag
        ]
    });
};


TimeRange24Input.prototype.init = function (props) {
    props = props || {};
    var cpProps = Object.assign(props);
    if ('notNull' in props) {
        this.notNull = props.notNull;
        delete cpProps.notNull;
    }
    if ('dayOffset' in props) {
        this.dayOffset = props.dayOffset;
        delete cpProps.dayOffset;
    }
    Object.assign(this, cpProps);
};


TimeRange24Input.property = {};

TimeRange24Input.property.notNull = {
    /***
     * @this TimeRange24Input
     * @param value
     */
    set: function (value) {
        value = !!value;
        this.$offset.notNull = value;
        this.$duration.notNull = value;
    },
    get: function () {
        return this.$offset.notNull;
    }
};

TimeRange24Input.property.disabled = {
    set: function (value) {
        value = !!value;
        if (value) {
            this.addClass('as-disabled');
        } else {
            this.removeClass('as-disabled');
        }
        this.$offset.disabled = value;
        this.$duration.disabled = value;
    },
    get: function () {
        return this.containsClass('as-disabled');
    }
}


TimeRange24Input.property.dayOffset = {
    set: function (value) {
        var notNull = this.notNull;
        if (Object(utils["isRealNumber"])(value)) {
            value = value << 0;
            value = value % datetime["MILLIS_PER_DAY"];
            value = (value + datetime["MILLIS_PER_DAY"]) % datetime["MILLIS_PER_DAY"];
            value = Math.floor(value / datetime["MILLIS_PER_MINUTE"]) * datetime["MILLIS_PER_MINUTE"];
        } else {
            value = notNull ? 0 : null;
        }

        this.$offset.dayOffset = value;
        this.$duration.dayOffset = value;
    },
    get: function () {
        return this.$offset.dayOffset;
    }
};

TimeRange24Input.property.duration = {
    /***
     * @this TimeRange24Input
     * @param value
     */
    set: function (value) {
        var notNull = this.notNull;
        if (Object(utils["isRealNumber"])(value)) {
            value = Math.floor(Math.min(datetime["MILLIS_PER_DAY"], Math.max(0, value)));
            value = Math.floor(value / datetime["MILLIS_PER_MINUTE"]) * datetime["MILLIS_PER_MINUTE"];
        } else {
            value = notNull ? 0 : null;
        }
        this.$duration.value = value;
    },
    get: function () {
        return this.$duration.value;
    }
};


TimeRange24Input.eventHandler = {};

TimeRange24Input.eventHandler.offsetChange = function (event) {
    this.$duration.dayOffset = this.$offset.dayOffset;
    this.emit('change', {
        type: 'change',
        property: 'dayOffset',
        originalEvent: event.originalEvent || event.originEvent || event
    });
};

TimeRange24Input.eventHandler.durationChange = function (event) {
    if (this.$duration.dayOffset !== null && this.$offset.dayOffset === null) {
        this.$offset.dayOffset = this.$duration.dayOffset;
    }
    this.emit('change', {
        type: 'change',
        property: 'duration',
        originalEvent: event.originalEvent || event.originEvent || event
    });
};


ACore["d" /* default */].install(TimeRange24Input);

/* harmony default export */ var js_TimeRange24Input = (TimeRange24Input);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/checktreeitem.css
var checktreeitem = __webpack_require__(288);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/tool/TextMeasurement.js

function TextMeasurement(opts) {
    opts = opts || {};
    this.chars = opts.chars || (" !\"$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ" +
        "[\\]^_abcdefghijklmnopqrstuvwxyz{|}" +
        "¥©ÀÁÂÃÈÉÊÌÍÒÓÔÕÙÚÝàáâãèéêìíñòóôõùúýĂăĐđĨĩŨũƠơƯưẠ̌̀́̃̉Р" +
        "ийксуẠạẢảẤấẦầẨẩẪẫẬậẮắẰằẲẳẴẵẶặẸẹẺẻẼẽẾếỀềỂểỄễỆệỈỉỊị" +
        "ỌọỎỏỐốỒồỔổỖỗỘộỚớỜờỞởỠỡỢợỤụỦủỨứỪừỬửỮữỰựỲỳỴỵỶỷỸỹ–’“”…₫€?").split('');

    this.computed = Object.assign({}, opts.computed || {});
}


TextMeasurement.prototype.compute = function (font) {
    if (this.computed[font]) return true;
    if (!('document' in window)) return false;
    if (!this.canvas) {
        this.canvas = document.createElement('canvas');
        this.ctx = this.canvas.getContext('2d');
    }
    var ctx = this.ctx;
    ctx.font = font;
    var data = {};
    var charBoxes = {};
    data.charBoxes = charBoxes;
    var c, d, i, j;
    var metrics;
    var n = this.chars.length;
    var chars = this.chars;
    for (i = 0; i < n; ++i) {
        c = chars[i];
        metrics = ctx.measureText(c);
        charBoxes[c] = metrics.width;
    }

    var spacing = {};
    data.spacing = spacing;
    var pair;
    for (i = 0; i < n; ++i) {
        c = chars[i];
        for (j = 0; j < n; ++j) {
            d = chars[j];
            pair = c + d;
            metrics = ctx.measureText(pair);
            spacing[pair] = metrics.width - charBoxes[c] - charBoxes[d];
        }
    }

    this.computed[font] = data;
    return true;
};


/***
 *
 * @param {string} text
 * @param {string=} font
 * @return {number}
 */
TextMeasurement.prototype.measureTextWidth = function (text, font) {
    var l = text.length;
    if (l === 0) return 0;
    var width = 0;
    var data = this.computed[font];
    var charBoxes = data.charBoxes;
    var spacing = data.spacing;
    var c, pc;
    pc = text[0];
    width += charBoxes[pc] || charBoxes['0'];

    for (var i = 1; i < l; ++i) {
        c = text[i];
        width += spacing[pc + c];
        width += charBoxes[c] || charBoxes['0'];
        pc = c;
    }
    return width;
};

/* harmony default export */ var tool_TextMeasurement = (TextMeasurement);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/CheckTreeItem.js








/***
 * @extends ExpNode
 * @constructor
 */
function CheckTreeItem() {
    this._itemData = null;
    this.$name = Object(ACore["a" /* $ */])('span.absol-exp-node-name', this);
    this.$desc = Object(ACore["a" /* $ */])('span.absol-exp-node-desc', this);
    this.$iconCtn = Object(ACore["a" /* $ */])('div.absol-exp-node-ext-icon', this);
    this.$level = Object(ACore["a" /* $ */])('.absol-exp-node-level', this);
    this.$checkbox = Object(ACore["a" /* $ */])('checkboxbutton', this)
        .on('change', this.eventHandler.checkboxChange);
    this.$toggleIcon = Object(ACore["a" /* $ */])('toggler-ico', this);
    this.on('click', this.eventHandler.click);
}

CheckTreeItem.tag = 'CheckTreeItem'.toLowerCase();

CheckTreeItem.render = function () {
    return Object(ACore["c" /* _ */])({
        tag: 'button',
        extendEvent: ['select', 'presstoggle'],
        class: ['as-check-tree-item', 'absol-exp-node'],
        child: [
            '.absol-exp-node-level',
            'toggler-ico',
            'checkboxbutton',
            'img.absol-exp-node-ext-icon',
            'div.absol-exp-node-ext-icon',
            'span.absol-exp-node-name',
            'span.absol-exp-node-desc'
        ]
    });
};

CheckTreeItem.property = {};

CheckTreeItem.property.icon = ExpTree["b" /* ExpNode */].property.icon;
CheckTreeItem.property.text = ExpTree["b" /* ExpNode */].property.name;
CheckTreeItem.property.level = ExpTree["b" /* ExpNode */].property.level;
CheckTreeItem.property.desc = ExpTree["b" /* ExpNode */].property.desc;
CheckTreeItem.property.status = ExpTree["b" /* ExpNode */].property.status;

CheckTreeItem.property.data = {
    set: function (itemData) {
        this._itemData = itemData;
        var text = Object(SelectListItem["c" /* getTextOfListItem */])(itemData);
        this.text = text;
        var desc = Object(SelectListItem["b" /* getDescriptionOfListItem */])(itemData);
        this.desc = desc;
        if (itemData && itemData.icon) {
            this.icon = itemData.icon;
        }
    },
    get: function () {
        return this._itemData;
    }
};

CheckTreeItem.property.selected = {
    set: function (value) {
        this.$checkbox.disabled = value === 'empty';
        if (value === 'all') {
            this.$checkbox.removeClass('as-has-minus')
                .removeClass('as-has-minus');
            this.$checkbox.checked = true;
        } else if (value === 'child') {
            this.$checkbox.checked = false;
            this.$checkbox.addClass('as-has-minus');
        } else if (value === 'empty') {
            this.$checkbox.removeClass('as-has-minus')
            this.$checkbox.checked = false;
        } else {
            this.$checkbox.removeClass('as-has-minus');
            this.$checkbox.checked = false;
        }
    },
    get: function () {
        if (this.$checkbox.checked) {
            return 'all';
        } else {
            if (this.$checkbox.containsClass('as-has-minus')) {
                return 'child';
            } else {
                return 'none';
            }
        }
    }
};


CheckTreeItem.eventHandler = {};


CheckTreeItem.eventHandler.checkboxChange = function (event) {
    this.emit('select', {
        type: 'select',
        target: this,
        originalEvent: event.originalEvent || event.originEvent || event
    });
};

CheckTreeItem.eventHandler.click = function (event) {
    var tBound;
    if (this.status === 'open' || this.status === 'close') {
        tBound = this.$toggleIcon.getBoundingClientRect();
        if (event.clientX <= tBound.right) {
            this.emit('presstoggle', {type: 'presstoggle', target: this, originalEvent: event}, this);
        } else if (!Object(EventEmitter["d" /* hitElement */])(this.$checkbox, event)) {
            this.$checkbox.checked = !this.$checkbox.checked;
            this.eventHandler.checkboxChange(event);
        }
    } else {
        if (!Object(EventEmitter["d" /* hitElement */])(this.$checkbox, event)) {
            this.$checkbox.checked = !this.$checkbox.checked;
            this.eventHandler.checkboxChange(event);
        }
    }
};

ACore["d" /* default */].install(CheckTreeItem);


/* harmony default export */ var js_CheckTreeItem = (CheckTreeItem);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/checktreebox.css
var checktreebox = __webpack_require__(290);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/CPUViewer.js
var CPUViewer = __webpack_require__(23);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/CheckTreeBox.js










/***
 * @extends Follower
 * @constructor
 */
function CheckTreeBox() {
    this._initControl();
    this._initScroller();
    this._initDomHook();
    this._initProperty();
    this._initFooter();
    /***
     * @name strictValue
     * @memberOf CheckTreeBox#
     * @type {boolean}
     */
}

CheckTreeBox.tag = 'CheckTreeBox'.toLowerCase();

CheckTreeBox.prototype.preLoadN = 3;
CheckTreeBox.prototype.itemHeight = 28;
CheckTreeBox.prototype.itemInPage = 36;

CheckTreeBox.prototype._initScroller = function () {
    this.$scroller = Object(ACore["a" /* $ */])('.as-check-tree-box-scroller', this)
        .on('scroll', this.eventHandler.scroll);
    this.itemInPage = Math.max(36, Math.ceil(Object(Dom["d" /* getScreenSize */])().height / this.itemHeight));
    this.$content = Object(ACore["a" /* $ */])('.as-check-tree-box-content', this);
    this.$pages = Object(ACore["b" /* $$ */])('.as-select-list-box-page', this);
    this.$pages.forEach(function (p) {
        p.__viewOffset__ = -1;
    })
};

CheckTreeBox.prototype._initDomHook = function () {
    this.$domSignal = Object(ACore["c" /* _ */])('attachhook');
    this.appendChild(this.$domSignal);
    this.domSignal = new DomSignal["a" /* default */](this.$domSignal);
    this.domSignal.on('viewListAt', this.viewListAt.bind(this));
};

CheckTreeBox.prototype._initProperty = function () {
    this._items = [];
    this._values = [];
    this.itemHolderByValue = {};
    /***
     *
     * @type {TreeNodeHolder[]}
     */
    this.rootHolders = [];
    /***
     *
     * @type {TreeNodeHolder[]}
     */
    this.holders = [];
    /***
     *
     * @type {TreeNodeHolder[]}
     */
    this.rootViewHolders = [];
    /***
     *
     * @type {TreeNodeHolder[]}
     */
    this.viewHolders = [];
    this.enableSearch = true;
};

CheckTreeBox.prototype._initControl = function () {
    this.cache = {};
    this.$searchInput = Object(ACore["a" /* $ */])('searchtextinput', this)
        .on('stoptyping', this.eventHandler.searchModify);
};


CheckTreeBox.prototype._initFooter = function () {
    this.$checkAll = Object(ACore["a" /* $ */])('.as-select-list-box-check-all', this)
        .on('change', this.eventHandler.checkAllChange);
    this.$cancelBtn = Object(ACore["a" /* $ */])('.as-select-list-box-cancel-btn', this)
        .on('click', this.eventHandler.clickCancelBtn);
};


CheckTreeBox.render = function () {
    return Object(ACore["c" /* _ */])({
        tag: 'follower',
        extendEvent: ['change', 'toggleitem', 'cancel'],
        class: ['as-check-tree-box', 'as-select-list-box', 'as-anchor-1'],
        child: [
            {
                class: 'as-select-list-box-search-ctn',
                child: 'searchtextinput'
            },
            {
                class: ['as-check-tree-box-scroller', 'as-bscroller', 'as-select-list-box-scroller'],
                child: {
                    class: ['as-check-tree-box-content', 'as-select-list-box-content'],
                    child: Array(this.prototype.preLoadN).fill('.as-select-list-box-page')
                }
            },
            {
                class: 'as-select-list-box-footer',
                child: [
                    {
                        tag: 'checkbox',
                        class: 'as-select-list-box-check-all',
                        props: {
                            checked: false,
                            text: 'Check All'
                        }
                    },
                    {
                        class: 'as-select-list-box-footer-right',
                        child: {
                            tag: 'a',
                            class: 'as-select-list-box-cancel-btn',
                            child: {text: 'Cancel'}
                        }
                    }
                ]
            }
        ]
    });
};

CheckTreeBox.prototype.HolderClass = TreeNodeHolder;

CheckTreeBox.prototype.depthIndexing = function (items, arr, rootArr) {
    var res = {};
    var count = 0;
    var self = this;
    var HolderClass = this.HolderClass;

    /***
     *
     * @param {TreeNodeHolder|null} root
     * @param items
     */
    function scan(root, items) {
        items.forEach(function visit(item) {
            var value = item.value + '';
            res[value] = res[value] || [];
            var node = new HolderClass(self, item, count++, root);
            res[value].push(node);
            arr && arr.push(node);
            if (root) {
                root.child.push(node);
            } else if (rootArr) {
                rootArr.push(node);
            }
            if (res[value].length > 1) {
                console.log("Duplicate value", res[value]);
            }
            if (item.items && item.items.length > 0)
                scan(node, item.items);
        });
    }

    scan(null, items);
    return res;
};

CheckTreeBox.prototype.findItemHoldersByValue = function (value) {
    return (this.itemHolderByValue[value] || []).slice();
};

CheckTreeBox.prototype.viewListAt = function (offset) {
    offset = offset || 0;
    if (!this.isDescendantOf(document.body)) {
        this.domSignal.emit('viewListAt', offset);
        return;
    }
    this.noTransition();

    var midPage = this.$pages.length >> 1;
    var startOffset = Math.max(0, offset - midPage * this.itemInPage);
    var cOffset;
    var itemN = this.viewHolders.length;
    for (var i = 0; i < this.$pages.length; ++i) {
        cOffset = startOffset + i * this.itemInPage;
        if (cOffset < itemN) {
            this.$pages[i].__viewOffset__ = cOffset;
            this.$pages[i].removeStyle('display')
                .addStyle('top', cOffset * this.itemHeight + 'px');
            this._fillPage(this.$pages[i], Math.min(this.itemInPage, itemN - cOffset));
            this._assignItems(this.$pages[i], cOffset);
        } else {
            this.$pages[i].__viewOffset__ = -1;
            this.$pages[i].addStyle('display', 'none');
        }
    }
};

CheckTreeBox.prototype.noTransition = function () {
    if (this.containsClass('as-no-transition')) return;
    this.addClass('as-no-transition');
    setTimeout(function () {
        this.removeClass('as-no-transition');
    }.bind(this), 100);
};


CheckTreeBox.prototype._pool = [];

CheckTreeBox.prototype._releaseItem = function (item) {
    if (item.nodeHolder && item.nodeHolder.itemElt === item) {
        item.nodeHolder.itemElt = null;
    }
    this._pool.push(item);
};

CheckTreeBox.prototype._requestItem = function () {
    return this._pool.pop() || Object(ACore["c" /* _ */])({
        tag: js_CheckTreeItem.tag,
        props: {
            menuElt: this
        },
        on: {
            presstoggle: function (event) {
                this.menuElt.eventHandler.toggleItem(this, event);
            },
            select: function (event) {
                this.menuElt.eventHandler.selectItem(this, event);
            }
        }
    });
};

CheckTreeBox.prototype._fillPage = function (pageElt, n) {
    while (pageElt.childNodes.length > n) {
        this._releaseItem(pageElt.lastChild);
        pageElt.removeChild(pageElt.lastChild);
    }
    while (pageElt.childNodes.length < n) {
        pageElt.addChild(this._requestItem());
    }
};

CheckTreeBox.prototype._assignItems = function (pageElt, offset) {
    for (var i = 0; i < pageElt.childNodes.length; ++i) {
        this.viewHolders[offset + i].itemElt = pageElt.childNodes[i];
    }
};


CheckTreeBox.prototype._resetView = function () {
    this.$searchInput.value = '';
    this.viewHolders = this.rootHolders.reduce(function (ac, holder) {
        return holder.toArray(ac)
    }, []);
    this.rootViewHolders = this.rootHolders;
    this.updateContentSize();
    this.viewListAt(0);
};

CheckTreeBox.prototype.resetSearchState = function () {
    this._resetView();
};

CheckTreeBox.prototype._calcEstimateSize = function () {
    this.estimateSize = {width: 0, height: 0};
    var holders = this.holders.slice();
    var n = holders.length;
    var holder;
    var longestHolder = null;
    var longest = 0;
    var w;
    for (var i = 0; i < n; ++i) {
        holder = holders[i];
        w = holder.calcEstimateWidth();
        if (w > longest) {
            longest = w;
            longestHolder = holder;
        }
    }

    if (longestHolder) {
        this.estimateSize.width = longestHolder.calcWidth();
        this.estimateSize.height = this.itemHeight * n;
    }
    this.addStyle('--select-list-estimate-width', this.estimateSize.width + 'px');

};

CheckTreeBox.prototype.updateContentSize = function () {
    this.$content.addStyle('height', this.viewHolders.length * this.itemHeight + 'px');
};

CheckTreeBox.prototype._updateToValues = function () {
    var values = [];
    this.rootHolders.forEach(function visit(node) {
        if (node.selected === 'all') {
            values.push(node.item.value);
        } else if (node.selected === 'child') {
            node.child.forEach(visit);
        }
    });
    this._values = values;
};


CheckTreeBox.prototype._updateFromValues = function () {
    var values = this._values;
    var valueDict = this._values.reduce(function (ac, cr) {
        ac[cr] = true;
        return ac;
    }, {});
    this.rootHolders.forEach(function visit(node) {
        var selectedAllCount = 0;
        var selectedChildCount = 0;
        var cNode;
        var value = node.item.value;
        if (valueDict[value]) {
            node.selectAll(true);
        } else {
            for (var i = 0; i < node.child.length; ++i) {
                cNode = node.child[i];
                visit(cNode);
                if (cNode.selected === 'all') {
                    selectedAllCount++;
                } else if (cNode.selected === 'child') {
                    selectedChildCount++;
                }
            }
            if (node.child > 0 && selectedAllCount === node.child.length) {
                node.selected = 'all';

            } else if (selectedAllCount + selectedChildCount > 0) {
                node.selected = 'child';
            } else {
                node.selected = 'none';
            }

            if (node.itemElt) node.itemElt.selected = node.selected;
        }
    });
    this.updateCheckedAll();
};


CheckTreeBox.prototype.updateCheckedAll = function () {
    var holders = this.rootHolders;
    if (holders.length === 0) return;
    var c = 0;
    for (var i = 0; i < holders.length; ++i) {
        if (holders[i].selected === 'all') c++;
        else break;
    }
    this.$checkAll.checked = c === holders.length;
};

CheckTreeBox.prototype._implicit = function (values) {
    return values || [];
};


CheckTreeBox.prototype._explicit = function (values) {
    return values;
};

CheckTreeBox.property = {};

CheckTreeBox.property.items = {
    /***
     * @this CheckTreeBox
     * @param items
     */
    set: function (items) {
        CPUViewer["a" /* default */].hold();
        this.cache = {};
        items = items || [];
        this._items = items;
        Object(search["c" /* prepareSearchForList */])(items);
        this.holders = [];
        this.itemHolderByValue = this.depthIndexing(items, this.holders, this.rootHolders);
        this._calcEstimateSize();
        this._resetView();
        this.values = this['values'];//update
        CPUViewer["a" /* default */].release();
    },
    get: function () {
        return this._items;
    }
};


CheckTreeBox.property.values = {
    /***
     * @this CheckTreeBox
     * @param values
     */
    set: function (values) {
        this._values = this._implicit(values);
        this._updateFromValues();

    },
    get: function () {
        return this._explicit(this._values);
    }
};

CheckTreeBox.property.viewValues = {
    get: function (){
        return this._values;
    }
};

CheckTreeBox.property.enableSearch = {
    set: function (value) {
        if (value) this.addClass('as-enable-search');
        else
            this.removeClass('as-enable-search');
    },
    get: function () {
        return this.containsClass('as-enable-search');
    }
};

CheckTreeBox.eventHandler = {};

CheckTreeBox.eventHandler.toggleItem = function (item, event) {
    this.noTransition();
    var nodeHolder = item.nodeHolder;
    if (!nodeHolder) {
        console.error("Load error, item was not assigned TreeNodeHolder!")
    } else
        nodeHolder.toggle();
};

CheckTreeBox.eventHandler.selectItem = function (item, event) {
    var nodeHolder = item.nodeHolder;
    if (!nodeHolder) {
        console.error("Load error, item was not assigned TreeNodeHolder!");
        return;
    }
    this.noTransition();
    CPUViewer["a" /* default */].hold();
    var ref = nodeHolder.findReferenceNode();
    var targetNode = ref || nodeHolder;
    var selected = item.selected;
    if (selected === 'all') {
        targetNode.selectAll();
    } else {
        targetNode.unselectAll();
    }
    if (ref) {
        nodeHolder.getRoot().updateSelectedFromRef();
    }
    this._updateToValues();
    this.updateCheckedAll();
    this.emit('change', {type: 'change', target: this}, this);
    CPUViewer["a" /* default */].release();
};

/***
 * @this CheckTreeBox
 */
CheckTreeBox.eventHandler.scroll = function () {
    CPUViewer["a" /* default */].hold();
    var scrollTop = this.$scroller.scrollTop;
    var scrollBottom = scrollTop + this.$scroller.clientHeight;
    var startOffset = this.$pages[0].__viewOffset__;
    var endOffset = this.$pages[this.$pages.length - 1].__viewOffset__;
    if (endOffset === -1) {
        endOffset = this.viewHolders.length;
    } else {
        endOffset += this.$pages[this.$pages.length - 1].childNodes.length;
    }

    var needLoad = 0;
    if (startOffset > 0 && startOffset * this.itemHeight + 200 > scrollTop)
        needLoad = -1;
    if (needLoad === 0 && this.viewHolders.length > endOffset && endOffset * this.itemHeight - 200 < scrollBottom) {
        needLoad = 1;
    }

    var page2Load;
    if (needLoad < 0) {
        page2Load = this.$pages.pop();
        this.$pages.unshift(page2Load);
        page2Load.__viewOffset__ = Math.max(0, startOffset - this.itemInPage);
        this._fillPage(page2Load, startOffset - page2Load.__viewOffset__);
        this._assignItems(page2Load, page2Load.__viewOffset__);
        page2Load.removeStyle('display');
        page2Load.addStyle('top', page2Load.__viewOffset__ * this.itemHeight + 'px');
    } else if (needLoad > 0) {
        for (var i = 0; i < this.$pages.length; ++i) {
            if (this.$pages[i].__viewOffset__ === -1) {
                page2Load = this.$pages[i];
                break;
            }
        }
        if (!page2Load) {
            page2Load = this.$pages.shift();
            this.$pages.push(page2Load);
        }
        page2Load.__viewOffset__ = endOffset;
        this._fillPage(page2Load, Math.min(this.itemInPage, this.viewHolders.length - endOffset));
        this._assignItems(page2Load, page2Load.__viewOffset__);
        page2Load.removeStyle('display');
        page2Load.addStyle('top', page2Load.__viewOffset__ * this.itemHeight + 'px');
    }
    CPUViewer["a" /* default */].release();
};


/***
 * @this CheckTreeBox
 */
CheckTreeBox.eventHandler.searchModify = function () {
    CPUViewer["a" /* default */].hold();
    var self = this;
    var text = this.$searchInput.value.trim();
    if (text.length === 0) {
        this._resetView();
        CPUViewer["a" /* default */].release();
        return;
    }
    var searchData;
    if (this.cache[text]) {
        searchData = this.cache[text];
    } else {
        searchData = {};
        searchData.items = Object(search["e" /* searchTreeListByText */])(text, this._items);
        searchData.rootViewHolders = [];
        var temp1 = [];
        var temp2 = [];
        self.depthIndexing(searchData.items, temp1);
        searchData.items.forEach(function visit(it) {
            if (it.ref.items && it.ref.items.length > 0 && (!it.items || it.items.length === 0)) {
                it.items = it.ref.items;
                it.doNotInitOpen = true;
            } else if (it.items && it.items.length > 0) {
                it.items.forEach(visit);
            }
        });
        self.depthIndexing(searchData.items, temp2, searchData.rootViewHolders);
        searchData.viewHolders = [];

        while (temp1.length > 0 && temp2.length > 0) {
            if (temp1[0].item === temp2[0].item) {
                searchData.viewHolders.push(temp2.shift());
                temp1.shift();
            } else {
                temp2.shift();
            }
        }
    }

    searchData.viewHolders.forEach(function (it) {
        if (it.status === 'close') {
            if (!it.item.doNotInitOpen)
                it.status = 'open';
        }
    });
    this.viewHolders = searchData.viewHolders.slice();
    this.rootViewHolders = searchData.rootViewHolders.slice();
    this.viewHolders.forEach(function (node) {
        var ref = node.findReferenceNode();
        node.selected = ref.selected;
        if (node.itemElt) node.itemElt.selected = node.selected;
    });

    this.updateContentSize();
    this.viewListAt(0);
    this.updatePosition();
    CPUViewer["a" /* default */].release();
};


CheckTreeBox.prototype.updateSelectedInViewIfNeed = function () {
    if (this.viewHolders.length > 0) {
        if (this.viewHolders[0].findReferenceNode()) {
            this.viewHolders.forEach(function (node) {
                var ref = node.findReferenceNode();
                node.selected = ref.selected;
                if (node.itemElt) node.itemElt.selected = node.selected;
            });
        }
    }
};


CheckTreeBox.eventHandler.checkAllChange = function (event) {
    CPUViewer["a" /* default */].hold();
    var checkedAll = this.$checkAll.checked;
    var changed = false;
    var holders = this.rootHolders;
    var holder;
    for (var i = 0; i < holders.length; ++i) {
        holder = holders[i];
        if (checkedAll) {
            if (holder.selected !== 'all') {
                holder.selectAll();
                changed = true;
            }
        } else {
            if (holder.selected !== 'none') {
                holder.unselectAll();
                changed = true;
            }
        }
    }
    if (this.rootViewHolders !== this.rootHolders) {
        this.rootViewHolders.forEach(function (holder) {
            holder.updateSelectedFromRef();
        });
    }

    if (changed) {
        this._updateToValues();
        this.emit('change', {type: 'change', target: this}, this);
    }

    CPUViewer["a" /* default */].release();
};


CheckTreeBox.eventHandler.clickCancelBtn = function (event) {
    this.emit('cancel', {type: 'cancel', target: this, originalEvent: event}, this);
};

ACore["d" /* default */].install(CheckTreeBox);


/* harmony default export */ var js_CheckTreeBox = (CheckTreeBox);


/***
 *
 * @param {CheckTreeBox} boxElt
 * @param {SelectionItem} item
 * @param {number} idx
 * @param {TreeNodeHolder} parent
 * @constructor
 */
function TreeNodeHolder(boxElt, item, idx, parent) {
    this.boxElt = boxElt;
    this.item = item;
    this.idx = idx;
    this.parent = parent;
    this.status = (item.items && item.items.length > 0) ? 'close' : 'none';
    this.selected = 'none';
    /***
     *
     * @type {TreeNodeHolder[]}
     */
    this.child = [];
    this.level = parent ? parent.level + 1 : 0;
    this._elt = null;
}


TreeNodeHolder.prototype.findIdxInView = function () {
    var holders = this.boxElt.viewHolders;
    var start = 0;
    var end = holders.length - 1;
    var mid;
    var idx = this.idx;
    var holderIdx;
    while (start < end) {
        mid = (start + end) >> 1;
        holderIdx = holders[mid].idx;
        if (holderIdx < idx) {
            start = mid + 1;
        } else if (holderIdx > idx) {
            end = mid - 1;
        } else {
            return mid;
        }
    }
    holderIdx = holders[start].idx;
    if (holderIdx === idx)
        return start;
    return -1;
};

TreeNodeHolder.prototype.toggle = function () {
    CPUViewer["a" /* default */].hold();
    var idx = this.findIdxInView();
    var status = this.status;
    if (status === 'close') {
        this.itemElt.status = 'open';
        this.status = 'open';
        var arr = this.toArray();
        arr.shift();
        this.boxElt.viewHolders.splice.apply(this.boxElt.viewHolders, [idx + 1, 0].concat(arr));
        this.boxElt.updateContentSize();
        this.boxElt.viewListAt(idx);
        this.boxElt.emit('toggleitem', {
            type: 'toggleiteion',
            target: this.boxElt,
            nodeHolder: this,
            status: 'open'
        }, this.boxElt);
    } else if (status === 'open') {
        this.itemElt.status = 'close';
        this.status = 'close';
        var l = 0;
        while (this.boxElt.viewHolders[idx + 1 + l] && this.boxElt.viewHolders[idx + 1 + l].isDescendantOf(this)) ++l;
        this.boxElt.viewHolders.splice(idx + 1, l);
        this.boxElt.updateContentSize();
        this.boxElt.viewListAt(idx);
        this.boxElt.emit('toggleitem', {
            type: 'toggleiteion',
            target: this.boxElt,
            nodeHolder: this,
            status: 'close'
        }, this.boxElt);
    }

    CPUViewer["a" /* default */].release();
};


/***
 *
 * @param {boolean=} isDownUpdate
 */
TreeNodeHolder.prototype.selectAll = function (isDownUpdate) {
    if (this.selected === 'all') return;
    this.selected = 'all';
    if (this.itemElt) this.itemElt.selected = this.selected;
    this.child.forEach(function (child) {
        child.selectAll(true);
    });
    if (!isDownUpdate) {
        if (this.parent) this.parent.updateUp();
    }
};


/***
 *
 * @param {boolean=} isDownUpdate
 */
TreeNodeHolder.prototype.unselectAll = function (isDownUpdate) {
    if (this.selected === 'none') return;
    this.selected = 'none';
    if (this.itemElt) this.itemElt.selected = this.selected;
    this.child.forEach(function (child) {
        child.unselectAll(true);
    });
    if (!isDownUpdate) {
        if (this.parent) this.parent.updateUp();
    }
};

TreeNodeHolder.prototype.updateUp = function () {
    var childSelectAll = 0;
    var childSelectChild = 0;
    if (this.child.length > 0) {
        for (var i = 0; i < this.child.length; ++i) {
            if (this.child[i].selected === 'all') {
                childSelectAll++;
            }
            else if (this.child[i].selected === 'child') {
                childSelectChild++;
            }
        }
        if (childSelectAll === this.child.length) {
            this.selected = 'all';
        }
        else if (childSelectChild + childSelectAll > 0) {
            this.selected = 'child';
        }
        else {
            this.selected = 'none';
        }
        if (this.itemElt) {
            this.itemElt.selected = this.selected;
        }
    }

    if (this.parent) this.parent.updateUp();
};

TreeNodeHolder.prototype.calcEstimateWidth = function () {
    var width = 12;//padding
    width += 12 * this.level;
    width += 14.7 + 5;//toggle icon
    width += 16;//checkbox
    if (this.item.icon) width += 21;//icon
    width += 7 + Object(utils["estimateWidth14"])(this.item.text);//margin-text
    if (this.item.desc) width += 6 + Object(utils["estimateWidth14"])(this.item.desc) * 0.85;
    return width;
};

TreeNodeHolder.prototype.calcWidth = function () {
    var width = 12;//padding
    width += 12 * this.level;
    width += 14.7 + 5;//toggle icon
    width += 16;//checkbox
    if (this.item.icon) width += 21;//icon
    width += 7 + Object(utils["measureText"])(this.item.text, '14px arial').width;//margin-text
    if (this.item.desc) width += 6 + Object(utils["measureText"])(this.item.desc, '11.9px arial').width * 0.85;
    return width;
};

TreeNodeHolder.prototype.isDescendantOf = function (parent) {
    var cr = this.parent;
    while (cr) {
        if (parent === cr) return true;
        cr = cr.parent;
    }
    return false;
};


/***
 *
 * @param {TreeNodeHolder[]=} ac
 * @return {TreeNodeHolder[]}
 */
TreeNodeHolder.prototype.toArray = function (ac) {
    ac = ac || [];
    ac.push(this);
    if (this.status === 'open') {
        for (var i = 0; i < this.child.length; ++i) {
            this.child[i].toArray(ac);
        }
    }
    return ac;
};

Object.defineProperty(TreeNodeHolder.prototype, 'itemElt', {
    set: function (elt) {
        if (this._elt === elt) return;

        if (this._elt) {
            if (this._elt.nodeHolder === this) {
                this._elt.nodeHolder = null;
            }
        }

        if (elt) {
            if (elt.nodeHolder) {
                elt.nodeHolder.itemElt = null;
            }

            elt.nodeHolder = this;
            this._elt = elt;
            elt.data = this.item;
            elt.level = this.level;
            elt.status = this.status;
            elt.selected = this.selected;
        }
        else {
            this._elt = null;
        }
    },
    get: function () {
        return this._elt;
    }
});


TreeNodeHolder.prototype.findReferenceNode = function () {
    var value = this.item.value;
    var holders = this.boxElt.findItemHoldersByValue(value);
    var holder;
    for (var i = 0; i < holders.length; ++i) {
        holder = holders[i];
        if ((holder.item === this.item.ref || holder.item === this.item) && holder !== this) return holder;
    }
    return null;
};

TreeNodeHolder.prototype.getRoot = function () {
    if (!this.parent) return this;
    return this.parent.getRoot();
};

TreeNodeHolder.prototype.updateSelectedFromRef = function () {
    var ref = this.findReferenceNode();
    if (!ref) return;
    var selected = ref.selected;
    this.selected = selected;
    if (this.itemElt) this.itemElt.selected = selected;
    this.child.forEach(function (c) {
        c.updateSelectedFromRef();
    });
};


// CONCATENATED MODULE: ./node_modules/absol-acomp/js/CheckTreeLeafOnlyBox.js





/***
 * Only tree has leaf can be selected
 * @extends CheckTreeBox
 * @constructor
 */
function CheckTreeLeafOnlyBox() {
    js_CheckTreeBox.apply(this, arguments);
}


CheckTreeLeafOnlyBox.tag = 'CheckTreeLeafOnlyBox'.toLowerCase();


CheckTreeLeafOnlyBox.render = function () {
    return Object(ACore["c" /* _ */])({
        tag: 'follower',
        extendEvent: ['change', 'toggleitem', 'cancel'],
        class: ['as-check-tree-leaf-only-box', 'as-check-tree-box', 'as-select-list-box', 'as-anchor-1'],
        child: [
            {
                class: 'as-select-list-box-search-ctn',
                child: 'searchtextinput'
            },
            {
                class: ['as-check-tree-box-scroller', 'as-bscroller', 'as-select-list-box-scroller'],
                child: {
                    class: ['as-check-tree-box-content', 'as-select-list-box-content'],
                    child: Array(this.prototype.preLoadN).fill('.as-select-list-box-page')
                }
            },
            {
                class: 'as-select-list-box-footer',
                child: [
                    {
                        tag: 'checkbox',
                        class: 'as-select-list-box-check-all',
                        props: {
                            checked: false,
                            text: 'Check All'
                        }
                    },
                    {
                        class: 'as-select-list-box-footer-right',
                        child: {
                            tag: 'a',
                            class: 'as-select-list-box-cancel-btn',
                            child: {text: 'Cancel'}
                        }
                    }
                ]
            }
        ]
    });
};


Object.assign(CheckTreeLeafOnlyBox.prototype, js_CheckTreeBox.prototype);
CheckTreeLeafOnlyBox.property = Object.assign({}, js_CheckTreeBox.property);
CheckTreeLeafOnlyBox.eventHandler = Object.assign({}, js_CheckTreeBox.eventHandler);

CheckTreeLeafOnlyBox.prototype._pool = [];


CheckTreeLeafOnlyBox.prototype._requestItem = function () {
    return this._pool.pop() || Object(ACore["c" /* _ */])({
        tag: js_CheckTreeItem.tag,
        class: 'as-check-tree-leaf-only-item',
        props: {
            menuElt: this
        },
        on: {
            presstoggle: function (event) {
                this.menuElt.eventHandler.toggleItem(this, event);
            },
            select: function (event) {
                this.menuElt.eventHandler.selectItem(this, event);
            }
        }
    });
};

CheckTreeLeafOnlyBox.prototype.HolderClass = TreeLeafOnlyNodeHolder;


CheckTreeLeafOnlyBox.prototype.depthIndexing = function (items, arr, rootArr) {
    var res = {};
    var count = 0;
    var self = this;
    var HolderClass = this.HolderClass;

    /***
     *
     * @param {TreeLeafOnlyNodeHolder|null} root
     * @param items
     */
    function scan(root, items) {
        items.forEach(function visit(item) {
            var value = item.value + '';
            res[value] = res[value] || [];
            var node = new HolderClass(self, item, count++, root);
            res[value].push(node);
            arr && arr.push(node);
            if (root) {
                root.child.push(node);
            } else if (rootArr) {
                rootArr.push(node);
            }
            if (res[value].length > 1) {
                console.log("Duplicate value", res[value]);
            }
            if (item.items && item.items.length > 0)
                scan(node, item.items);
            if (item.isLeaf) {
                if (!item.items || item.items.length === 0) {
                    node.leafCount = 1;
                } else {
                    console.error("Invalid item", item);
                }
            }
            if (root) {
                root.leafCount += node.leafCount;
            }
            if (node.leafCount === 0) {
                node.selected = 'empty';

            }
        });
    }

    scan(null, items);
    return res;
};


CheckTreeLeafOnlyBox.prototype._updateFromValues = function () {
    var valueDict = this.values.reduce(function (ac, cr) {
        ac[cr] = true;
        return ac;
    }, {});
    this.rootHolders.forEach(function visit(node) {
        var selectedAllCount = 0;
        var selectedChildCount = 0;
        var emptyChildCount = 0;
        var cNode;
        var value = node.item.value;
        if (valueDict[value]) {
            node.selectAll(true);
        } else {
            for (var i = 0; i < node.child.length; ++i) {
                cNode = node.child[i];
                visit(cNode);
                if (cNode.selected === 'all') {
                    selectedAllCount++;
                } else if (cNode.selected === 'child') {
                    selectedChildCount++;
                } else if (cNode.selected === 'empty') {
                    emptyChildCount++;
                }
            }

            if (node.child > 0 && selectedAllCount > 0 && selectedAllCount + emptyChildCount === node.child.length) {
                node.selected = 'all';
            } else if (selectedAllCount + selectedChildCount > 0) {
                node.selected = 'child';
            } else if (node.selected !== 'empty') {
                node.selected = 'none';
            }

            if (node.itemElt) node.itemElt.selected = node.selected;
        }
    });
    this.updateCheckedAll();
};



ACore["d" /* default */].install(CheckTreeLeafOnlyBox);

/* harmony default export */ var js_CheckTreeLeafOnlyBox = (CheckTreeLeafOnlyBox);


/***
 * @extends TreeNodeHolder
 * @constructor
 */
function TreeLeafOnlyNodeHolder() {
    TreeNodeHolder.apply(this, arguments);
    /***
     * @memberOf  TreeLeafOnlyNodeHolder#
     * @type {number}
     */
    this.leafCount = 0;
}

OOP["a" /* default */].mixClass(TreeLeafOnlyNodeHolder, TreeNodeHolder);


/***
 *
 * @param {boolean=} isDownUpdate
 */
TreeLeafOnlyNodeHolder.prototype.selectAll = function (isDownUpdate) {
    if (this.selected === 'empty') return;
    return TreeNodeHolder.prototype.selectAll.apply(this, arguments);
};

TreeLeafOnlyNodeHolder.prototype.unselectAll = function (isDownUpdate) {
    if (this.selected === 'empty') return;
    return TreeNodeHolder.prototype.unselectAll.apply(this, arguments);
};


TreeLeafOnlyNodeHolder.prototype.updateUp = function () {
    var childSelectAll = 0;
    var childSelectChild = 0;
    var childEmpty = 0;
    if (this.child.length > 0) {
        for (var i = 0; i < this.child.length; ++i) {
            if (this.child[i].selected === 'all') {
                childSelectAll++;
            } else if (this.child[i].selected === 'child') {
                childSelectChild++;
            } else if (this.child[i].selected === 'empty') {
                childEmpty++;
            }
        }
        if (childEmpty === this.child.length) {

            this.selected = 'empty';
        } else if (childSelectAll + childEmpty === this.child.length) {
            this.selected = 'all';
        } else if (childSelectChild + childSelectAll > 0) {
            this.selected = 'child';
        } else {
            this.selected = 'none';
        }
        if (this.itemElt) {
            this.itemElt.selected = this.selected;
        }
    }

    if (this.parent) this.parent.updateUp();
};





// CONCATENATED MODULE: ./node_modules/absol-acomp/js/MultiCheckTreeMenu.js












/***
 * @extends AElement
 * @constructor
 */
function MultiCheckTreeMenu() {
    this._items = [];
    this._values = [];
    this._viewValues = [];
    /***
     * @type {CheckTreeBox|CheckTreeLeafOnlyBox}
     */
    this.$checkTreeBox = Object(ACore["c" /* _ */])({
        tag: js_CheckTreeBox.tag,
        on: {
            change: this.eventHandler.boxChange,
            preupdateposition: this.eventHandler.preUpdateListPosition,
            toggleitem: this.eventHandler.boxToggleItem,
            cancel: this.eventHandler.boxCancel
        }
    });
    this.$itemCtn = Object(ACore["a" /* $ */])('.as-multi-select-menu-item-ctn', this);
    this.$checkTreeBox.followTarget = this;
    this.on('click', this.eventHandler.click);

    this.enableSearch = false;

    /**
     * @name leafOnly
     * @type {boolean}
     * @memberOf MultiCheckTreeMenu#
     */
}


MultiCheckTreeMenu.tag = 'MultiCheckTreeMenu'.toLowerCase();

MultiCheckTreeMenu.render = function () {
    return Object(ACore["c" /* _ */])({
        class: ['as-multi-select-menu', 'as-multi-check-tree-menu'],
        extendEvent: ['change'],
        attr: {
            tabindex: '1'
        },
        child: [
            {
                class: ['as-multi-select-menu-item-ctn', 'as-bscroller']
            },
            {
                tag: 'button',
                class: 'as-multi-select-menu-toggle-btn',
                child: 'dropdown-ico'
            },
            'attachhook'
        ]
    });
};

MultiCheckTreeMenu.prototype.tokenPool = [];

MultiCheckTreeMenu.prototype._requestToken = function () {
    var token = this.tokenPool.pop();
    if (!token) {
        token = Object(ACore["c" /* _ */])({
            tag: SelectBoxItem["a" /* default */].tag,
            props: {
                menu: this
            },
            on: {
                close: function (event) {
                    setTimeout(function () {
                        if (this.menu) this.menu.eventHandler.pressCloseToken(this, event);
                    }.bind(this), 1)
                }
            }
        });
    }
    return token;
};

MultiCheckTreeMenu.prototype._releaseToken = function (token) {
    token.menu = null;
    this.tokenPool.push(token);
};

MultiCheckTreeMenu.prototype._filToken = function (n) {
    while (this.$itemCtn.childNodes.length > n) {
        this.$itemCtn.removeChild(this.$itemCtn.lastChild);
    }
    while (this.$itemCtn.childNodes.length < n) {
        this.$itemCtn.addChild(this._requestToken());
    }
};


MultiCheckTreeMenu.prototype._assignTokens = function (items) {
    for (var i = 0; i < items.length; ++i) {
        this.$itemCtn.childNodes[i].data = items[i];
    }
};


MultiCheckTreeMenu.prototype._switchLeafMode = function () {
    var enableSearch = this.enableSearch;
    if (this.leafOnly) {
        this.$checkTreeBox = Object(ACore["c" /* _ */])({
            tag: js_CheckTreeLeafOnlyBox.tag,
            on: {
                change: this.eventHandler.boxChange,
                preupdateposition: this.eventHandler.preUpdateListPosition,
                toggleitem: this.eventHandler.boxToggleItem,
                cancel: this.eventHandler.boxCancel
            }
        });
        this._explicit = this._leafOnlyExplicit;

    } else {
        this.$checkTreeBox = Object(ACore["c" /* _ */])({
            tag: js_CheckTreeBox.tag,
            on: {
                change: this.eventHandler.boxChange,
                preupdateposition: this.eventHandler.preUpdateListPosition,
                toggleitem: this.eventHandler.boxToggleItem,
                cancel: this.eventHandler.boxCancel
            }
        });
        this._explicit = this._normalExplicit;

    }
    this.$checkTreeBox.followTarget = this;
    this.$checkTreeBox.items = this._items;
    this.$checkTreeBox.values = this._values;
    this.$checkTreeBox.enableSearch = enableSearch;
};


MultiCheckTreeMenu.prototype._implicit = function (values) {
    values = (values || []);
    var valueDict = (values || []).reduce(function (ac, cr) {
        ac[cr + ''] = true;
        return ac;
    }, {});

    var resDict = {};

    function depthRemoveValueDict(node) {
        if (valueDict[node.value]) delete valueDict[node.value];
        if (node.items && node.items.length) {
            node.items.forEach(depthRemoveValueDict);
        }
    }

    var leafOnly = this.leafOnly;
    var scan;
    var leafCount = {};
    var leafScan;
    if (leafOnly) {
        leafScan = function (node) {
            if (node.isLeaf) {
                leafCount[node.value] = 1;
            } else {
                leafCount[node.value] = 0;
            }
            if (node.items && node.items.length > 0) {
                if (!node.isLeaf) {
                    node.items.forEach(leafScan);
                    leafCount[node.value] = node.items.reduce(function (ac, cr) {
                        return ac + (leafCount[cr.value] || 0);
                    }, 0);
                } else {
                    console.error("Invalid item:", node);
                }
            }
        };
        this._items.forEach(leafScan);
        scan = function scan(node) {
            if (!leafCount[node.value]) {
                depthRemoveValueDict(node);
                return true;
            }
            if (valueDict[node.value] && leafCount[node.value] > 0) return true;
            if (!node.items || node.items.length === 0) return false;
            var cs = node.items.map(scan);
            if (cs.every(function (e) {
                return e
            })) {
                depthRemoveValueDict(node);
                return true;
            } else {
                node.items.forEach(function (nd, i) {
                    if (cs[i] && leafCount[nd.value] > 0) resDict[nd.value] = nd;
                });
                return false;
            }
        };
    } else {
        scan = function scan(node) {
            if (valueDict[node.value]) {
                depthRemoveValueDict(node);
                return true;
            }
            if (!node.items || node.items.length === 0) return false;
            var cs = node.items.map(scan);
            if (cs.every(function (e) {
                return e
            })) {
                depthRemoveValueDict(node);
                return true;
            } else {
                node.items.forEach(function (nd, i) {
                    if (cs[i]) resDict[nd.value] = nd;
                });
                return false;
            }
        };
    }

    var csRoot = this._items.map(scan);

    this._items.forEach(function (nd, i) {
        if (csRoot[i] && (!leafOnly || leafCount[nd.value] > 0)) resDict[nd.value] = nd;
    });

    var eValues = values.reduce(function (ac, cr) {
        if (valueDict[cr.value]) ac.push(cr.value);
        return ac;
    }, []);
    for (var key in resDict) {
        eValues.push(resDict[key].value);
    }

    return eValues;
};


MultiCheckTreeMenu.prototype._normalExplicit = function (values) {
    return (values || []).slice();
};


MultiCheckTreeMenu.prototype._leafOnlyExplicit = function (values) {
    var valueDict = values.reduce(function (ac, cr) {
        ac[cr] = true;
        return ac;
    }, {});
    var res = [];

    function scan(node, selected) {
        selected = selected || valueDict[node.value];
        if (node.isLeaf  && selected) res.push(node.value);
        if (node.items && node.items.length > 0 ){
            node.items.forEach(function (cNode){
                scan(cNode, selected);
            })
        }
    }

    this._items.forEach(function (node){
        scan(node, false);
    });

    return res;
};


MultiCheckTreeMenu.prototype._explicit = MultiCheckTreeMenu.prototype._normalExplicit;


MultiCheckTreeMenu.prototype.findItemsByValues = function (values) {
    return values.map(function (value) {
        var holders = this.$checkTreeBox.findItemHoldersByValue(value);
        if (holders.length > 0) return holders[0].item;
        return null;
    }.bind(this)).filter(function (it) {
        return !!it;
    });
};


MultiCheckTreeMenu.prototype.viewValues = function (values) {
    var items = this.findItemsByValues(values);
    this._filToken(items.length);
    this._assignTokens(items);
    this._viewValues = values;
    if (this.isFocus) {
        var bound = this.getBoundingClientRect();
        this.$checkTreeBox.addStyle('min-width', bound.width + 'px');
        ResizeSystem["a" /* default */].update();
    }
};

MultiCheckTreeMenu.prototype.commitView = function () {
    var values = this._values;
    var views = this._viewValues;
    var changed = values.length !== views.length;
    var viewDict;
    if (!changed) {
        viewDict = views.reduce(function (ac, cr) {
            ac[cr] = true;
            return ac;
        }, {});
        changed = values.some(function (value) {
            return !viewDict[value];
        });
    }
    if (changed) {
        this._values = views.slice();
        this.emit('change', {type: 'change', target: this}, this);
    }
};

MultiCheckTreeMenu.prototype.cancelView = function () {
    this.$checkTreeBox.values = this._values;
    this.viewValues(this._values)
};

MultiCheckTreeMenu.prototype.init = function (props) {
    props = props || {};
    var cProps = Object.assign({}, props);
    if ('leafOnly' in props) {
        this.leafOnly = props.leafOnly;
        delete cProps.leafOnly;
    }
    if ('items' in props) {
        this.items = props.items;
        delete cProps.items;
    }
    if ('values' in props) {
        this.values = props.values;
        delete cProps.values;
    }

    Object.assign(this, cProps);
}


MultiCheckTreeMenu.property = {};

MultiCheckTreeMenu.property.isFocus = {
    /***
     * @this MultiCheckTreeMenu
     * @param value
     */
    set: function (value) {
        var self = this;
        value = !!value;
        var c = this.containsClass('as-focus');
        if (value === c) return;
        CPUViewer["a" /* default */].hold();
        if (value) {
            self.off('click', self.eventHandler.click);
            var bound = this.getBoundingClientRect();
            this.$checkTreeBox.addStyle('min-width', bound.width + 'px');
            this.addClass('as-focus');
            document.body.appendChild(this.$checkTreeBox);
            this.$checkTreeBox.updatePosition();
            if (this._focusTimeout > 0) {
                clearTimeout(this._focusTimeout);
            }
            this._focusTimeout = setTimeout(function () {
                document.addEventListener('mousedown', this.eventHandler.clickOut);
                this._focusTimeout = -1;
            }.bind(this));

        } else {
            this.removeClass('as-focus');
            this.$checkTreeBox.selfRemove();
            this.$checkTreeBox.resetSearchState();
            document.removeEventListener('mousedown', this.eventHandler.clickOut);

            function waitMouseUp() {
                document.removeEventListener('mouseup', waitMouseUp);
                setTimeout(function () {
                    self.on('click', self.eventHandler.click);
                }, 5)
            }

            document.addEventListener('mouseup', waitMouseUp);
        }
        CPUViewer["a" /* default */].release();
    },
    get: function () {
        return this.containsClass('as-focus');
    }
};

MultiCheckTreeMenu.property.items = {
    set: function (items) {
        this._items = items || [];
        this.$checkTreeBox.items = this._items;
        this.addStyle('--list-min-width', this.$checkTreeBox.estimateSize.width + 'px');
        this.values = this._values;//update
    },
    get: function () {
        return this.$checkTreeBox.items;
    }
};

MultiCheckTreeMenu.property.values = {
    /***
     * @this MultiCheckTreeMenu
     * @param values
     */
    set: function (values) {
        values = this._implicit(values || []);
        this.$checkTreeBox.values = values;
        this._values = values;
        values = this.$checkTreeBox.values.slice();//correct wrong item
        this.viewValues(values);
    },
    /***
     * @this MultiCheckTreeMenu
     */
    get: function () {
        return this._explicit(this._values);
    }
};

MultiCheckTreeMenu.property.leafOnly = {
    set: function (value) {
        if (!!value === this.containsClass('as-leaf-only'))
            return;
        if (value) {
            this.addClass('as-leaf-only');
        } else {
            this.removeClass('as-leaf-only');
        }
        this._switchLeafMode();
    },
    get: function () {
        return this.containsClass('as-leaf-only');
    }
};


MultiCheckTreeMenu.property.disabled = MultiSelectMenu["a" /* default */].property.disabled;


MultiCheckTreeMenu.eventHandler = {};

/***
 * @this MultiCheckTreeMenu
 * @param event
 */
MultiCheckTreeMenu.eventHandler.clickOut = function (event) {
    if (event.target === this || event.target === this.$itemCtn || (!Object(EventEmitter["d" /* hitElement */])(this, event) && !Object(EventEmitter["d" /* hitElement */])(this.$checkTreeBox, event))) {
        this.commitView();
        this.isFocus = false;
    }
};


/***
 * @this MultiCheckTreeMenu
 * @param event
 */
MultiCheckTreeMenu.eventHandler.click = function (event) {
    if (event.target === this || event.target === this.$itemCtn) {
        this.isFocus = true;
    }
};


/***
 * @this MultiCheckTreeMenu
 * @param event
 */
MultiCheckTreeMenu.eventHandler.boxChange = function (event) {
    this.viewValues(this.$checkTreeBox.values);
    ResizeSystem["a" /* default */].update();
};

MultiCheckTreeMenu.eventHandler.boxCancel = function (event) {
    this.cancelView();
    this.isFocus = false;
};


/***
 * @this MultiCheckTreeMenu
 * @param {SelectBoxItem} tokenElt
 * @param event
 */
MultiCheckTreeMenu.eventHandler.pressCloseToken = function (tokenElt, event) {
    var value = tokenElt.value;
    var holders = this.$checkTreeBox.findItemHoldersByValue(value);
    holders.forEach(function (holder) {
        holder.unselectAll();
    });
    this.$checkTreeBox.updateCheckedAll();
    this.$checkTreeBox.updateSelectedInViewIfNeed();
    var newValues = this._viewValues.filter(function (v) {
        return v !== value;
    });
    if (this.isFocus) {
        this.viewValues(newValues);
    } else {
        this.values = newValues;
        this.emit('change', {type: 'change', target: this}, this);
    }
};


MultiCheckTreeMenu.eventHandler.preUpdateListPosition = function () {
    var bound = this.getBoundingClientRect();
    var screenSize = Object(Dom["d" /* getScreenSize */])();
    var availableTop = bound.top - 5;
    var availableBot = screenSize.height - 5 - bound.bottom;
    this.$checkTreeBox.addStyle('--max-height', Math.max(availableBot, availableTop) + 'px');
    var outBound = Object(Dom["f" /* traceOutBoundingClientRect */])(this);
    if (bound.bottom < outBound.top || bound.top > outBound.bottom || bound.right < outBound.left || bound.left > outBound.right) {
        this.isFocus = false;
    }
};

MultiCheckTreeMenu.eventHandler.boxToggleItem = function (event) {
    var bound = this.getBoundingClientRect();
    var screenSize = Object(Dom["d" /* getScreenSize */])();
    var availableTop = bound.top - 5;
    var availableBot = screenSize.height - 5 - bound.bottom;
    this.$checkTreeBox.addStyle('--max-height', (this.$checkTreeBox._lastAnchor < 4 ? availableBot : availableTop) + 'px');
    this.$checkTreeBox.updatePosition();
};


MultiCheckTreeMenu.property.enableSearch = {
    set: function (value) {
        this.$checkTreeBox.enableSearch = !!value;
    },
    get: function () {
        return this.$checkTreeBox.enableSearch;
    }
};


ACore["d" /* default */].install(MultiCheckTreeMenu);

/* harmony default export */ var js_MultiCheckTreeMenu = (MultiCheckTreeMenu);

// MultiCheckTreeMenu.prototype.




// EXTERNAL MODULE: ./node_modules/absol-acomp/css/fileinputbox.css
var fileinputbox = __webpack_require__(294);

// EXTERNAL MODULE: ./node_modules/absol-acomp/assets/exticons/catalog.json
var catalog = __webpack_require__(76);

// EXTERNAL MODULE: ./node_modules/absol/src/Network/FileSaver.js
var FileSaver = __webpack_require__(51);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/FileInputBox.js








/***
 * @extends AElement
 * @constructor
 */
function FileInputBox() {
    this.$fileSize = Object(ACore["a" /* $ */])('.as-file-input-box-file-size', this);
    this.$fileName = Object(ACore["a" /* $ */])('.as-file-input-box-file-name', this);
    this.$bg = Object(ACore["a" /* $ */])('.as-file-input-box-background', this);
    this.$input = Object(ACore["a" /* $ */])('input', this)
        .on('change', this.eventHandler.input_fileChange);
    this.$trigger = Object(ACore["c" /* _ */])({
        elt: Object(ACore["a" /* $ */])('.as-file-input-box-trigger', this),
        tag: js_DropZone.tag,
        on: {
            fileenter: this.eventHandler.input_fileEnter,
            fileleave: this.eventHandler.input_fileLeave,
            filedrop: this.eventHandler.input_fileDrop,

        }
    });
    this.$downloadBtn = Object(ACore["a" /* $ */])('.as-file-input-box-download-btn', this)
        .on('click', this.download.bind(this));
    this.$removeBtn = Object(ACore["a" /* $ */])('.as-file-input-box-remove-btn', this)
        .on('click', this.clearValue.bind(this, true));

    this.allowUpload = true;
    this._value = null;
    this.value = this._value;
    this._fileSize = null;
    this.fileSize = null;
    this._fileName = null;
    this.fileName = null;
    this._fileType = null;
    this.fileType = null;
    this.downloadable = false;
}


FileInputBox.tag = 'FileInputBox'.toLowerCase();

FileInputBox.render = function () {
    return Object(ACore["c" /* _ */])({
        extendEvent: ['change'],
        class: 'as-file-input-box',
        child: [
            '.as-file-input-box-background',
            {
                tag: 'label',
                class: 'as-file-input-box-trigger',
                child: {
                    tag: 'input',
                    attr: {
                        type: 'file',
                        accept: '*',
                        title: null
                    }
                }
            },

            {
                class: 'as-file-input-box-upload-overlay',
                child: 'span.mdi.mdi-upload'
            },
            {
                class: 'as-file-input-box-info',
                child: [
                    {tag: 'span', class: 'as-file-input-box-file-name', child: {text: ''}},
                    'br',
                    {tag: 'span', class: 'as-file-input-box-file-size', child: {text: ''}},
                ]
            },
            {
                class: 'as-file-input-box-action-left',
                child: {
                    tag: 'button',
                    class: 'as-file-input-box-remove-btn',
                    child: 'span.mdi.mdi-close'
                }
            },
            {
                class: 'as-file-input-box-action-right',
                child: {
                    tag: 'button',
                    class: 'as-file-input-box-download-btn',
                    child: 'span.mdi.mdi-download'
                }
            },

        ]
    });
};


FileInputBox.prototype.download = function () {
    var value = this.value;
    if (value) {
        if (value && value.name && value.url){
            Object(FileSaver["saveAs"])(value.url, value.name);
        }
        else {
            Object(FileSaver["saveAs"])(value, this.fileName);
        }
    }
};

FileInputBox.prototype.clearValue = function (userAction, event) {
    if (this.value) {
        this.value = null;
        if (userAction){
            this.emit('change', {
                type: 'change',
                originalEvent: event,
                action: 'clear',
                target: this
            }, this);
        }
    }
}

FileInputBox.property = {};

FileInputBox.property.value = {
    set: function (value) {
        value = value || null;
        var type = null;
        var size = null;
        var name = null;
        if ((value instanceof File) || (value instanceof Blob)) {
            size = value.size;
            name = value.name;
            type = name.split('.').pop().toLowerCase();

        } else if (Object(utils["isURLAddress"])(value)) {
            type = value.replace(/\.upload$/, '').split('.').pop();
            name = value.split('/').pop().replace(/%20/g, ' ');
            this.attr('title', value);
        }
        else if (value && value.name && value.url){//keeview file format
            this.attr('title', value.url);
            name = value.name;
            type = name.split('.').pop().toLowerCase();
        }
        this._value = value;
        this.fileSize = size;
        this.fileName = name;
        this.fileType = type;
        if (value) {
            this.addClass('as-has-value');
        } else {
            this.removeClass('as-has-value');
        }
    },
    get: function () {
        return this._value;
    }
};


FileInputBox.property.fileType = {
    set: function (value) {
        if (value) {
            if (catalog.indexOf(value) >= 0)
                this.$bg.addStyle('backgroundImage', 'url(' + MessageInput["b" /* default */].iconAssetRoot + '/' + value + '.svg)')
            else
                this.$bg.addStyle('backgroundImage', 'url(' + MessageInput["b" /* default */].iconAssetRoot + '/' + 'blank' + '.svg)')
        } else {
            this.$bg.removeStyle('backgroundImage')
        }
    },
    get: function () {
        return this._fileType;
    }
};

FileInputBox.property.fileName = {
    set: function (value) {
        value = typeof value === 'string' ? value : null;
        if (value) {
            this.$fileName.firstChild.data = value;
            this.addClass('as-has-file-name');
        } else {
            this.$fileName.firstChild.data = '';
            this.removeClass('as-has-file-name');
        }
        this._fileName = value;
    },
    get: function () {
        return this._fileName;
    }
};

FileInputBox.property.fileSize = {
    set: function (value) {
        if (Object(utils["isRealNumber"])(value)) value = Math.max(0, value);
        else value = null;
        if (value === null) {
            this.$fileSize.firstChild.data = '';
            this.removeClass('as-has-file-size');
        } else {
            this.$fileSize.firstChild.data = Object(utils["fileSize2Text"])(value);
            this.addClass('as-has-file-size');
        }
        this._fileSize = value;
    },
    get: function () {
        return this._fileSize;
    }
};

FileInputBox.property.allowUpload = {
    set: function (value) {
        if (value) {
            this.addClass('as-allow-upload');
        } else {
            this.removeClass('as-allow-upload');
        }
    },
    get: function () {
        return this.containsClass('as-allow-upload');
    }
};

FileInputBox.property.downloadable = {
    set: function (value) {
        if (value) {
            this.addClass('as-downloadable');
        } else {
            this.removeClass('as-downloadable');
        }
    },
    get: function () {
        return this.containsClass('as-downloadable');
    }
};


FileInputBox.property.removable = {
    set: function (value) {
        if (value) {
            this.addClass('as-removable');
        } else {
            this.removeClass('as-removable');
        }
    },
    get: function () {
        return this.containsClass('as-removable');
    }
};


FileInputBox.property.accept = {
    set: function (value) {
        if (!value) value = null;
        this.$input.attr('accept', value + '');
    },
    get: function () {
        return this.$input.attr('accept') || null;
    }
};


FileInputBox.eventHandler = {};

FileInputBox.eventHandler.input_fileChange = function (event) {
    var files = Array.prototype.slice.call(this.$input.files);
    if (files.length > 0) {
        this.value = files[0];
        this.emit('change', {
            type: 'change',
            originalEvent: event,
            file: files[0],
            action: 'file_dialog',
            target: this
        }, this);
    }
};

FileInputBox.eventHandler.input_fileEnter = function (event) {
};

FileInputBox.eventHandler.input_fileLeave = function (event) {
};

FileInputBox.eventHandler.input_fileDrop = function (event) {
    var files = Array.prototype.slice.call(event.files);
    var accept = this.accept;
    var file;
    if (files.length > 0) {
        file = files[0];
        if (!Object(utils["fileAccept"])(accept, file.type) && !Object(utils["fileAccept"])(accept, file.name)) file = null;
    }
    if (file) {
        this.value = file;
        this.emit('change', {type: 'change', originalEvent: event, file: file, action: 'drop', target: this}, this);
    }

};


ACore["d" /* default */].install(FileInputBox);

/* harmony default export */ var js_FileInputBox = (FileInputBox);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/countdowntext.css
var countdowntext = __webpack_require__(296);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/CountdownText.js






var CountdownText_ = ACore["d" /* default */]._;
var CountdownText_$ = ACore["d" /* default */].$;


/***
 * @extends AElement
 * @constructor
 */
function CountdownText() {
    this.addClass('as-countdown-text');
    this.defineEvent('update');
    this.defineEvent('finish');
    this.text = '';
    this._formatTokens = {};
    this._format = 'HH:mm';
    this.format = 'HH:mm';
    this.fps = 5;
    this._finishTime = null;
    this.finishTime = null;
    this['_tick'] = this._tick.bind(this);
    setTimeout(this.start.bind(this), 0);//auto start
}

CountdownText.tag = 'CountdownText'.toLowerCase();


CountdownText.render = function () {
    return CountdownText_('span');
};


CountdownText.prototype._tick = function () {
    var remainSecond = this.remainSecond;
    var prevText = this.text;
    var newText;
    var format = this._format;
    var tokens = this._formatTokens;
    var sec, min, hour;
    if (typeof format === "function") {
        newText = format.call(this, remainSecond);
    } else {
        sec = Math[(tokens['ms'] || tokens['mss']) ? 'floor' : 'ceil'](remainSecond);
        min = Math.floor(remainSecond / 60);
        hour = Math.floor(remainSecond / 60 / 60);
        newText = format.replace(new RegExp(datetime["DATE_TIME_TOKEN_RGX"].source, 'g'), function (all) {
            switch (all) {
                case 'D':
                    return Math.floor(remainSecond / 60 / 60 / 24) + '';
                case 'HH':
                case 'H':
                case 'hh':
                    if (tokens['D']) {
                        return Object(utils["zeroPadding"])(hour % 24, all.length);
                    } else {
                        return Object(utils["zeroPadding"])(hour, all.length);
                    }
                case 'mm':
                case 'M':
                case 'MM':
                    if (tokens['HH'] || tokens['hh']) {
                        return Object(utils["zeroPadding"])(min % 60, all.length);
                    } else {
                        return Object(utils["zeroPadding"])(min, all.length);
                    }
                case 'ss':
                case 'S':
                case 'SS':
                    if (tokens['m'] || tokens['mm']) {
                        return Object(utils["zeroPadding"])(sec % 60, all.length);
                    } else {
                        return Object(utils["zeroPadding"])(sec, all.length);
                    }
                case 'cs':
                    return Object(utils["zeroPadding"])(Math.ceil(remainSecond * 100) % 100, 2);
                case 'ms':
                    return Object(utils["zeroPadding"])(Math.ceil(remainSecond * 1000) % 1000, 3);
                default:
                    return all;
            }
        });
    }

    if (prevText !== newText) {
        this.text = newText;
        this.innerHTML = newText;
        this.emit('update', {target: this, type: 'update'}, this);
    }


    if (remainSecond <= 0) {
        this.stop();
        this.emit('finish', {target: this, type: 'update'}, this);
    }
};

CountdownText.prototype.start = function () {
    this.resume();
};

CountdownText.prototype.resume = function () {
    if (this._intvId > 0) return;
    this._intvId = setInterval(this._tick, 1000 / this.fps);
};

CountdownText.prototype.pause = function () {
    if (this._intvId > 0) {
        clearInterval(this._intvId);
        this._intvId = -1;
    }
};

CountdownText.prototype.stop = function () {
    this.pause();

};


CountdownText.property = {};

CountdownText.property.format = {
    set: function (value) {
        if (typeof value === "string" || typeof value === 'function') {
            this._format = value || 'HH:mm';
            this._formatTokens = (this._format.match(new RegExp(datetime["DATE_TIME_TOKEN_RGX"].source, 'g')) || []).reduce(function (ac, cr) {
                ac[cr] = true;
                return ac;
            }, {})
        } else {
            this._formatTokens = {};
            this._format = 'HH:mm';
        }
    },
    get: function () {
        return this._format;
    }
};

CountdownText.property.remainSecond = {
    set: function (value) {
        if (!(value >= 0)) {
            value = 0;
        }
        this.finishTime = new Date(new Date().getTime() + value)
    },
    get: function () {
        if (this.finishTime !== null) {
            return Math.max(0, (this.finishTime.getTime() - new Date().getTime()) / 1000);
        } else return null;
    }
};

CountdownText.property.finishTime = {
    set: function (value) {
        if (typeof value === "number" || typeof value === 'string') {
            value = new Date(value);
        }
        if (!value || !value.getTime) value = null;
        if (value && value.getTime && isNaN(value.getTime())) value = null;
        this._finishTime = value;
    },
    get: function () {
        return this._finishTime;
    }
};

CountdownText.property.fps = {
    set: function (value) {
        this._fps = Object(utils["isRealNumber"])(value) ? value : 200;
        if (this._intvId > 0) {
            clearInterval(this._intvId);
            this._intvId = setInterval(this._tick, 1000 / this._fps);
        }
    },
    get: function () {
        return this._fps;
    }
};


ACore["d" /* default */].install(CountdownText);

/* harmony default export */ var js_CountdownText = (CountdownText);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/messagedialog.css
var messagedialog = __webpack_require__(298);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/YesNoQuestionDialog.js





/***
 * @extends AElement
 * @constructor
 */
function YesNoQuestionDialog() {
    this.$yesBtn = Object(ACore["a" /* $ */])('.as-message-dialog-yes-btn', this)
        .on('click', this.eventHandler.action.bind(null, 'yes'));
    this.$noBtn = Object(ACore["a" /* $ */])('.as-message-dialog-no-btn', this)
        .on('click', this.eventHandler.action.bind(null, 'no'));
    this.$title = Object(ACore["a" /* $ */])('.as-message-dialog-title', this);
    this.$message = Object(ACore["a" /* $ */])('.as-message-dialog-message', this);
}

YesNoQuestionDialog.tag = 'YesNoQuestionDialog'.toLowerCase();

YesNoQuestionDialog.render = function () {
    return Object(ACore["c" /* _ */])({
        extendEvent: ['action'],
        class: 'as-message-dialog',
        child: [
            {
                class: 'as-message-dialog-header',
                child: {
                    tag: 'span',
                    class: 'as-message-dialog-title',
                    child: {text: ''}
                }
            },
            {
                class: 'as-message-dialog-body',
                child: {
                    tag: 'span',
                    class: 'as-message-dialog-message',
                    child: {text: ''}
                }
            },
            {
                class: 'as-message-dialog-footer',
                child: [
                    {
                        tag: js_FlexiconButton.tag,
                        class: ['as-message-dialog-no-btn', 'secondary'],
                        props: {
                            text: 'No'
                        }
                    },
                    {
                        tag: js_FlexiconButton.tag,
                        class: ['as-message-dialog-yes-btn', 'primary'],
                        props: {
                            text: 'Yes'
                        }
                    }
                ]
            }
        ]
    });
};

YesNoQuestionDialog.eventHandler = {};


YesNoQuestionDialog.eventHandler.action = function (action, event) {
    this.emit('action', {type: 'action', target: this, originalEvent: event, action: action}, this);
};

YesNoQuestionDialog.property = {};

YesNoQuestionDialog.property.dialogTitle = {
    set: function (value) {
        value = (value || '') + '';
        this.$title.firstChild.data = value;
    },
    get: function () {
        return this.$title.firstChild.data;
    }
};

YesNoQuestionDialog.property.message = {
    set: function (value) {
        value = (value || '') + '';
        this.$message.firstChild.data = value;
    },
    get: function () {
        return this.$message.firstChild.data;
    }
};

YesNoQuestionDialog.property.textYes = {
    set: function (value) {
        value = (value || 'Yes') + '';
        this.$yesBtn.text = value;
    },
    get: function () {
        return this.$yesBtn.text;
    }
};


YesNoQuestionDialog.property.textNo = {
    set: function (value) {
        value = (value || 'No') + '';
        this.$noBtn.text = value;
    },
    get: function () {
        return this.$noBtn.text;
    }
};


ACore["d" /* default */].install(YesNoQuestionDialog);


/* harmony default export */ var js_YesNoQuestionDialog = (YesNoQuestionDialog);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/LoadingCubeModal.js




/***
 * @extends Modal
 * @constructor
 */
function LoadingCubeModal() {

}

LoadingCubeModal.tag = 'LoadingCubeModal'.toLowerCase();

LoadingCubeModal.render = function () {
    return Object(ACore["c" /* _ */])({
        tag:'modal',
        class: 'as-loading-cube-modal',
        child: '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" style="margin: auto; background: rgb(241, 242, 243); display: block; shape-rendering: auto;" width="200px" height="200px" viewBox="0 0 100 100" preserveAspectRatio="xMidYMid">\n' +
            '<g transform="translate(26.666666666666668,26.666666666666668)">\n' +
            '  <rect x="-20" y="-20" width="40" height="40" fill="#13a9df">\n' +
            '    <animateTransform attributeName="transform" type="scale" repeatCount="indefinite" dur="1s" keyTimes="0;1" values="1.1500000000000001;1" begin="-0.3s"></animateTransform>\n' +
            '  </rect>\n' +
            '</g>\n' +
            '<g transform="translate(73.33333333333333,26.666666666666668)">\n' +
            '  <rect x="-20" y="-20" width="40" height="40" fill="#4be44c">\n' +
            '    <animateTransform attributeName="transform" type="scale" repeatCount="indefinite" dur="1s" keyTimes="0;1" values="1.1500000000000001;1" begin="-0.2s"></animateTransform>\n' +
            '  </rect>\n' +
            '</g>\n' +
            '<g transform="translate(26.666666666666668,73.33333333333333)">\n' +
            '  <rect x="-20" y="-20" width="40" height="40" fill="#e2d58b">\n' +
            '    <animateTransform attributeName="transform" type="scale" repeatCount="indefinite" dur="1s" keyTimes="0;1" values="1.1500000000000001;1" begin="0s"></animateTransform>\n' +
            '  </rect>\n' +
            '</g>\n' +
            '<g transform="translate(73.33333333333333,73.33333333333333)">\n' +
            '  <rect x="-20" y="-20" width="40" height="40" fill="#e1e7e7">\n' +
            '    <animateTransform attributeName="transform" type="scale" repeatCount="indefinite" dur="1s" keyTimes="0;1" values="1.1500000000000001;1" begin="-0.1s"></animateTransform>\n' +
            '  </rect>\n' +
            '</g>\n' +
            '</svg>'
    });
};

LoadingCubeModal.share = {
    token: null,
    $elt: null
};

/***
 *
 * @return {String}
 */
LoadingCubeModal.show = function (){
    if (!LoadingCubeModal.share.$elt) LoadingCubeModal.share.$elt = Object(ACore["c" /* _ */])(LoadingCubeModal.tag);
    if (!LoadingCubeModal.share.$elt.isDescendantOf(document.body)){
        document.body.appendChild(LoadingCubeModal.share.$elt);
    }
    LoadingCubeModal.share.token = Object(stringGenerate["randomIdent"])(9);
    return LoadingCubeModal.share.token;
};

/***
 *
 * @param {String} token
 * @return {Boolean}
 */
LoadingCubeModal.close = function (token){
  if (LoadingCubeModal.share.$elt &&LoadingCubeModal.share.$elt.isDescendantOf(document.body) && (!token || token ===LoadingCubeModal.share.token)){
      this.share.$elt.remove();
      LoadingCubeModal.share.token  = null;
      return  true;
  }
  return  false;
};



ACore["d" /* default */].install(LoadingCubeModal);

/* harmony default export */ var js_LoadingCubeModal = (LoadingCubeModal);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/selecttreeleafmenu.css
var selecttreeleafmenu = __webpack_require__(98);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/SelectTreeLeafBox.js








function isBranchStatus(status) {
    return status === 'open' || status === 'close';
}

function invertStatus(status) {
    return {open: 'close', close: 'open'}[status] || 'none';
}


/***
 * @extends Follower
 * @constructor
 */
function SelectTreeLeafBox() {
    this._initControl();
    this._searchCache = {};
    this._value = null;
    this._items = [];
    this.strictValue = true;
    this.$items = [];
    this.$itemByValue = {};
    this.$selectedItem = null;

    this.$dislayItems = this.$items;
    this.$dislayItemByValue = this.$itemByValue;

    this.$content = Object(ACore["a" /* $ */])('.as-select-tree-leaf-box-content', this);
    this._savedStatus = {};
    this.estimateSize = {width: 0, height: 0};
}


SelectTreeLeafBox.tag = 'SelectTreeLeafBox'.toLowerCase();

SelectTreeLeafBox.render = function () {
    return Object(ACore["c" /* _ */])({
        tag: Follower["a" /* default */], attr: {
            tabindex: 0
        }, class: ['as-select-tree-leaf-box', 'as-select-list-box'], extendEvent: ['pressitem'], child: [{
            class: 'as-select-list-box-search-ctn', child: 'searchtextinput'
        }, {
            class: ['as-bscroller', 'as-select-list-box-scroller', 'as-select-tree-leaf-box-content'], child: []
        }, 'attachhook.as-dom-signal']
    });
};


SelectTreeLeafBox.prototype._initControl = function () {
    this.$searchInput = Object(ACore["a" /* $ */])('searchtextinput', this)
        .on('stoptyping', this.eventHandler.searchModify);
};


SelectTreeLeafBox.prototype.resetSearchState = function () {
    var value = this.$searchInput.value;
    if (value.length > 0) {
        this.$searchInput.value = '';
        if (value.trim().length) {
            this.$content.clearChild();
            this.$content.addChild(this.$items);
            this.$dislayItems = this.$items;
            this.$dislayItemByValue = this.$itemByValue;
            this._updateSelectedItem();
        }
    }
};


SelectTreeLeafBox.prototype._findFirstLeaf = function () {
    var found = false;

    function visit(item) {
        if (item.isLeaf) {
            found = item;
            return true;
        }
        if (item.items && item.items.length > 0) {
            item.items.some(visit);
        }
        return !!found;
    }

    this._items.some(visit);
    return found;
};

SelectTreeLeafBox.prototype._makeTree = function (item, dict, savedStatus) {
    var self = this;
    var status = 'none';
    var isLeaf = item.isLeaf;
    if (item.items && item.items.length > 0) {
        status = 'close';
    }
    if (isBranchStatus(status) && isBranchStatus(savedStatus[item.value])) {
        status = savedStatus[item.value];
    }

    var nodeElt = Object(ACore["c" /* _ */])({
        tag: ExpTree["c" /* default */].tag, class: 'as-select-tree-leaf-item', props: {
            name: item.text, desc: item.desc, icon: item.icon, status: status,
            itemData: item
        }
    });
    nodeElt.getNode().on({
        press: function (event) {
            if (isBranchStatus(nodeElt.status)) {
                nodeElt.status = invertStatus(nodeElt.status)
                savedStatus[item.value] = nodeElt.status;
            } else if (isLeaf) {
                self.emit('pressitem', {item: item, target: self, itemElt: nodeElt, originalEvent: event}, self);
            }
        }
    });
    if (dict) {
        if (dict[item.value] && !this.warned) {
            this.warned = true;
            console.warn(this, 'has duplicated value, element will not work correctly!', item);
        }
        dict[item.value] = nodeElt;
    }
    if (item.isLeaf) {
        nodeElt.addClass('as-is-leaf');
    }

    if (item.items && item.items.length > 0) {
        item.items.forEach(function (item1) {
            nodeElt.addChild(self._makeTree(item1, dict, savedStatus));
        });
    }

    return nodeElt;
};

SelectTreeLeafBox.prototype._estimateItemWidth = function (item, level) {
    var width = 12;//padding
    width += 12 * level;
    width += 14.7 + 5;//toggle icon
    if (item.icon) width += 21;//icon
    width += 7 + Object(utils["estimateWidth14"])(item.text) + 5 + 7;//margin-text
    if (item.desc) width += 6 + Object(utils["estimateWidth14"])(item.desc) * 0.85;
    return width;
};

SelectTreeLeafBox.prototype.viewToSelected = function () {
    var selectedNode = this.$selectedItem;
    if (!selectedNode) return;
    selectedNode.scrollIntoView();
    var parent = selectedNode.getParent();
    while (parent && parent.getParent) {
        if (parent.status === 'close') {
            parent.getNode().emit('press');
        }
        parent = parent.getParent();
    }

};

SelectTreeLeafBox.prototype._calcEstimateSize = function (items) {
    var self = this;
    var width = 0;
    var height = 0;

    function visit(item, level) {
        var itemWidth = self._estimateItemWidth(item, level);
        width = Math.max(width, itemWidth);
        height += 28;
        if (item.items && item.items.length) {
            item.items.forEach(function (item) {
                visit(item, level + 1);
            });
        }
    }

    items.forEach(function (item) {
        visit(item, 0);
    });

    return {
        width: width,
        height: height
    };
};

SelectTreeLeafBox.prototype._updateSelectedItem = function () {
    if (this.$selectedItem) {
        this.$selectedItem.removeClass('as-selected');
        this.$selectedItem = null;
    }
    this.$selectedItem = this.$dislayItemByValue[this._value];
    if (this.$selectedItem) {
        this.$selectedItem.addClass('as-selected');
    }
};

SelectTreeLeafBox.property = {};

SelectTreeLeafBox.eventHandler = {};


SelectTreeLeafBox.property.items = {
    /***
     * @this SelectTreeLeafBox
     * @param items
     */
    set: function (items) {
        var self = this;
        this._savedStatus = {};
        this._searchCache = {};
        items = items || [];
        this._items = items;
        Object(search["c" /* prepareSearchForList */])(items);
        this.$content.clearChild();
        this.$itemByValue = {};
        this.$dislayItemByValue = this.$itemByValue;

        this.$items = items.map(function (item) {
            return self._makeTree(item, self.$itemByValue, self._savedStatus);
        });
        this.$dislayItems = this.$items;
        this.$content.addChild(this.$items);
        this.estimateSize = this._calcEstimateSize(items);
        this.addStyle('--select-list-estimate-width', this.estimateSize.width + 'px');
        var firstLeaf;
        if (this._value === null || this._value === undefined || (this.strictValue && !this.$itemByValue[this._value])) {
            firstLeaf = this._findFirstLeaf();
            if (firstLeaf) {
                this.value = firstLeaf.value;
            }
        }
        this._updateSelectedItem();
    }, get: function () {
        return this._items;
    }
};

SelectTreeLeafBox.property.value = {
    set: function (value) {
        this._value = value;
        this._updateSelectedItem();
    }, get: function () {
        return this._value;
    }
};

SelectTreeLeafBox.property.enableSearch = SelectListBox["b" /* default */].property.enableSearch;

SelectTreeLeafBox.prototype._search = function (query) {
    var self = this;
    var queryItem = Object(search["b" /* default */])({text: query});
    var minScore = Infinity;
    var maxScore = -Infinity;

    function makeScoreTree(item) {
        var holder = {
            item: item, score: Object(search["a" /* calcItemMatchScore */])(queryItem, item), childrenScore: 0, children: []
        };
        minScore = Math.min(minScore, holder.score);
        maxScore = Math.max(maxScore, holder.score);

        var children;
        if (item.items && item.items.length > 0) {
            children = item.items.map(makeScoreTree);
            holder.children = children;
            holder.childrenScore = holder.children.reduce(function (ac, cr) {
                return Math.max(ac, cr.score, cr.childrenScore);
            }, 0);
        }
        return holder;
    }

    var treeScores = this._items.map(makeScoreTree);
    var midScore = (maxScore + minScore) / 2;
    var savedStatus = {};

    function filterTree(scoredTrees, ignore) {
        return scoredTrees.filter(function (holder) {
            return ignore || holder.score >= midScore || holder.childrenScore >= midScore;
        }).map(function makeTree(holder) {
            var item = Object.assign({}, holder.item);
            if (!ignore && holder.children && holder.children.length > 0) {
                if (holder.childrenScore >= midScore) {
                    savedStatus[item.value] = 'open';
                    item.items = filterTree(holder.children, false);
                } else {
                    savedStatus[item.value] = 'close';
                    item.items = filterTree(holder.children, true);
                }
            }
            return item;
        });
    }

    var resultItems = filterTree(treeScores, false);
    var dict = {};
    var $items = resultItems.map(function (item) {
        return self._makeTree(item, dict, savedStatus);
    });
    return {
        $items: $items,
        items: resultItems,
        savedStatus: Object.assign({}, savedStatus),
        originSavedStatus: savedStatus,
        dict: dict
    };
}

/***
 * @this SelectTreeLeafBox
 */
SelectTreeLeafBox.eventHandler.searchModify = function () {
    var query = this.$searchInput.value.trim();
    if (query.length === 0) {
        this.$content.clearChild().addChild(this.$items);
        this.$dislayItemByValue = this.$itemByValue;
        this.$dislayItems = this.$items;
        this._updateSelectedItem();
        return;
    }
    if (!this._searchCache[query]) {
        this._searchCache[query] = this._search(query);
    }
    var searchData = this._searchCache[query];
    searchData.savedStatus = Object.assign(searchData.savedStatus, searchData.originSavedStatus);
    for (var val in searchData.dict) {
        if (isBranchStatus(searchData.dict[val].status)) {
            if (searchData.savedStatus[val]) {
                searchData.dict[val].status = searchData.savedStatus[val]
            }
        }
    }
    this.$content.clearChild()
        .addChild(searchData.$items);
    this.$dislayItemByValue = searchData.dict;
    this.$dislayItems = searchData.$items;
    this._updateSelectedItem();
};


ACore["d" /* default */].install(SelectTreeLeafBox);

/* harmony default export */ var js_SelectTreeLeafBox = (SelectTreeLeafBox);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/SelectTreeLeafMenu.js








/***
 * @extends AElement
 * @constructor
 */
function SelectTreeLeafMenu() {
    this.$selectBox = Object(ACore["c" /* _ */])({
        tag: js_SelectTreeLeafBox.tag,
        on: {
            pressitem: this.eventHandler.pressItem,
            preupdateposition: this.eventHandler.preUpdateListPosition
        }
    });
    OOP["a" /* default */].drillProperty(this, this.$selectBox, 'enableSearch');
    this.$selectBox.followTarget = this;
    this.$holderItem = Object(ACore["a" /* $ */])('selectlistitem', this);
    this.on('click', this.eventHandler.click.bind(this));
}

SelectTreeLeafMenu.tag = 'SelectTreeLeafMenu'.toLowerCase();

SelectTreeLeafMenu.render = function () {
    return Object(ACore["c" /* _ */])({
        class: ['absol-selectmenu', 'as-select-menu', 'as-select-tree-leaf-menu'],
        extendEvent: ['change'],
        attr: {
            tabindex: '1'
        },
        child: [
            {
                class: 'absol-selectmenu-holder-item',
                child: 'selectlistitem'
            },
            {
                tag: 'button',
                class: 'absol-selectmenu-btn',
                child: ['dropdown-ico']
            }
        ]
    });
};


SelectTreeLeafMenu.prototype.init = function (props) {
    props = props || {};
    Object.keys(props).forEach(function (key) {
        if (props[key] === undefined) delete props[key];
    });
    if (props.strictValue) {
        this.strictValue = props.strictValue;
        delete props.strictValue;
    }

    var hasValue = 'value' in props;
    var value = props.value;
    delete props.value;
    this.super(props);
    if (hasValue)
        this.value = value;
};


SelectTreeLeafMenu.property = {};

SelectTreeLeafMenu.property.items = {
    set: function (items) {
        items = items || [];
        this.$selectBox.items = items;
        this.addStyle('--select-list-estimate-width', this.$selectBox.estimateSize.width + 'px');
        if (this.$selectBox.$selectedItem) {
            this.$holderItem.data = this.$selectBox.$selectedItem.itemData;
        } else {
            this.$holderItem.data = {text:''};
        }
    },
    get: function () {
        return this.$selectBox.items;
    }
};

SelectTreeLeafMenu.property.value = {
    set: function (value) {
        this.$selectBox.value = value;
        if (this.$selectBox.$selectedItem) {
            this.$holderItem.data = this.$selectBox.$selectedItem.itemData;
        } else {
            this.$holderItem.data = {text:''};
        }
    },
    get: function () {
        return this.$selectBox.value;
    }
};

SelectTreeLeafMenu.property.strictValue = {
    set: function (value) {
        this.$selectBox.strictValue = !!value;
        if (value) this.addClass('as-strict-value');
        else this.removeClass('as-strict-value');
    },
    get: function () {
        return this.containsClass('as-strict-value');
    }
};


SelectTreeLeafMenu.property.isFocus = {
    /**
     * @this SelectTreeLeafMenu
     * @param value
     */
    set: function (value) {
        value = !!value;
        var isFocus = this.containsClass('as-focus');
        if (value === isFocus) return;
        var bound;
        if (value) {
            this.addClass('as-focus');
            bound = this.getBoundingClientRect();
            this.$selectBox.addStyle('min-width', bound.width + 'px');
            document.body.appendChild(this.$selectBox);
            this.$selectBox.updatePosition();
            this.off('click', this.eventHandler.click);
            setTimeout(function () {
                document.addEventListener('click', this.eventHandler.clickOut);
            }.bind(this), 5);
            this.$selectBox.viewToSelected();
        } else {
            this.removeClass('as-focus');
            document.removeEventListener('click', this.eventHandler.clickOut);
            this.$selectBox.remove();
            setTimeout(function () {
                this.on('click', this.eventHandler.click);
            }.bind(this), 100);
            this.$selectBox.resetSearchState();
        }
    },
    get: function () {
        return this.containsClass('as-focus');
    }
};

SelectTreeLeafMenu.property.disabled = SelectMenu2["a" /* default */].property.disabled;


SelectTreeLeafMenu.eventHandler = {};

SelectTreeLeafMenu.eventHandler.clickOut = function (event) {
    if (Object(EventEmitter["d" /* hitElement */])(this.$selectBox, event)) return;
    this.isFocus = false;
};


SelectTreeLeafMenu.eventHandler.click = function (event) {
    this.isFocus = true;
};

SelectTreeLeafMenu.eventHandler.pressItem = function (event) {
    this.$selectBox.value = event.item.value;
    this.$holderItem.data = event.item;
    var prevValue = this._value;
    this._value = event.item.value;
    this.isFocus = false;
    if (prevValue !== this._value) {
        this.emit('change', {
            item: event,
            type: 'change',
            target: this,
            originalEvent: event.originalEvent || event.originalEvent || event
        }, this);
    }
};

SelectTreeLeafMenu.eventHandler.preUpdateListPosition = function () {
    var bound = this.getBoundingClientRect();
    var screenSize = Object(Dom["d" /* getScreenSize */])();
    var availableTop = bound.top - 5;
    var availableBot = screenSize.height - 5 - bound.bottom;
    this.$selectBox.addStyle('--max-height', Math.max(availableBot, availableTop) + 'px');
    var outBound = Object(Dom["f" /* traceOutBoundingClientRect */])(this);
    if (bound.bottom < outBound.top || bound.top > outBound.bottom || bound.right < outBound.left || bound.left > outBound.right) {
        this.isFocus = false;
    }
};


ACore["d" /* default */].install(SelectTreeLeafMenu);
/* harmony default export */ var js_SelectTreeLeafMenu = (SelectTreeLeafMenu);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/MultiCheckTreeLeafBox.js










function MultiCheckTreeLeafBox_isBranchStatus(status) {
    return status === 'open' || status === 'close';
}

function MultiCheckTreeLeafBox_invertStatus(status) {
    return {open: 'close', close: 'open'}[status] || 'none';
}


/***
 * @extends Follower
 * @constructor
 */
function MultiCheckTreeLeafBox() {
    this._initControl();
    this._searchCache = {};
    this._items = [];
    this._values = [];
    this.strictValue = true;
    this.$items = [];
    this.$itemByValue = {};

    this.$dislayItems = this.$items;
    this.$dislayItemByValue = this.$itemByValue;

    this.$content = Object(ACore["a" /* $ */])('.as-select-tree-leaf-box-content', this);
    this._savedStatus = {};
    this.estimateSize = {width: 0, height: 0};
}


MultiCheckTreeLeafBox.tag = 'MultiCheckTreeLeafBox'.toLowerCase();

MultiCheckTreeLeafBox.render = function () {
    return Object(ACore["c" /* _ */])({
        tag: Follower["a" /* default */],
        attr: {
            tabindex: 0
        },
        class: ['as-select-tree-leaf-box', 'as-select-list-box'],
        extendEvent: ['change'],
        child: [
            {
                class: 'as-select-list-box-search-ctn', child: 'searchtextinput'
            },
            {
                class: ['as-bscroller', 'as-select-list-box-scroller', 'as-select-tree-leaf-box-content'],
                child: []
            },
            'attachhook.as-dom-signal'
        ]
    });
};


MultiCheckTreeLeafBox.prototype._initControl = function () {
    this.$searchInput = Object(ACore["a" /* $ */])('searchtextinput', this)
        .on('stoptyping', this.eventHandler.searchModify);
};


MultiCheckTreeLeafBox.prototype.resetSearchState = function () {
    var value = this.$searchInput.value;
    if (value.length > 0) {
        this.$searchInput.value = '';
        if (value.trim().length) {
            this.$content.clearChild();
            this.$content.addChild(this.$items);
            this.$dislayItems = this.$items;
            this.$dislayItemByValue = this.$itemByValue;
            this._updateSelectedItems();
        }
    }
};


MultiCheckTreeLeafBox.prototype._findFirstLeaf = function () {
    var found = false;

    function visit(item) {
        if (item.isLeaf) {
            found = item;
            return true;
        }
        if (item.items && item.items.length > 0) {
            item.items.some(visit);
        }
        return !!found;
    }

    this._items.some(visit);
    return found;
};

MultiCheckTreeLeafBox.prototype._makeTree = function (item, dict, savedStatus) {
    var self = this;
    var status = 'none';
    var isLeaf = item.isLeaf;
    if (item.items && item.items.length > 0) {
        status = 'close';
    }
    if (MultiCheckTreeLeafBox_isBranchStatus(status) && MultiCheckTreeLeafBox_isBranchStatus(savedStatus[item.value])) {
        status = savedStatus[item.value];
    }

    var treeElt = Object(ACore["c" /* _ */])({
        tag: ExpTree["c" /* default */].tag, class: 'as-select-tree-leaf-item', props: {
            name: item.text, desc: item.desc, icon: item.icon, status: status,
            itemData: item
        }
    });
    var nodeElt = treeElt.getNode().on({
        press: function (event) {
            if (MultiCheckTreeLeafBox_isBranchStatus(treeElt.status)) {
                treeElt.status = MultiCheckTreeLeafBox_invertStatus(treeElt.status)
                savedStatus[item.value] = treeElt.status;
            } else if (isLeaf) {
                if (!Object(EventEmitter["d" /* hitElement */])(checkboxElt, event)) {
                    var checked = !checkboxElt.checked;
                    checkboxElt.checked = checked;
                    var idx = self._values.indexOf(item.value);
                    var changed = false;
                    if (checked && idx < 0) {
                        changed = true;
                        self._values.push(item.value);
                    } else if (!checked && idx >= 0) {
                        changed = true;
                        self._values.splice(idx, 1);
                    }

                    if (changed)
                        self.emit('change', {
                            item: item,
                            target: self,
                            itemElt: treeElt,
                            originalEvent: event
                        }, self);
                }
            }
        }
    });
    var checkboxElt = null;
    if (isLeaf) {
        checkboxElt = Object(ACore["c" /* _ */])({
            tag: CheckBoxInput["a" /* default */].tag, on: {
                change: function (event) {
                    var checked = checkboxElt.checked;
                    var idx = self._values.indexOf(item.value);
                    var changed = false;
                    if (checked && idx < 0) {
                        changed = true;

                        self._values.push(item.value);
                    } else if (!checked && idx >= 0) {
                        changed = true;

                        self._values.splice(idx, 1);
                    }
                    if (changed)
                        self.emit('change', {
                            item: item,
                            target: self,
                            itemElt: treeElt,
                            originalEvent: event
                        }, self);
                }
            }
        });
        nodeElt.addChildAfter(checkboxElt, nodeElt.$toggleIcon);
        treeElt.$checkbox = checkboxElt;
    }

    if (dict) {
        if (dict[item.value] && !this.warned) {
            this.warned = true;
            console.warn(this, 'has duplicated value, element will not work correctly!', item);
        }
        dict[item.value] = treeElt;
    }
    if (isLeaf) {
        treeElt.addClass('as-is-leaf');
    }

    if (item.items && item.items.length > 0) {
        item.items.forEach(function (item1) {
            treeElt.addChild(self._makeTree(item1, dict, savedStatus));
        });
    }

    return treeElt;
};

MultiCheckTreeLeafBox.prototype._estimateItemWidth = function (item, level) {
    var width = 12;//padding
    width += 12 * level;
    width += 14.7 + 5;//toggle icon
    if (item.icon) width += 21;//icon
    width += 7 + Object(utils["estimateWidth14"])(item.text) + 5 + 7;//margin-text
    if (item.desc) width += 6 + Object(utils["estimateWidth14"])(item.desc) * 0.85;
    if (item.isLeaf) width += 16;
    return width;
};

MultiCheckTreeLeafBox.prototype.viewToSelected = function () {
    var selectedNode = this.$selectedItem;
    if (!selectedNode) return;
    selectedNode.scrollIntoView();
    var parent = selectedNode.getParent();
    while (parent && parent.getParent) {
        if (parent.status === 'close') {
            parent.getNode().emit('press');
        }
        parent = parent.getParent();
    }

};

MultiCheckTreeLeafBox.prototype._calcEstimateSize = function (items) {
    var self = this;
    var width = 0;
    var height = 0;

    function visit(item, level) {
        var itemWidth = self._estimateItemWidth(item, level);
        width = Math.max(width, itemWidth);
        height += 28;
        if (item.items && item.items.length) {
            item.items.forEach(function (item) {
                visit(item, level + 1);
            });
        }
    }

    items.forEach(function (item) {
        visit(item, 0);
    });

    return {
        width: width,
        height: height
    };
};

MultiCheckTreeLeafBox.prototype._updateSelectedItems = function () {
    var dict = this._values.reduce(function (ac, cr) {
        ac[cr] = true;
        return ac;
    }, {});
    var itemElt;
    for (var val in this.$dislayItemByValue) {
        itemElt = this.$dislayItemByValue[val];
        if (itemElt.$checkbox) {
            itemElt.$checkbox.checked = !!dict[itemElt.itemData.value];
        }
    }
};

MultiCheckTreeLeafBox.property = {};

MultiCheckTreeLeafBox.eventHandler = {};


MultiCheckTreeLeafBox.property.items = {
    /***
     * @this MultiCheckTreeLeafBox
     * @param items
     */
    set: function (items) {
        var self = this;
        this._savedStatus = {};
        this._searchCache = {};
        items = items || [];
        this._items = items;
        Object(search["c" /* prepareSearchForList */])(items);
        this.$content.clearChild();
        this.$itemByValue = {};
        this.$dislayItemByValue = this.$itemByValue;

        this.$items = items.map(function (item) {
            return self._makeTree(item, self.$itemByValue, self._savedStatus);
        });
        this.$dislayItems = this.$items;
        this.$content.addChild(this.$items);
        this.estimateSize = this._calcEstimateSize(items);
        this.addStyle('--select-list-estimate-width', this.estimateSize.width + 'px');
        this._updateSelectedItems();
    }, get: function () {
        return this._items;
    }
};

MultiCheckTreeLeafBox.property.values = {
    set: function (values) {
        this._values.splice(0, this._values.length);
        values = values || [];
        var arr = this._values;
        values.reduce(function (ac, cr) {
            if (!ac[cr]) {
                ac[cr] = true;
                arr.push(cr);
            }
            return ac;
        }, {});
        this._updateSelectedItems();
    }, get: function () {
        return this._values;
    }
};

MultiCheckTreeLeafBox.property.enableSearch = SelectListBox["b" /* default */].property.enableSearch;

MultiCheckTreeLeafBox.prototype._search = function (query) {
    var self = this;
    var queryItem = Object(search["b" /* default */])({text: query});
    var minScore = Infinity;
    var maxScore = -Infinity;

    function makeScoreTree(item) {
        var holder = {
            item: item, score: Object(search["a" /* calcItemMatchScore */])(queryItem, item), childrenScore: 0, children: []
        };
        minScore = Math.min(minScore, holder.score);
        maxScore = Math.max(maxScore, holder.score);

        var children;
        if (item.items && item.items.length > 0) {
            children = item.items.map(makeScoreTree);
            holder.children = children;
            holder.childrenScore = holder.children.reduce(function (ac, cr) {
                return Math.max(ac, cr.score, cr.childrenScore);
            }, 0);
        }
        return holder;
    }

    var treeScores = this._items.map(makeScoreTree);
    var midScore = (maxScore + minScore) / 2;
    var savedStatus = {};

    function filterTree(scoredTrees, ignore) {
        return scoredTrees.filter(function (holder) {
            return ignore || holder.score >= midScore || holder.childrenScore >= midScore;
        }).map(function makeTree(holder) {
            var item = Object.assign({}, holder.item);
            if (!ignore && holder.children && holder.children.length > 0) {
                if (holder.childrenScore >= midScore) {
                    savedStatus[item.value] = 'open';
                    item.items = filterTree(holder.children, false);
                } else {
                    savedStatus[item.value] = 'close';
                    item.items = filterTree(holder.children, true);
                }
            }
            return item;
        });
    }

    var resultItems = filterTree(treeScores, false);
    var dict = {};
    var $items = resultItems.map(function (item) {
        return self._makeTree(item, dict, savedStatus);
    });
    return {
        $items: $items,
        items: resultItems,
        savedStatus: Object.assign({}, savedStatus),
        originSavedStatus: savedStatus,
        dict: dict
    };
}

/***
 * @this MultiCheckTreeLeafBox
 */
MultiCheckTreeLeafBox.eventHandler.searchModify = function () {
    var query = this.$searchInput.value.trim();
    if (query.length === 0) {
        this.$content.clearChild().addChild(this.$items);
        this.$dislayItemByValue = this.$itemByValue;
        this.$dislayItems = this.$items;
        this._updateSelectedItems();
        return;
    }
    if (!this._searchCache[query]) {
        this._searchCache[query] = this._search(query);
    }
    var searchData = this._searchCache[query];
    searchData.savedStatus = Object.assign(searchData.savedStatus, searchData.originSavedStatus);
    for (var val in searchData.dict) {
        if (MultiCheckTreeLeafBox_isBranchStatus(searchData.dict[val].status)) {
            if (searchData.savedStatus[val]) {
                searchData.dict[val].status = searchData.savedStatus[val]
            }
        }
    }
    this.$content.clearChild()
        .addChild(searchData.$items);
    this.$dislayItemByValue = searchData.dict;
    this.$dislayItems = searchData.$items;
    this._updateSelectedItems();
};


ACore["d" /* default */].install(MultiCheckTreeLeafBox);

/* harmony default export */ var js_MultiCheckTreeLeafBox = (MultiCheckTreeLeafBox);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/MultiCheckTreeLeafMenu.js






/****
 * @extends AElement
 * @constructor
 */
function MultiCheckTreeLeafMenu() {
    this.$selectBox = Object(ACore["c" /* _ */])({
        tag: js_MultiCheckTreeLeafBox.tag,
        on: {
            change: this.eventHandler.selectBoxChange
        }
    });
    this.$selectBox.followTarget = this;
    this.on('click', this.eventHandler.click);
    this.$itemCtn = Object(ACore["a" /* $ */])('.as-multi-select-menu-item-ctn', this);
}

MultiCheckTreeLeafMenu.tag = 'MultiCheckTreeLeafMenu'.toLowerCase();

MultiCheckTreeLeafMenu.render = function () {
    return Object(ACore["c" /* _ */])({
        class: ['as-multi-select-menu', 'as-multi-check-tree-leaf-menu'],
        extendEvent: ['change'],
        attr: {
            tabindex: '1'
        },
        child: [
            {
                class: ['as-multi-select-menu-item-ctn', 'as-bscroller']
            },
            {
                tag: 'button',
                class: 'as-multi-select-menu-toggle-btn',
                child: 'dropdown-ico'
            },
            'attachhook'
        ]
    });
};


MultiCheckTreeLeafMenu.prototype._updateSelectedItems = function () {
    var values = this.$selectBox.values;
    while (this.$itemCtn.childNodes.length > values.length) {
        this.$itemCtn.removeChild(this.$itemCtn.lastChild);
    }
    while (this.$itemCtn.childNodes.length < values.length) {
        this.$itemCtn.addChild(this._makeItem());
    }

    var item;
    for (var i = 0; i < values.length; ++i) {
        item = this.$selectBox.$itemByValue[values[i]] && this.$selectBox.$itemByValue[values[i]].itemData;
        if (item) {
            this.$itemCtn.childNodes[i].data = item;
        }
    }
};

MultiCheckTreeLeafMenu.prototype._makeItem = function () {
    var itemElt = Object(ACore["c" /* _ */])({
        tag: SelectBoxItem["a" /* default */].tag,
    });

    itemElt.on('close', this.eventHandler.itemPressClose.bind(null, itemElt));

    return itemElt;
};

MultiCheckTreeLeafMenu.prototype.init = function (props) {
    props = props || {};
    var cProps = Object.assign({}, props);
    if ('items' in props) {
        this.items = props.items;
        delete cProps.items;
    }
    if ('values' in props) {
        this.values = props.values;
        delete cProps.values;
    }

    Object.assign(this, cProps);
};


MultiCheckTreeLeafMenu.property = {};

MultiCheckTreeLeafMenu.property.items = {
    set: function (items) {
        this.$selectBox.items = items;
        this.addStyle('--select-list-estimate-width', this.$selectBox.estimateSize.width + 'px');
        this._updateSelectedItems();
    },
    get: function () {
        return this.$selectBox.items;
    }
};

MultiCheckTreeLeafMenu.property.values = {
    set: function (values) {
        this.$selectBox.values = values || [];
        this._updateSelectedItems();

    },
    get: function () {
        return this.$selectBox.values;
    }
};


MultiCheckTreeLeafMenu.property.isFocus = js_SelectTreeLeafMenu.property.isFocus;

MultiCheckTreeLeafMenu.property.disabled =  MultiSelectMenu["a" /* default */].property.disabled;

MultiCheckTreeLeafMenu.eventHandler = {};

MultiCheckTreeLeafMenu.eventHandler.clickOut = js_SelectTreeLeafMenu.eventHandler.clickOut;

MultiCheckTreeLeafMenu.eventHandler.click = function (event) {
    if (event.target === this || event.target === this.$itemCtn) {
        this.isFocus = true;
    }
};

MultiCheckTreeLeafMenu.eventHandler.selectBoxChange = function () {
    this._updateSelectedItems();
    this.emit('change', {type: 'change', target: this}, this);
};

MultiCheckTreeLeafMenu.eventHandler.itemPressClose = function (itemElt, event) {
    var item = itemElt.data;
    this.$selectBox.values = this.$selectBox.values.filter(function (value) {
        return value !== item.value;
    });
    this._updateSelectedItems();
    this.emit('change', {type: 'change', target: this}, this);
};

ACore["d" /* default */].install(MultiCheckTreeLeafMenu);

/* harmony default export */ var js_MultiCheckTreeLeafMenu = (MultiCheckTreeLeafMenu);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/filelistinput.css
var filelistinput = __webpack_require__(301);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/FileListItem.js






/***
 * @extends AElement
 * @constructor
 */
function FileListItem() {
    this.$icon = Object(ACore["a" /* $ */])('.as-file-list-item-icon', this);
    this.$name = Object(ACore["a" /* $ */])('.as-file-list-item-name', this);
    this.value = null;
    this.fileType = null;
    this.fileName = '';
}

FileListItem.tag = 'FileListItem'.toLowerCase();


FileListItem.render = function () {
    return Object(ACore["c" /* _ */])({
        class: 'as-file-list-item',
        child: [
            {
                tag: 'img',
                class: 'as-file-list-item-icon',
                props: {
                    src: MessageInput["b" /* default */].iconAssetRoot + '/' + 'blank' + '.svg'
                }
            },
            {
                class: 'as-file-list-item-name',
                child: {text: '..'}
            }
        ]
    });
};

FileListItem.property = {};

FileListItem.property.fileType = {
    set: function (value) {
        this._fileType = value;
        if (value) {
            if (catalog.indexOf(value) >= 0)
                this.$icon.src = MessageInput["b" /* default */].iconAssetRoot + '/' + value + '.svg';
            else
                this.$icon.src = MessageInput["b" /* default */].iconAssetRoot + '/' + 'blank' + '.svg';
        } else {
            this.$icon.src = MessageInput["b" /* default */].iconAssetRoot + '/' + 'blank' + '.svg';
        }
    },
    get: function () {
        return this._fileType;
    }
};

FileListItem.property.fileName = {
    set: function (value) {
        this.$name.firstChild.data = value + '';
    },
    get: function () {
        return this.$name.firstChild.data;
    }
};


FileListItem.property.value = {
    set: function (value) {
        value = value || null;
        var type = null;
        var size = null;
        var name = null;
        if ((value instanceof File) || (value instanceof Blob)) {
            size = value.size;
            name = value.name;
            type = name.split('.').pop().toLowerCase();

        } else if (Object(utils["isURLAddress"])(value)) {
            type = value.replace(/\.upload$/, '').split('.').pop();
            name = value.split('/').pop().replace(/%20/g, ' ');
            this.attr('title', value);
        } else if (value && value.name && value.url) {//keeview file format
            this.attr('title', value.url);
            name = value.name;
            type = name.split('.').pop().toLowerCase();
        }
        this._value = value;
        this.fileSize = size;
        this.fileName = name;
        this.fileType = type;
        if (value) {
            this.addClass('as-has-value');
        } else {
            this.removeClass('as-has-value');
        }
    },
    get: function () {
        return this._value;
    }
}


ACore["d" /* default */].install(FileListItem);

/* harmony default export */ var js_FileListItem = (FileListItem);
// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/LanguageSystem.js
var LanguageSystem = __webpack_require__(66);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/FileListInput.js











/***
 * @extends AElement
 * @constructor
 */
function FileListInput() {
    ContextMenu["a" /* default */].auto();
    this.$add = Object(ACore["a" /* $ */])('.as-file-list-input-add', this);
    this.$attachhook = Object(ACore["a" /* $ */])('attachhook', this);
    this.$attachhook.requestUpdateSize = this.updateSize.bind(this);
    this.$attachhook.on('attached', function () {
        ResizeSystem["a" /* default */].add(this);
        this.requestUpdateSize();
    });
    this.on('filedrop', this.eventHandler.input_fileDrop);
    this.on('contextmenu', this.eventHandler.itemContext);


    this.$addedFile = Object(ACore["a" /* $ */])('input', this.$add)
        .on('change', this.eventHandler.clickAdd);
    /***
     *
     * @type {FileInputBox[]}
     */
    this.$fileItems = [];
    this.$activeItem = null;
    this._files = [];
    /***
     * @name files
     * @memberOf FileListInput#
     * @type {*}
     *
     */
    /***
     * @name readOnly
     * @memberOf FileListInput#
     * @type {boolean}
     */

    /***
     * @name multiple
     * @memberOf FileListInput#
     * @type {boolean}
     */
    /***
     * @name droppable
     * @memberOf FileListInput#
     * @type {boolean}
     */
}

FileListInput.tag = 'FileListInput'.toLowerCase();

FileListInput.render = function () {
    return Object(ACore["c" /* _ */])({
        tag: js_DropZone.tag,
        class: ['as-file-list-input', 'as-bscroller', 'as-empty', 'as-droppable'],
        extendEvent: ['change', 'contextmenu'],
        child: [
            {
                tag: 'label',
                class: 'as-file-list-input-add',
                child: [
                    {
                        tag: 'input',
                        attr: {
                            type: 'file',
                            accept: '*',
                            title: null
                        }
                    },
                    {
                        class: 'as-file-list-input-add-icon-ctn',
                        child: 'span.mdi.mdi-upload-outline'
                    },
                    'attachhook'
                ]
            },
            {
                tag: 'span',
                class: 'as-file-list-drag-file-text',
                child: {
                    text: '(Kéo thả  file vào đây để tải lên)'
                }
            },
            {
                class: 'as-file-list-input-upload-overlay',
                child: 'span.mdi.mdi-upload'
            }
        ]
    });
};

FileListInput.prototype.updateSize = function () {
    var bound, px, n;
    var requireWidth = this.getComputedStyleValue('--item-require-width') || '300px';
    if (requireWidth.match(/%$/)) {
        this.addStyle('--item-width', requireWidth);
    } else if (requireWidth.match(/px$/)) {
        bound = this.getBoundingClientRect();
        px = parseFloat(requireWidth.replace('px', ''));
        if (!isNaN(px) && px > 0) {
            n = Math.max(1, Math.floor((bound.width - 10 - 2) / px));
            this.addStyle('--item-width', Math.floor(100 / n) + '%');
        } else {
            this.removeStyle('--item-width');
        }
    } else {
        this.removeStyle('--item-width');
    }
};

FileListInput.prototype._makeFileItem = function (file) {
    var fileElt = Object(ACore["c" /* _ */])({
        tag: js_FileListItem.tag,
        props: {
            allowUpload: false,
            fileData: file,
        }
    });
    fileElt.on('mousedown', this.eventHandler.mouseDownItem.bind(this, fileElt));
    if (file instanceof File || file instanceof Blob || typeof file === 'string') {
        fileElt.value = file;
    } else if (typeof file === 'object') {
        if (file.value || file.url) fileElt.value = file.value || file.url;
        if (file.fileName || file.name) fileElt.fileName = file.fileName || file.name;
    }
    return fileElt;
};

FileListInput.prototype.add = function (file) {
    var fileElt = this._makeFileItem(file);
    this.$fileItems.push(fileElt);
    this.addChildBefore(fileElt, this.$add);
    this._files.push(file);
    this._updateCountClass();
};

FileListInput.prototype._updateCountClass = function () {
    if (this._files.length > 0) {
        this.removeClass('as-empty');
    } else {
        this.addClass('as-empty');
    }
};

FileListInput.prototype.activeFileItemElt = function (itemElt) {
    if (this.$activeItem !== itemElt) {
        if (this.$activeItem) {
            this.$activeItem.removeClass('as-active');
        }
        this.$activeItem = itemElt;
        if (this.$activeItem) {
            this.$activeItem.addClass('as-active');
        }
    }
};

FileListInput.prototype.downloadFileItemElt = function (fileElt) {
    var fileData = fileElt.fileData;
    var name = fileData.name || fileElt.fileName;
    var file;
    if (fileData instanceof File || fileData instanceof Blob) {
        file = fileData;
    } else if (typeof fileData === 'object') {
        if (fileData.url) file = fileData.url;
    } else if (typeof fileData === "string") {
        file = fileData;
    }
    if (file) {
        Object(FileSaver["saveAs"])(file, name);
    }
};

FileListInput.prototype.deleteFileItemElt = function (fileElt) {
    var fileData = fileElt.fileData;
    var idx = this._files.indexOf(fileData);
    if (idx >= 0) {
        this._files.splice(idx, 1);
    }
    fileElt.remove();
};

FileListInput.prototype._findFileItemElt = function (target) {
    while (target && target !== this) {
        if (target.containsClass && target.containsClass('as-file-list-item')) {
            return target;
        }
        target = target.parentElement;
    }
    return null;
};


FileListInput.property = {};

FileListInput.property.files = {
    /***
     * @this FileListInput
     * @param files
     */
    set: function (files) {
        var self = this;
        this.$fileItems.forEach(function (fileElt) {
            fileElt.remove();
        });
        files = files || [];
        this._files = files;
        this.$fileItems = files.map(function (file) {
            var elt = self._makeFileItem(file);
            self.addChildBefore(elt, self.$add);
            return elt;
        });
        this._updateCountClass();
    },
    /***
     * @this FileListInput
     */
    get: function () {
        return this._files;
    }
};


FileListInput.property.readOnly = {
    set: function (value) {
        value = !!value;
        if (value) {
            this.addClass('as-read-only');
        } else {
            this.removeClass('as-read-only');
        }
        this.$fileItems.forEach(function (fileElt) {
            fileElt.removable = !value;
        });
    },
    get: function () {
        return this.containsClass('as-read-only');
    }
};

FileListInput.property.droppable = {
    set: function (value) {
        value = !!value;
        if (value) {
            this.addClass('as-droppable');
        } else {
            this.removeClass('as-droppable');
        }
        this.$fileItems.forEach(function (fileElt) {
            fileElt.removable = !value;
        });
    },
    get: function () {
        return this.containsClass('as-droppable');
    }
};

FileListInput.property.multiple = {
    set: function (value) {
        this.$addedFile.multiple = !!value;
    },
    get: function () {
        return this.$addedFile.multiple;
    }
};


FileListInput.property.accept = {
    set: function (value) {
        if (!value) value = null;
        this.$addedFile.attr('accept', value + '');
    },
    get: function () {
        return this.$addedFile.attr('accept') || null;
    }
};

ACore["d" /* default */].install(FileListInput);

/***
 * @memberOf  FileListInput#
 * @type {{}}
 */
FileListInput.eventHandler = {};


FileListInput.eventHandler.clickAdd = function (event) {
    var files = Array.prototype.slice.call(this.$addedFile.files);
    this.$addedFile.files = null;
    if (files.length === 0) return;
    for (var i = 0; i < files.length; ++i) {
        this.add(files[i]);
    }
    this.emit('change', {files: files, type: 'change', target: this, originalEvent: event, action: 'add'}, this);
};

/***
 * @this FileListInput
 * @param itemElt
 * @param event
 */
FileListInput.eventHandler.mouseDownItem = function (itemElt, event) {
    this.activeFileItemElt(itemElt);
};


FileListInput.eventHandler.input_fileDrop = function (event) {
    if (this.readOnly || !this.droppable) return;
    var self = this;
    var files = Array.prototype.slice.call(event.files);
    if (files.length === 0) return;
    if (!this.multiple) files = files.slice(0, 1);
    var accept = this.accept;
    files = files.filter(function (file) {
        return Object(utils["fileAccept"])(accept, file.type) || Object(utils["fileAccept"])(accept, file.name);
    });

    if (files.length > 0) {
        files.forEach(function (file) {
            self.add(file);
        });
        this.emit('change', {type: 'change', files: files, target: this, action: 'drop'}, this);
    }
};

/***
 * @this FileListInput
 * @param itemElt
 * @param event
 */
FileListInput.eventHandler.itemContext = function (event) {
    var self = this;
    var itemElt = this._findFileItemElt(event.target);
    var menuItems = [];
    if (itemElt) {
        menuItems.push({
            text: LanguageSystem["a" /* default */].getText('txt_download') || "Download",
            icon: 'span.mdi.mdi-download',
            cmd: 'download'
        });
    }
    if (!this.readOnly) {
        if (itemElt)
            menuItems.push({
                text: LanguageSystem["a" /* default */].getText('txt_delete') || "Delete",
                icon: 'span.mdi.mdi-delete',
                cmd: 'delete'
            });
        menuItems.push(
            {
                text: LanguageSystem["a" /* default */].getText('txt_delete_all') || "Delete All",
                icon: 'span.mdi.mdi-delete-empty',
                cmd: 'delete_all'
            });
    }
    if (menuItems.length > 0) {
        event.showContextMenu({
            items: menuItems
        }, function (event) {
            var files;
            switch (event.menuItem.cmd) {
                case 'download':
                    self.downloadFileItemElt(itemElt);
                    break;
                case 'delete':
                    self.deleteFileItemElt(itemElt);
                    self.emit('change', {type: 'change', item: itemElt.fileData, target: this, action: 'delete'}, this);
                    break;
                case 'delete_all':
                    files = self.files;
                    self.files = [];
                    self.emit('change', {type: 'change', items: files, target: this, action: 'delete_all'}, this);
                    break;
            }
        });
    }
};


/* harmony default export */ var js_FileListInput = (FileListInput);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/DateInYearPicker.js
var DateInYearPicker = __webpack_require__(77);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/DateInYearInput.js
var DateInYearInput = __webpack_require__(87);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/dualselectmenu.css
var dualselectmenu = __webpack_require__(305);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/DualSelectBox.js







/***
 * @extends Follower
 * @constructor
 */
function DualSelectBox() {
    this.$domSignal = Object(ACore["c" /* _ */])('attachhook').addTo(this);
    this.domSignal = new DomSignal["a" /* default */](this.$domSignal);
    this.domSignal.on('scrollIntoSelected', this.scrollIntoSelected.bind(this));
    this._items = [];
    this._value = [null, null];
    this.holderByValue = {};
    this.$lists = Object(ACore["b" /* $$ */])('.as-dual-select-box-list', this);
    this.$searcTextInput = Object(ACore["a" /* $ */])('searchtextinput', this)
        .on('stoptyping', this.eventHandler.searchTextInputModify);
    this.cView = new DualSelectView(this, this._items);
    this.searchedView = {
        '*': this.cView
    };


    this.estimateSize = { width: 0, height: 0 };

    this._emittedValue = [null, null];


    /***
     * @name strictValue
     * @type {boolean}
     * @memberOf DualSelectBox#
     */
    /***
     * @name enableSearch
     * @type {boolean}
     * @memberOf DualSelectBox#
     */

    /***
     * @name value
     * @type {Array}
     * @memberOf DualSelectBox#
     */

    /***
     * @name items
     * @type {Array}
     * @memberOf DualSelectBox#
     */
}


DualSelectBox.tag = 'DualSelectBox'.toLowerCase();

DualSelectBox.render = function () {
    return Object(ACore["c" /* _ */])({
        tag: Follower["a" /* default */].tag,
        class: 'as-dual-select-box',
        extendEvent: ['change'],
        child: [
            {
                class: 'as-dual-select-box-search-ctn',
                child: {
                    tag: 'searchtextinput'
                }
            },
            {
                class: 'as-dual-select-box-list-ctn',
                child: [
                    {
                        class: ['as-dual-select-box-list', 'absol-selectlist', 'as-bscroller'],
                        child: Array(200).fill(null).map(function (u, i) {
                            return {
                                class: 'absol-selectlist-item',
                                child: {
                                    tag: 'span',
                                    child: { text: 'item ' + i }
                                }
                            };
                        })
                    },
                    {
                        class: 'as-dual-select-box-arrow-ctn',
                        child: 'span.mdi.mdi-menu-right'
                    },
                    {
                        class: ['as-dual-select-box-list', 'absol-selectlist', 'as-bscroller'],
                        child: Array(200).fill(null).map(function (u, i) {
                            return {
                                class: 'absol-selectlist-item',
                                child: {
                                    tag: 'span',
                                    child: { text: 'item ' + i }
                                }
                            };
                        })
                    }
                ]
            }
        ]
    });
};

DualSelectBox.prototype._implicit = function (value) {
    if (value instanceof Array) {
        if (value.length > 2) value = value.slice(0, 2);
        else {
            value.push.apply(value, Array(2 - value.length).fill(null));
        }
    }
    else {
        value = [null, null];
    }
    return value;
};


DualSelectBox.prototype._explicit = function (value) {
    value = value.slice();
    var strictValue = this.strictValue;
    if (!this.holderByValue[value[0]]) {
        if (this._items.length > 0 && strictValue) {
            value[0] = this._items[0].value;
        }
        else {
            return null;
        }
    }
    if (!this.holderByValue[value[0]].child[value[1]]) {
        if (strictValue && this.holderByValue[value[0]].item.items && this.holderByValue[value[0]].item.items.length > 0) {
            value[1] = this.holderByValue[value[0]].item.items[0].value;
        }
        else {
            return null;
        }
    }

    if (value[0] === null || value[1] === null) {
        return null;
    }

    return value;
};

DualSelectBox.prototype._notifyIfChange = function (event) {
    var value = this._explicit(this._value);
    if (value === this._emittedValue) return;
    if (!value !== !this._emittedValue || (value[0] !== this._emittedValue[0] || value[1] !== this._emittedValue[1])) {
        this.emit('change', { type: 'change', target: this, originalEvent: event }, this);
    }
};


DualSelectBox.prototype._makeLeftItem = function (item) {
    var itemElt = Object(ACore["c" /* _ */])({
        class: 'absol-selectlist-item',
        child: {
            tag: 'span',
            child: { text: item.text }
        }
    });
    itemElt.itemData = item;
    itemElt.on('click', this.eventHandler.clickLeftItem.bind(this, itemElt));

    return itemElt;
};


DualSelectBox.prototype.makeRightItem = function (item) {
    var itemElt = Object(ACore["c" /* _ */])({
        class: 'absol-selectlist-item',
        child: {
            tag: 'span',
            child: { text: item.text }
        }
    });
    itemElt.itemData = item;
    itemElt.on('click', this.eventHandler.clickRightItem.bind(this, itemElt));

    return itemElt;
};


DualSelectBox.prototype._calcEstimateSize = function (items) {
    var longestItem = null;
    var longestE14 = 0;
    var e14, i, j;
    var item, subItem;
    for (i = 0; i < items.length; ++i) {
        item = items[i];
        e14 = Object(utils["estimateWidth14"])(item.text);
        if (e14 > longestE14) {
            longestItem = item;
            longestE14 = e14;
        }
    }

    var leftTextWidth = longestItem ? Object(utils["measureText"])(longestItem.text, '14px arial').width : 0;
    var maxN = items.length;
    for (i = 0; i < items.length; ++i) {
        item = items[i];
        if (!item.items || item.items.length === 0) continue;
        maxN = Math.max(maxN, item.items.length);
        for (j = 0; j < item.items.length; ++j) {
            subItem = item.items[j];
            e14 = Object(utils["estimateWidth14"])(subItem.text);
            if (e14 > longestE14) {
                longestItem = subItem;
                longestE14 = e14;
            }
        }
    }
    var rightTextWidth = longestItem ? Object(utils["measureText"])(longestItem.text, '14px arial').width : 0;

    return {
        width: 7 + leftTextWidth + 7 + 5 + 7 + 1 + 17 + 1 + 7 + rightTextWidth + 7 + 5 + 7 + 20,
        height: maxN * 20,
        textWidth: leftTextWidth + rightTextWidth + 12
    }
};


DualSelectBox.prototype.scrollIntoSelected = function () {
    if (!this.isDescendantOf(document.body)) {
        this.domSignal.emit('scrollIntoSelected');
        return;
    }
    if (this.cView && this.cView.$leftSelectedItem && this.cView.$leftSelectedItem.isDescendantOf(this.$lists[0])) {
        this.cView.$leftSelectedItem.scrollIntoView();
    }
    if (this.cView && this.cView.$rightSelectedItem && this.cView.$rightSelectedItem.isDescendantOf(this.$lists[1])) {
        this.cView.$rightSelectedItem.scrollIntoView();
    }
};

DualSelectBox.property = {};

DualSelectBox.property.items = {
    /***
     * @this DualSelectBox
     * @param items
     */
    set: function (items) {
        var self = this;
        items = items || [];
        Object(search["c" /* prepareSearchForList */])(items);
        this._items = items;


        this.holderByValue = items.reduce(function (ac, cr) {
            ac[cr.value] = {
                item: cr,
                child: (cr.items || []).reduce(function (ac1, cr1) {
                    ac1[cr1.value] = {
                        item: cr1
                    }
                    return ac1;
                }, {})
            }
            return ac;
        }, {});
        this.estimateSize = this._calcEstimateSize(items);
        this.addStyle('--dual-list-estimate-width', this.estimateSize.width + 'px');
        this.searchedView = {};
        this.cView = new DualSelectView(this, items);
        this.searchedView['*'] = this.cView;
        this.cView.toView();
    },
    get: function () {
        return this._items;
    }
};


DualSelectBox.property.enableSearch = {
    set: function (value) {
        if (value) {
            this.addClass('as-enable-search');
        }
        else {
            this.removeClass('as-enable-search');
        }
    },
    get: function () {
        return this.containsClass('as-enable-search');
    }
};


DualSelectBox.property.strictValue = {
    set: function (value) {
        if (value) {
            this.addClass('as-strict-value');
        }
        else {
            this.removeClass('as-strict-value');
        }
        if (this.cView)
            this.cView.updateViewByValue();
    },
    get: function () {
        return this.containsClass('as-strict-value');
    }
};

DualSelectBox.property.value = {
    /***
     * @this DualSelectBox
     * @param value
     */
    set: function (value) {
        this._value = this._implicit(value);
        if (this.cView) {
            this.cView.updateViewByValue();
            this.cView.toRightList();
        }
        this.scrollIntoSelected();
    },
    get: function () {
        return this._explicit(this._value);
    }
};

/***
 * @memberOf DualSelectBox#
 * @type {{}}
 */
DualSelectBox.eventHandler = {};

/***
 * @this DualSelectBox
 * @param itemElt
 * @param event
 */
DualSelectBox.eventHandler.clickLeftItem = function (itemElt, event) {
    var item = itemElt.itemData;
    this._value[0] = item.value;
    this.cView.updateLeftSelectedItem();
    this.cView.updateRightList();
    this.cView.toRightList();

    if (this.cView.$leftItemByValue[item.value] && this.cView.$leftItemByValue[item.value].itemData
        && this.cView.$leftItemByValue[item.value].itemData.items && this.cView.$leftItemByValue[item.value].itemData.items.length > 0) {
        this._value[1] = this.cView.$leftItemByValue[item.value].itemData.items[0].value;
        this.cView.updateRightSelectedItem();
    }
    if (this.cView.$rightSelectedItem) {
        this.cView.$rightSelectedItem.scrollIntoView();
    }
    this._notifyIfChange(event);
};

/***
 * @this DualSelectBox
 * @param itemElt
 * @param event
 */
DualSelectBox.eventHandler.clickRightItem = function (itemElt, event) {
    var item = itemElt.itemData;
    this._value[1] = item.value;
    this.cView.updateRightSelectedItem();
    this._notifyIfChange(event);
};


DualSelectBox.prototype.searchItemByText = function (text) {
    var items = this._items;
    var queryItem = Object(search["b" /* default */])({ text: text });
    var maxScore = 0;
    var holders = items.map(function (item) {
        var h = {
            item: item,
            itemScore: Object(search["a" /* calcItemMatchScore */])(queryItem, item),
        };
        maxScore = Math.max(maxScore, h.itemScore);
        var childMaxScore = 0;
        if (item.items && item.items.length > 0) {
            h.child = item.items.map(function (cItem) {
                var cItemScore = Object(search["a" /* calcItemMatchScore */])(queryItem, cItem);
                maxScore = Math.max(maxScore, cItemScore);
                childMaxScore = Math.max(childMaxScore, cItemScore);
                return {
                    item: cItem,
                    itemScore: cItemScore
                };
            });
            h.childScore = childMaxScore;
        }

        return h;
    });

    holders.sort(function (a, b) {
        return -Math.max(a.itemScore, a.childScore) + Math.max(b.itemScore, b.childScore)
    });
    var midScore = maxScore / 2;
    holders = holders.filter(function (holder) {
        return Math.max(holder.itemScore, holder.childScore) >= midScore;
    });

    return holders.map(function (holder) {
        var oldItem = holder.item;
        var item = { text: oldItem.text, value: oldItem.value };
        var childHolders;
        if (holder.child) {
            childHolders = holder.child.slice();
            childHolders.sort(function (a, b) {
                return -a.itemScore + b.itemScore;
            });
            item.items = childHolders.map(function (cHolder) {
                return cHolder.item;
            });
            item.isSearchItem = true;
        }
        return item;
    });
};

DualSelectBox.prototype.focus = function () {
    if (this.enableSearch) {
        this.$searcTextInput.focus();
    }
};

DualSelectBox.prototype.resetSearchState = function () {
    if (this.$searcTextInput.value.length === 0) return;
    this.$searcTextInput.value = '';
    this.eventHandler.searchTextInputModify();
};


/***
 * @this DualSelectBox
 */
DualSelectBox.eventHandler.searchTextInputModify = function () {
    var query = this.$searcTextInput.value.trim().replace(/\s+/, ' ');
    if (query.length === 0) query = '*';
    var view = this.searchedView[query];
    if (!view) {
        view = new DualSelectView(this, this.searchItemByText(query));
        this.searchedView[query] = view;
    }
    this.cView = view;
    this.cView.updateLeftSelectedItem();
    this.cView.updateRightSelectedItem();
    view.toView();
    this.$lists[0].scrollTop = 0;
    this.$lists[1].scrollTop = 0;
    if (query === '*') this.scrollIntoSelected();
};


ACore["d" /* default */].install(DualSelectBox);

/* harmony default export */ var js_DualSelectBox = (DualSelectBox);

/***
 *
 * @param {DualSelectBox} box
 * @param items
 * @constructor
 */
function DualSelectView(box, items) {
    var self = this;
    this.box = box;
    this.items = items;

    this.$leftItems = items.map(function (item) {
        return self.box._makeLeftItem(item);
    });
    this.$leftItemByValue = this.$leftItems.reduce(function (ac, cr) {
        ac[cr.itemData.value] = cr;
        return ac;
    }, {});

    this.$rightItems = [];
    this.$rightItemByValue = {};
    this.$leftSelectedItem = null;
    this.$rightSelectedItem = null;
    this.updateViewByValue();
}

DualSelectView.prototype.toView = function () {
    this.box.$lists[0].clearChild();
    this.box.$lists[0].addChild(this.$leftItems);
    this.updateLeftSelectedItem();
    this.toRightList();
};

DualSelectView.prototype.toRightList = function () {
    this.box.$lists[1].clearChild();
    this.box.$lists[1].addChild(this.$rightItems);
    this.updateLeftSelectedItem();
};


DualSelectView.prototype.updateViewByValue = function () {
    this.updateLeftSelectedItem();
    this.updateRightList();
};


DualSelectView.prototype.updateRightList = function () {
    var self = this;
    var leftValue = this.box._value[0];
    var items = this.$leftItemByValue[leftValue] && this.$leftItemByValue[leftValue].itemData.items;
    if (items && items.length > 0) {
        this.$rightItems = items.map(function (item) {
            return self.box.makeRightItem(item);
        });
    }
    else {
        this.$rightItems = [];
    }
    this.$rightItemByValue = this.$rightItems.reduce(function (ac, cr) {
        ac[cr.itemData.value] = cr;
        return ac;
    }, {});
    this.updateRightSelectedItem();
};

DualSelectView.prototype.updateLeftSelectedItem = function () {
    if (this.$leftSelectedItem) {
        this.$leftSelectedItem.removeClass('as-selected');
    }
    this.$leftSelectedItem = this.$leftItemByValue[this.box._value[0]] || null;
    if (this.$leftSelectedItem) {
        this.$leftSelectedItem.addClass('as-selected');
    }
};


DualSelectView.prototype.updateRightSelectedItem = function () {
    if (this.$rightSelectedItem) {
        this.$rightSelectedItem.removeClass('as-selected');
    }
    this.$rightSelectedItem = this.$rightItemByValue[this.box._value[1]] || null;
    if (this.$rightSelectedItem) {
        this.$rightSelectedItem.addClass('as-selected');
    }
};
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/DualSelectMenu.js







/***
 * @extends AElement
 * @constructor
 */
function DualSelectMenu() {
    this._format = '$0, $1';
    /***
     * @type {DualSelectBox}
     */
    this.$box = Object(ACore["c" /* _ */])({
        tag: js_DualSelectBox.tag,
        props: {
            anchor: [1, 6, 2, 5]
        },
        on: {
            preupdateposition: this.eventHandler.preUpdatePosition,
            change: this.eventHandler.boxChange
        }
    });
    this.$item = Object(ACore["a" /* $ */])('.absol-selectlist-item', this);
    this.on('click', this.eventHandler.click);
    OOP["a" /* default */].drillProperty(this, this.$box, 'enableSearch');
    /***
     * @name strictValue
     * @type {boolean}
     * @memberOf DualSelectMenu#
     */
}


DualSelectMenu.tag = 'DualSelectMenu'.toLowerCase();

DualSelectMenu.render = function () {
    return Object(ACore["c" /* _ */])({
        class: ['absol-selectmenu', 'as-dual-select-menu'],
        extendEvent: ['change'],
        attr: {
            tabindex: '1'
        },
        child: [
            {
                class: 'absol-selectmenu-holder-item',
                child: '.absol-selectlist-item'
            },
            {
                tag: 'button',
                class: 'absol-selectmenu-btn',
                child: ['dropdown-ico']
            },
            'attachhook',
        ]
    });
};


DualSelectMenu.prototype._updateViewValue = function () {
    var format = this._format;
    var value = this.$box.value || [null, null];
    var strictValue = this.strictValue;
    var hbv = this.$box.holderByValue;
    var firstToken = '__';
    var secToken = '__';

    var firstHolder = hbv[value[0]];
    var sectHolder;
    if (firstHolder) {
        firstToken = firstHolder.item.text;
        sectHolder = firstHolder.child[value[1]];
        if (sectHolder)
            secToken = sectHolder.item.text

    }
    var text = format.replace('$0', firstToken)
        .replace('$1', secToken);
    this.$item.clearChild().addChild(Object(ACore["c" /* _ */])({
        tag:'span',
        child:{text: text}
    }));


};

DualSelectMenu.property = {};

DualSelectMenu.property.isFocus = {
    /***
     * @this DualSelectMenu
     * @param value
     */
    set: function (value) {
        var self = this;
        value = !!value;
        if (this.containsClass('as-focus') === value) return;
        if (value) {
            this._prevValue = (this.$box.value||[null, null]).join('//');
            this.addClass('as-focus');
            this.off('click', this.eventHandler.click);
            this.$box.followTarget = this;
            this.$box.addTo(document.body);
            this.$box.updatePosition();
            this.$box.scrollIntoSelected();
            setTimeout(function () {
                document.addEventListener('click', self.eventHandler.clickOut);
            }, 10);
        }
        else {
            this.removeClass('as-focus');
            this.$box.remove();
            this.$box.resetSearchState();
            document.removeEventListener('click', self.eventHandler.clickOut);
            setTimeout(function () {
                self.on('click', self.eventHandler.click);
            }, 10);
            if ((this.$box.value||[null, null]).join('//') !==  this._prevValue ){
                this._updateViewValue();
                this.emit('change', {type: 'change', target: this}, this);
            }
        }
    },
    get: function () {
        return this.containsClass('as-focus');
    }
}

/****
 * @memberOf DualSelectMenu#
 * @type {{}}
 */
DualSelectMenu.eventHandler = {};

DualSelectMenu.property.items = {
    /***
     * @this DualSelectMenu
     * @param items
     */
    set: function (items) {
        this.$box.items = items;
        this.addStyle('--dual-list-estimate-text-width', this.$box.estimateSize.textWidth + 'px');
        this._updateViewValue();
    },
    get: function () {
        return this.$box.items;
    }
};

DualSelectMenu.property.value = {
    set: function (value) {
        this.$box.value = value;
        this._updateViewValue();
    },
    get: function () {
        return this.$box.value;
    }
};

DualSelectMenu.property.strictValue = {
    set: function (value) {
        this.$box.strictValue = value;
        this._updateViewValue();
    },
    get: function () {
        return this.$box.strictValue;
    }
};


DualSelectMenu.property.format = {
    set: function (value) {
        this._format = value || '$0, $1';
        this._updateViewValue();
    },
    get: function () {
        return this._format;
    }
}


/**
 * @this DualSelectMenu
 */
DualSelectMenu.eventHandler.click = function () {
    this.isFocus = true;
};

/**
 * @this DualSelectMenu
 */
DualSelectMenu.eventHandler.clickOut = function (event) {
    if (Object(EventEmitter["d" /* hitElement */])(this.$box, event)) return;
    this.isFocus = false;
};

/***
 * @this DualSelectMenu
 */
DualSelectMenu.eventHandler.preUpdatePosition = function () {
    var bound = this.getBoundingClientRect();
    var screenSize = Object(Dom["d" /* getScreenSize */])();
    var availableTop = bound.top - 5;
    var availableBot = screenSize.height - 5 - bound.bottom;
    this.$box.addStyle('--max-height', Math.max(availableBot, availableTop) + 'px');
    var outBound = Object(Dom["f" /* traceOutBoundingClientRect */])(this);
    if (bound.bottom < outBound.top || bound.top > outBound.bottom || bound.right < outBound.left || bound.left > outBound.right) {
        this.isFocus = false;
    }
};


DualSelectMenu.eventHandler.boxChange = function () {
    this._updateViewValue();
};

ACore["d" /* default */].install(DualSelectMenu);

/* harmony default export */ var js_DualSelectMenu = (DualSelectMenu);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/toclist.css
var toclist = __webpack_require__(307);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TOCItem.js








/***
 * @extends AElement
 * @constructor
 */
function TOCItem() {
    this.$iconP = null;
    this.$iconCtn = Object(ACore["a" /* $ */])('.as-toc-item-ext-icon-ctn', this);
    this._status = 'none';
    this.$name = Object(ACore["a" /* $ */])('.as-toc-item-name', this);
    this.$nameInput = Object(ACore["a" /* $ */])('.as-toc-item-name-input', this)
        .on('keydown', this.eventHandler.keyDownNameInput)
        .on('paste', this.eventHandler.keyDownNameInput);
    this.$toggleCtn = Object(ACore["a" /* $ */])('.as-toc-item-toggle-ico-ctn', this)
        .on('click', this.eventHandler.clickToggleCtn);
    this._level = 0;
    this.$checkbox = Object(ACore["a" /* $ */])(CheckBoxInput["a" /* default */].tag, this)
        .on('change', this.eventHandler.checkedChange);
    this.$checkbox.disabled = true;
    this.$checkbox.addStyle('display', 'none');
    this.$checkIco = Object(ACore["a" /* $ */])('.as-toc-item-check-ctn .mdi-check', this)
        .addStyle('display', 'none')
        .addStyle('font-size', '18px');

    this.$quickMenuBtn = Object(ACore["a" /* $ */])('.as-toc-item-quick-menu-ctn button', this)
        .on('click', this.eventHandler.clickQuickMenuBtn);
    this.on('click', this.eventHandler.click);
    /***
     * @name name
     * @type {string}
     * @memberOf TOCItem#
     */

    /***
     * @name status
     * @type {"none"|"open"|"close"}
     * @memberOf TOCItem#
     */

    /***
     * @name level
     * @type {number}
     * @memberOf TOCItem#
     */
    /***
     * @name checked
     * @type {boolean}
     * @memberOf TOCItem#
     */
    /***
     * @name nodeData
     * @type {{}}
     * @memberOf TOCItem#
     */
}

TOCItem.tag = 'TOCItem'.toLowerCase();

TOCItem.render = function () {
    return Object(ACore["c" /* _ */])({
        class: 'as-toc-item',
        extendEvent: ['presstoggle', 'checkedchange', 'pressquickmenu', 'press'],
        child: [
            {
                class: 'as-toc-item-toggle-ico-ctn',
                child: 'toggler-ico'
            },
            '.as-toc-item-ext-icon-ctn',
            {
                class: 'as-toc-item-name-ctn',
                child: [
                    {
                        tag: 'span',
                        class: 'as-toc-item-name',
                        child: { text: 'đây là cái tên' }
                    },
                    {
                        tag: 'input',
                        class: 'as-toc-item-name-input',
                        attr: { type: 'text' }
                    }
                ]
            },
            {
                class: 'as-toc-item-check-ctn',
                child: [{
                    tag: CheckBoxInput["a" /* default */].tag
                }, 'span.mdi.mdi-check']
            },
            {
                class: 'as-toc-item-quick-menu-ctn',
                child: {
                    tag: 'button',

                    child: 'span.mdi.mdi-dots-vertical'
                }
            }
        ]
    });
};

TOCItem.property = {};


TOCItem.property.icon = {
    set: function (value) {
        if (this.$iconP) {
            this.$iconP.remove();
            this.$iconP = undefined;
        }
        if (value) {
            var newE;
            if (!Dom["b" /* default */].isDomNode(value)) {
                newE = Object(ACore["c" /* _ */])(value);
            }
            this.$iconP = newE;
            this.$iconCtn.addChild(newE);
            this._icon = value;
        }
        else {
            this._icon = undefined;
        }
    },
    get: function () {
        return this._icon;
    }
};


TOCItem.property.status = {
    set: function (value) {
        if (['none', 'open', 'close'].indexOf(value) <0) value = 'none';
        this.removeClass('as-status-' + this._status);
        this._status = value;
        this.addClass('as-status-' + value);
    },
    get: function () {
        return this._status;
    }
};


TOCItem.property.name = {
    set: function (value) {
        this.$name.firstChild.data = value || '';
    },
    get: function () {
        return this.$name.firstChild.data;
    }
};

TOCItem.property.level = {
    set: function (value) {
        this._level = value;
        this.addStyle('--level', value + '');
    },
    get: function () {
        return this._level;
    }
};


TOCItem.property.checked = {
    set: function (value) {
        this.$checkbox.checked = value;
        if (value) {
            this.$checkIco.removeStyle('display');
        }
        else {
            this.$checkIco.addStyle('display', 'none');

        }
    },
    get: function () {
        return this.$checkbox.checked;
    }
};


TOCItem.prototype.rename = function () {
    this.addClass('as-renaming');
    var name = this.name;
    var textWidth = Object(utils["measureText"])(name, '14px Arial, Helvetica, sans-serif').width;
    this.$nameInput.addStyle('width', textWidth + 2 + 'px');
    this.$nameInput.value = name;
    this.$nameInput.focus();
    this.$nameInput.select();
    this.$nameInput.once('blur', function () {
        if (this.$nameInput.value !== name) {
            //todo
            this.name = this.$nameInput.value;
        }
        this.removeClass('as-renaming');
    }.bind(this));
};


/***
 * @memberOf TOCItem#
 * @type {{}}
 */
TOCItem.eventHandler = {};

TOCItem.eventHandler.keyDownNameInput = function (event) {
    var extendText = '';
    if (event.type === 'paste') {
        extendText = (event.clipboardData || window.clipboardData).getData('text') || '';
    }
    else if (event.key.length === 1 && !(event.ctrl && event.key === 'C')) {
        extendText = event.key;
    }
    else if (event.key === 'Enter') {
        this.$nameInput.blur();
    }

    if (extendText.length > 0) {
        this.$nameInput.addStyle('width', Object(utils["measureText"])(this.$nameInput.value + extendText, '14px Arial, Helvetica, sans-serif').width + 2 + 'px');
    }


    setTimeout(function () {
        var name = this.$nameInput.value;
        this.$nameInput.addStyle('width', Object(utils["measureText"])(name, '14px Arial, Helvetica, sans-serif').width + 2 + 'px');
    }.bind(this), 0);
};

TOCItem.eventHandler.clickToggleCtn = function (event) {
    if (this.status === 'close' || this.status === 'open')
        this.emit('presstoggle', { originalEvent: event, type: 'presstoggle' }, this);
};


TOCItem.eventHandler.checkedChange = function (event) {
    this.emit('checkedchange', { type: 'checkedchange', target: this, originalEvent: event }, this);
};

TOCItem.eventHandler.clickQuickMenuBtn = function (event) {
    this.emit('pressquickmenu', { type: 'pressquickmenu', originalEvent: event }, this);
};

TOCItem.eventHandler.click = function (event) {
    if (!Object(EventEmitter["d" /* hitElement */])(this.$checkbox, event) && !Object(EventEmitter["d" /* hitElement */])(this.$quickMenuBtn, event)) {
        if (!Object(EventEmitter["d" /* hitElement */])(this.$toggleCtn, event) || !(this.status === "close" || this.status === 'open')) {
            this.emit('press', { type: 'press', originalEvent: event }, this)
        }
    }
};


ACore["d" /* default */].install(TOCItem);


/* harmony default export */ var js_TOCItem = (TOCItem);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/tool/BlurTrigger.js
var BlurTrigger = __webpack_require__(58);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TOCList.js









/***
 * @extends AElement
 * @constructor
 */
function TOCList() {
    this.$searchInput = null;
    this.$body = Object(ACore["a" /* $ */])('.as-toc-list-body', this);
    this.$searching = Object(ACore["a" /* $ */])('.as-toc-list-searching', this);

    this.rootController = new TOCVirtualRootController(this, [], this.$body);
    this.searchCache = {};
    this.savedState = { active: null, status: {} };
    /***
     * @name nodes
     * @type {{}[]}
     * @memberOf TOCList#
     */
}

TOCList.tag = 'TOCList'.toLowerCase();

TOCList.render = function () {
    return Object(ACore["c" /* _ */])({
        extendEvent: ['pressnode', 'checkednodechange', 'pressnodequickmmenu', 'statechange'],
        class: 'as-toc-list',
        child: [
            '.as-toc-list-body',
            '.as-toc-list-searching'
        ]
    });
};

TOCList.prototype.applySavedState = function () {
    var savedStatus = this.savedState.status;

    function visitArr(arr) {
        arr.forEach(function (ct) {
            var status = savedStatus[ct.ident];
            if (status) {
                ct.status = status;
            }
            savedStatus[ct.ident] = ct.status;
            visitArr(ct.children);
        });
    }

    visitArr(this.rootController.children);

    var activeCt = this.findControllerByIdent(this.savedState.active);
    if (activeCt) activeCt.active();
};

TOCList.prototype.resetSavedState = function () {
    this.savedState = { active: null, status: {} };
};

TOCList.prototype.saveState = function () {
    var oldState = this.savedState;
    var savedState = { active: null, status: {} };
    var changed = false;

    function visitArr(arr) {
        arr.forEach(function (ct) {
            savedState.status[ct.ident] = ct.status;
            changed = changed || savedState.status[ct.ident] !== oldState.status[ct.ident];
            if (ct.nodeElt.containsClass('as-active')) {
                savedState.active = ct.ident;
            }
            visitArr(ct.children);
        });
    }

    changed = changed || (oldState.active !== savedState.active);

    visitArr(this.rootController.children);
    this.savedState = savedState;
    if (changed) this.notifySavedStateChange();
};

TOCList.prototype.notifySavedStateChange = function () {
    this.emit('statechange', { target: this, type: 'statechange' }, this);
};

TOCList.prototype.loadSavedState = function (savedState) {
    savedState = savedState || {};
    this.savedState = {
        active: savedState.active || null,
        status: savedState.status || {}
    };
    this.applySavedState();
};


TOCList.prototype.openAllNodeRecursive = function () {
    this.rootController.openRecursive();
    this.savedState();
};

TOCList.prototype.closeAllNodeRecursive = function () {
    this.rootController.closeRecursive();
    this.savedState();
};

TOCList.prototype.deactivateAllNode = function () {
    this.rootController.deactivateRecursive();
};


/***
 *
 * @param ident
 * @returns {TOCNodeController|null}
 */
TOCList.prototype.activeNode = function (ident) {
    var nodeCt = this.findControllerByIdent(ident);
    if (nodeCt) nodeCt.active();
    return nodeCt;
};

/***
 *
 * @param {string} ident
 * @param {TOCNodeController|TOCVirtualRootController=} rootController
 * @returns {TOCNodeController}
 */
TOCList.prototype.findControllerByIdent = function (ident, rootController) {
    var res = null;
    rootController = rootController || this.rootController;

    function visitArr(arr) {
        arr.some(function (ct) {
            if (ct.ident === ident) {
                res = ct;
                return true;
            }
            visitArr(ct.children);
        });
    }

    visitArr(rootController.children);
    return res;
};

TOCList.prototype.makeNodeController = function (nodeData) {
    return new TOCNodeController(this, nodeData, null);
};

/**
 *
 * @param query
 * @private
 * @returns {TOCVirtualRootController}
 */
TOCList.prototype._calcSearch = function (query) {
    var searchRootController = this.searchCache[query];
    if (searchRootController) return searchRootController;
    var itemTree = this.searchCache.__itemTree__;
    if (!itemTree) {
        itemTree = this.nodes.map(function visit(node) {
            var item = Object(search["b" /* default */])({ text: node.name, value: Object.assign({}, node) });
            if (node.children && node.children.length > 0) {
                item.items = node.children.map(visit);
            }
            return item;
        });
        this.searchCache.__itemTree__ = itemTree;
    }
    var resultItemTree = Object(search["e" /* searchTreeListByText */])(query, itemTree);
    var resultNodes = resultItemTree.map(function visit2(item) {
        var node = Object.assign({}, item.value);
        delete node.children;
        if (item.items && item.items.length > 0) {
            node.children = item.items.map(visit2);
        }
        return node;
    });
    this.searchCache[query] = new TOCVirtualRootController(this, resultNodes)
    return this.searchCache[query];
};

TOCList.prototype.search = function (query) {
    query = query || '';
    query = query.trim().replace('\s(\s+)', ' ');
    var searchRoot = this._calcSearch(query);
    var activeNodeCt;
    if (query.length === 0) {
        this.removeClass('as-searching');
        this.$searching.clearChild();
    }
    else {
        this.addClass('as-searching');
        this.$searching.clearChild();
        searchRoot.openRecursive();
        activeNodeCt = this.findControllerByIdent(this.savedState.active, searchRoot);
        if (activeNodeCt) activeNodeCt.active();
        searchRoot.view = this.$searching;
    }
};


TOCList.property = {};

TOCList.property.nodes = {
    /***
     * @this TOCList
     * @param nodes
     */
    set: function (nodes) {
        this.searchCache = {};
        nodes = nodes || [];
        this.rootController = new TOCVirtualRootController(this, nodes);
        this.rootController.view = this.$body;

        this.applySavedState();
    },
    get: function () {
        return this.rootController.nodes;
    }
};

TOCList.property.searchInput = {
    /***
     * @this TOCList
     */
    set: function (elt) {
        if (this.$searchInput) {
            this.$searchInput.off('stoptyping', this.eventHandler.searchTextInputModify);
        }
        this.$searchInput = elt;
        if (this.$searchInput) {
            this.$searchInput.on('stoptyping', this.eventHandler.searchTextInputModify);
        }
    },
    /***
     * @this TOCList
     */
    get: function () {
        return this.$searchInput;
    }
}


/***
 * @memberOf TOCList#
 * @type {{}}
 */
TOCList.eventHandler = {};


TOCList.eventHandler.pressNode = function (nodeController, event) {
    var newEvent = {
        type: 'pressnode', target: this,
        originalEvent: event.originalEvent || event,
        controller: nodeController,
        nodeData: nodeController.nodeElt.nodeData,
        nodeElt: nodeController.nodeElt,
    };
    this.emit('pressnode', newEvent, this);
};

TOCList.eventHandler.checkedNodeChange = function (nodeController, event) {
    var newEvent = {
        type: 'checkednodechange',
        target: this,
        originalEvent: event.originalEvent || event,
        controller: nodeController,
        nodeData: nodeController.nodeElt.nodeData,
        nodeElt: nodeController.nodeElt
    };
    this.emit('checkednodechange', newEvent, this);
};


TOCList.eventHandler.pressNodeQuickMenu = function (nodeController, event) {
    var newEvent = {
        type: 'pressnodequickmmenu',
        target: this,
        originalEvent: event.originalEvent || event,
        controller: nodeController,
        nodeData: nodeController.nodeElt.nodeData,
        nodeElt: nodeController.nodeElt
    };

    newEvent.showMenu = function (menuProps, onSelect) {
        var token = QuickMenu["a" /* default */].show(nodeController.nodeElt.$quickMenuBtn, menuProps, 'auto', onSelect, false);
        var blurTrigger = new BlurTrigger["a" /* default */]([], 'click', function () {
            QuickMenu["a" /* default */].close(token);
        }, 10, 30);
    };
    this.emit('pressnodequickmmenu', newEvent, this);
};

/***
 * @this TOCList
 */
TOCList.eventHandler.searchTextInputModify = function () {
    this.search(this.$searchInput.value);
};


ACore["d" /* default */].install(TOCList);

/***
 *
 * @param {TOCList} listElt
 * @param {{}[]} nodes
 * @constructor
 */
function TOCVirtualRootController(listElt, nodes) {
    Object.defineProperties(this, {
        root: {
            value: this
        }
    });
    this.listElt = listElt;
    this.level = -1;
    this.nodes = nodes;
    /***
     *
     * @type {TOCNodeController[]}
     */
    this.children = nodes.map(function (nodeData) {
        return new TOCNodeController(listElt, nodeData, this);
    }.bind(this));
    this._view = null;
    /****
     * @type {AElement}
     * @name view
     * @memberOf TOCVirtualRootController#
     */
}


TOCVirtualRootController.prototype.deactivateRecursive = function () {
    this.children.forEach(function (ct) {

    });
};

TOCVirtualRootController.prototype.openRecursive = function () {
    this.children.forEach(function (ct) {
        ct.openRecursive();
    });
};

TOCVirtualRootController.prototype.closeRecursive = function () {
    this.children.forEach(function (ct) {
        ct.closeRecursive();
    });
};

TOCVirtualRootController.prototype.getViewElements = function () {
    var ac = [];
    this.children.forEach(function (ct) {
        ct.getViewElements(ac);
    });
    return ac;
};

TOCVirtualRootController.prototype.indexOfChild = function (child) {
    for (var i = 0; i < this.children.length; ++i) {
        if (child === this.children[i] || this.children[i].ident === child) return i;
    }
    return -1;
};

/***
 *
 * @param {TOCNodeController} controller
 * @param {TOCNodeController} at
 * @returns {TOCVirtualRootController}
 */
TOCVirtualRootController.prototype.addChildBefore = function (controller, at) {
    var atIdx;
    if (at) {
        atIdx = this.indexOfChild(at);
        if (atIdx >= 0) {
            if (controller.parent) controller.remove();

            this.children.splice(atIdx, 0, controller);
            controller.__parent__ = this;
            if (at.nodeElt.parentElement) {
                Object(utils["addElementsBefore"])(at.nodeElt.parentElement, controller.getViewElements(), at.nodeElt);
            }
            this.updateStatus();
        }
        else {
            throw new Error("The node before which the new node is to be inserted is not a child of this node.");

        }
    }
    else {
        if (controller.parent) controller.remove();
        this.children.push(controller);
        if (this.view) this.addChild(controller.getViewElements());
        this.updateStatus();
    }
    controller.setLevelRecursive(this.level + 1);
    return this;
};


TOCVirtualRootController.prototype.addChild = function (controller) {
    this.addChildBefore(controller, null);
    return this;
};

/***
 *
 * @param {TOCNodeController} controller
 * @param at
 */
TOCVirtualRootController.prototype.addChildAfter = function (controller, at) {
    var atIdx;
    var lastElement;
    if (at) {
        atIdx = this.indexOfChild(at);
        if (atIdx === this.children.length) {
            if (controller.parent) controller.remove();
            controller.__parent__ = this;
            this.children.push(controller);
            if (this.view) this.view.addChild(controller.getViewElements());
        }
        else if (atIdx >= 0) {
            if (controller.parent) controller.remove();
            controller.__parent__ = this;
            this.children.splice(atIdx, 0, controller);
            if (at.nodeElt.parentElement) {
                lastElement = at.getViewElements().pop();
                Object(utils["addElementAfter"])(at.nodeElt.parentElement, controller.getViewElements(), lastElement);

            }
        }
        else {
            throw new Error("The node before which the new node is to be inserted is not a child of this node.");
        }
    }
    else {
        if (controller.parent) controller.remove();
        controller.__parent__ = this;
        this.children.unshift(controller);
        Object(utils["addElementAfter"])(this.view, controller.getViewElements(), this.view.firstChild);
    }
    return this;
};

TOCVirtualRootController.prototype.updateStatus = noop["a" /* default */];

/***
 * @param {TOCNodeController} child
 * @returns {TOCVirtualRootController|TOCNodeController}
 */
TOCVirtualRootController.prototype.removeChild = function (child) {
    var idx = this.children.indexOf(child);
    if (idx >= 0) {
        this.children.splice(idx, 1);
        child.getViewElements().forEach(function (elt) {
            elt.remove();
        });
        this.updateStatus();
    }
    return this;
};


/***
 *
 * @param {function(nodeCt:TOCNodeController):(void|boolean)} callback return true to stop
 */
TOCVirtualRootController.prototype.traverse = function (callback) {
    this.children.some(function visit(ct) {
        return callback(ct) || ct.children.some(visit);
    });
};


Object.defineProperties(TOCVirtualRootController.prototype, {
    firstChild: {
        get: function () {
            return this.children[0] || null;
        }
    },
    lastChild: {
        get: function () {
            return this.children[this.children.length - 1] || null;
        }
    },
    view: {
        /***
         * @this TOCVirtualRootController
         * @param view
         */
        set: function (view) {
            view = view || null;
            if (view === this._view) return;
            if (this._view) {
                this._view.clearChild();

                this._view.rootController = null;
                this._view = null;
            }
            if (view) {
                if (view.rootController) {
                    view.rootController.view = null;
                }
                view.rootController = this;
                this._view = view;
                this._view.addChild(this.getViewElements());
            }
        },
        get: function () {
            return this._view;
        }
    }
});

/***
 *
 * @param {TOCList} listElt
 * @param {{}} nodeData
 * @param {TOCNodeController|TOCVirtualRootController} parent
 * @constructor
 */
function TOCNodeController(listElt, nodeData, parent) {
    Object.defineProperties(this, {
        listElt: { value: listElt },
        __parent__: {
            value: parent,
            enumerable: false,
            writable: true
        }
    });
    this.level = parent ? parent.level + 1 : 0;
    /***
     * @type {TOCItem}
     */
    this.nodeElt = Object(ACore["c" /* _ */])({
        tag: js_TOCItem.tag,
        props: {
            nodeData: nodeData,
            checked: !!nodeData.checked,
            name: nodeData.name,
            icon: nodeData.icon,
            level: this.level,
            controller: this,
            status: 'none'
        },
        on: {
            presstoggle: this.toggle.bind(this),
            press: this.ev_press.bind(this),
            checkedchange: this.ev_checkedChange.bind(this),
            pressquickmenu: this.ev_pressQuickMenu.bind(this)
        }
    });

    this.nodeElt.on('presstoggle', this.listElt.saveState.bind(this.listElt));
    /***
     * @name children
     * @type {TOCNodeController[]}
     * @memberOf TOCNodeController#
     */
    if (nodeData.children && nodeData.children.length > 0) {
        this.nodeElt.status = 'close';
        this.children = nodeData.children.map(function (c) {
            return new TOCNodeController(listElt, c, this);
        }.bind(this));
    }
    else {
        this.children = [];
    }
}

TOCNodeController.prototype.indexOfChild = TOCVirtualRootController.prototype.indexOfChild;

TOCNodeController.prototype.traverse = TOCVirtualRootController.prototype.traverse;

TOCNodeController.prototype.updateStatus = function () {
    if (this.children.length === 0 && this.nodeElt.status !== 'none') {
        this.nodeElt.status = 'none';
    }
    else if (this.children.length > 0 && this.nodeElt.status === 'none') {
        this.nodeElt.status = 'close';
    }
};

TOCNodeController.prototype.deactivateRecursive = function () {
    this.nodeElt.removeClass('as-active');
    this.children.forEach(function (ct) {
        ct.deactivateRecursive();
    });
};

TOCNodeController.prototype.removeChild = TOCVirtualRootController.prototype.removeChild;

TOCNodeController.prototype.remove = function () {
    this.parent.removeChild(this);
};


/***
 *
 * @param {TOCNodeController} controller
 * @param {TOCNodeController} at
 * @returns {TOCNodeController}
 */
TOCNodeController.prototype.addChildBefore = function (controller, at) {
    var atIdx;
    if (at) {
        atIdx = this.indexOfChild(at);
        if (atIdx >= 0) {
            if (controller.parent) controller.remove();
            this.children.splice(atIdx, 0, controller);
            controller.__parent__ = this;
            if (this.status === 'open') {
                Object(utils["addElementsBefore"])(this.nodeElt.parentElement, controller.getViewElements(), at.nodeElt);
            }
            controller.setLevelRecursive(this.level + 1);
            this.updateStatus();
        }
        else {
            throw new Error("The node before which the new node is to be inserted is not a child of this node.");
        }
    }
    else {
        if (controller.parent) controller.remove();
        this.children.push(controller);
        this.updateStatus();
        if (this.status === "open") {
            Object(utils["addElementsBefore"])(this.nodeElt.parentElement, controller.getViewElements(), at.nodeElt);
        }

    }
    return this;
};

TOCNodeController.prototype.addChild = TOCVirtualRootController.prototype.addChild;

TOCNodeController.prototype.addChildAfter = function (controller, at){

    throw new Error("Not implement!");
};


TOCNodeController.prototype.toggle = function () {
    if (this.status === 'close') this.open();
    else if (this.status === 'open') this.close();
};


TOCNodeController.prototype.open = function () {
    if (this.status !== 'close') return;
    this.nodeElt.status = 'open';
    var pE = this.nodeElt.parentElement;
    if (!pE) return;
    var veArr = this.getViewElements();
    veArr.shift();
    var at = pE.findChildAfter(this.nodeElt);
    if (at) {
        while (veArr.length > 0) {
            pE.addChildBefore(veArr.shift(), at);
        }
    }
    else {
        pE.addChild(veArr);
    }
};


TOCNodeController.prototype.close = function () {
    if (this.status !== 'open') return;
    var veArr = this.getViewElements();
    veArr.shift();
    while (veArr.length > 0) {
        veArr.pop().remove()
    }
    this.nodeElt.status = 'close';
};


TOCNodeController.prototype.getViewElements = function (ac) {
    if (ac === undefined) ac = [];
    ac.push(this.nodeElt);
    if (this.status === 'open' && this.children.length > 0) {
        this.children.forEach(function (ct) {
            ct.getViewElements(ac);
        });
    }
    return ac;
};

TOCNodeController.prototype.setLevelRecursive = function (value) {
    this.level = value;
    this.nodeElt.level = value;
    this.children.forEach(function (ct) {
        ct.setLevelRecursive(value + 1);
    });
};

TOCNodeController.prototype.openRecursive = function () {
    if (this.status === 'close') {
        this.open();
    }
    this.children.forEach(function (ct) {
        ct.openRecursive();
    });
};


TOCNodeController.prototype.ev_press = function (event) {
    this.listElt.eventHandler.pressNode(this, event);
};


TOCNodeController.prototype.ev_checkedChange = function (event) {
    this.nodeElt.nodeData.checked = this.nodeElt.checked;
    this.listElt.eventHandler.checkedNodeChange(this, event);
};

TOCNodeController.prototype.ev_pressQuickMenu = function (event) {
    this.listElt.eventHandler.pressNodeQuickMenu(this, event);
};

TOCNodeController.prototype.closeRecursive = function () {
    if (this.status === 'open') {
        this.close();
    }
    this.children.forEach(function (ct) {
        ct.openRecursive();
    });
};

/***
 *
 * @param {boolean=true} isActive default: true
 */
TOCNodeController.prototype.active = function (isActive) {
    var self = this;
    if (arguments.length === 0) isActive = true;
    //todo: notify savedState change
    if (isActive) {
        this.root.traverse(function (ct) {
            if (ct === self) {
                ct.nodeElt.addClass('as-active');
            }
            else
                ct.nodeElt.removeClass('as-active');
        });
        if (this.listElt.savedState.active !== this.ident) {
            this.listElt.savedState.active = this.ident;
            this.listElt.notifySavedStateChange();
        }
    }
    else {
        if (this.listElt.savedState.active === this.ident) {
            this.listElt.savedState.active = this.ident;
        }
        this.nodeElt.removeClass('as-active');
    }
};


Object.defineProperties(TOCNodeController.prototype, {
    /***
     * @memberOf TOCNodeController#
     * @name status
     * @type {"open"|"close"|"none"}
     */
    status: {
        get: function () {
            return this.nodeElt.status;
        },
        set: function (value) {
            if (value === 'open' && this.nodeElt.status === 'close') this.open();
            else if (value === 'close' && this.nodeElt.status === 'open') this.close();
        }
    },
    root: {
        get: function () {
            return this.parent ? this.parent.root : this;
        }
    },
    checked: {
        get: function () {
            return !!this.nodeElt.nodeData.checked;
        },
        set: function (value) {
            this.nodeElt.checked = !!value;
            this.nodeElt.nodeData.checked = !!value;
        }
    },
    name: {
        set: function (value) {
            value = value || '';
            this.nodeElt.name = value;
            this.nodeElt.nodeData.name = value;
        },
        get: function () {
            return this.nodeElt.nodeData.name;
        }
    },
    ident: {
        get: function () {
            return this.nodeElt.nodeData.ident;
        },
        set: function (value) {
            this.nodeElt.nodeData.ident = value;
        }
    },
    nodeData: {
        get: function () {
            return this.nodeElt.nodeData;
        },
        set: function (value) {
            this.nodeElt.nodeData = value;
        }
    },
    parent: {
        get: function () {
            return this.__parent__;
        }
    },
    firstChild: {
        get: function () {
            return this.children[0] || null;
        }
    },
    lastChild: {
        get: function () {
            return this.children[this.children.length - 1] || null;
        }
    }
});

/* harmony default export */ var js_TOCList = (TOCList);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/ckplaceholder.css
var ckplaceholder = __webpack_require__(309);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/ckeditor/ckcontentstyle.css.tpl
/* harmony default export */ var ckcontentstyle_css = ("\n.as-ck-alert {\n    padding: .75rem 1.25rem;\n    margin-bottom: 1rem;\n    border: 1px solid transparent;\n    border-radius: .188rem;\n}\n\n.as-ck-alert.as-variant-notice {\n    color: #7b5700;\n    background-color: #fbedcc;\n    border-color: #fae6b8;\n}\n\n.as-ck-alert.as-variant-warning {\n    color: #852d19;\n    background-color: #ffddd6;\n    border-color: #ffd0c5;\n}\n\n.as-ck-alert.as-variant-info{\n    color: #352c64;\n    background-color: #e0ddf2;\n    border-color: #d4cfed;\n}\n\n.as-ck-alert.as-variant-success {\n    color: #2a601f;\n    background-color: #dcf1d8;\n    border-color: #ceebc8;\n}\n\n.cke_contents_ltr ul{\n    list-style: none;\n}\n\n.cke_contents_ltr  ul li::before {\n    color: #007bff;\n    content: '●';\n    padding-inline-end: 1ch;\n}\n\n.cke_button_icon.cke_button__insert_expression_icon{\n    background-image:url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgIi0vL1czQy8vRFREIFNWRyAxLjEvL0VOIiAiaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEuZHRkIj4KPHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB2ZXJzaW9uPSIxLjEiICB3aWR0aD0iMjQiIGhlaWdodD0iMjQiIHZpZXdCb3g9IjAgMCAyNCAyNCI+CiAgIDxwYXRoIGZpbGw9IiMwMDAwMDAiIGQ9Ik01LDNIN1Y1SDVWMTBBMiwyIDAgMCwxIDMsMTJBMiwyIDAgMCwxIDUsMTRWMTlIN1YyMUg1QzMuOTMsMjAuNzMgMywyMC4xIDMsMTlWMTVBMiwyIDAgMCwwIDEsMTNIMFYxMUgxQTIsMiAwIDAsMCAzLDlWNUEyLDIgMCAwLDEgNSwzTTE5LDNBMiwyIDAgMCwxIDIxLDVWOUEyLDIgMCAwLDAgMjMsMTFIMjRWMTNIMjNBMiwyIDAgMCwwIDIxLDE1VjE5QTIsMiAwIDAsMSAxOSwyMUgxN1YxOUgxOVYxNEEyLDIgMCAwLDEgMjEsMTJBMiwyIDAgMCwxIDE5LDEwVjVIMTdWM0gxOU0xMiwxNUExLDEgMCAwLDEgMTMsMTZBMSwxIDAgMCwxIDEyLDE3QTEsMSAwIDAsMSAxMSwxNkExLDEgMCAwLDEgMTIsMTVNOCwxNUExLDEgMCAwLDEgOSwxNkExLDEgMCAwLDEgOCwxN0ExLDEgMCAwLDEgNywxNkExLDEgMCAwLDEgOCwxNU0xNiwxNUExLDEgMCAwLDEgMTcsMTZBMSwxIDAgMCwxIDE2LDE3QTEsMSAwIDAsMSAxNSwxNkExLDEgMCAwLDEgMTYsMTVaIiAvPgo8L3N2Zz4=');\n    background-position:0 0px;\n    background-size:16px;\n}\n\n.cke_button_icon.cke_button__insert_variable_icon{\n    background-image:url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgIi0vL1czQy8vRFREIFNWRyAxLjEvL0VOIiAiaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEuZHRkIj4KPHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB2ZXJzaW9uPSIxLjEiICB3aWR0aD0iMjQiIGhlaWdodD0iMjQiIHZpZXdCb3g9IjAgMCAyNCAyNCI+CiAgIDxwYXRoIGZpbGw9IiMwMDAwMDAiIGQ9Ik0yMC40MSwzQzIxLjgsNS43MSAyMi4zNSw4Ljg0IDIyLDEyQzIxLjgsMTUuMTYgMjAuNywxOC4yOSAxOC44MywyMUwxNy4zLDIwQzE4LjkxLDE3LjU3IDE5Ljg1LDE0LjggMjAsMTJDMjAuMzQsOS4yIDE5Ljg5LDYuNDMgMTguNyw0TDIwLjQxLDNNNS4xNywzTDYuNyw0QzUuMDksNi40MyA0LjE1LDkuMiA0LDEyQzMuNjYsMTQuOCA0LjEyLDE3LjU3IDUuMywyMEwzLjYxLDIxQzIuMjEsMTguMjkgMS42NSwxNS4xNyAyLDEyQzIuMiw4Ljg0IDMuMyw1LjcxIDUuMTcsM00xMi4wOCwxMC42OEwxNC40LDcuNDVIMTYuOTNMMTMuMTUsMTIuNDVMMTUuMzUsMTcuMzdIMTMuMDlMMTEuNzEsMTRMOS4yOCwxNy4zM0g2Ljc2TDEwLjY2LDEyLjIxTDguNTMsNy40NUgxMC44TDEyLjA4LDEwLjY4WiIgLz4KPC9zdmc+');\n    background-position:0 0px;\n    background-size:16px;\n}\n.cke_button_icon.cke_button__insert_dynamic_link_icon{\n    background-image:url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgIi0vL1czQy8vRFREIFNWRyAxLjEvL0VOIiAiaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEuZHRkIj4KPHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB2ZXJzaW9uPSIxLjEiICB3aWR0aD0iMjQiIGhlaWdodD0iMjQiIHZpZXdCb3g9IjAgMCAyNCAyNCI+CiAgIDxwYXRoIGZpbGw9IiMwMDAwMDAiIGQ9Ik0zIDFDMS44OSAxIDEgMS44OSAxIDNWMTRDMSAxNS4xMSAxLjg5IDE2IDMgMTZIMTRDMTUuMTEgMTYgMTYgMTUuMTEgMTYgMTRWMTFIMTRWMTRIM1YzSDE0VjVIMTZWM0MxNiAxLjg5IDE1LjExIDEgMTQgMU05IDdDNy44OSA3IDcgNy44OSA3IDlWMTJIOVY5SDIwVjIwSDlWMThIN1YyMEM3IDIxLjExIDcuODkgMjIgOSAyMkgyMEMyMS4xMSAyMiAyMiAyMS4xMSAyMiAyMFY5QzIyIDcuODkgMjEuMTEgNyAyMCA3SDkiIC8+Cjwvc3ZnPg==');\n    background-position:0 0px;\n    background-size:16px;\n}\n\n\n.as-ck-widget-expression\n{\n    color: #1da1ff;\n}\n\n.as-ck-widget-variable\n{\n    color: #144f25;\n}\n");
// CONCATENATED MODULE: ./node_modules/absol/src/DataStructure/Array.js
/***
 *
 * @param {(string|number|boolean|null)[]} arr
 * @returns {(string|number|boolean|null)[]}
 */
function arrayUnique(arr) {
    var dict = {};
    return arr.reduce(function (ac, cr) {
        var key = (typeof cr) + '//' + cr;
        if (key in dict) return ac;
        ac.push(cr);
        dict[key] = true;
        return ac;
    }, []);
}

/***
 *
 * @param {[]}arr
 * @return {[]}
 */
function arrayRemoveNone(arr) {
    return arr.filter(function (c) {
        return c !== null && c !== undefined;
    });
}
// EXTERNAL MODULE: ./node_modules/absol/src/JSMaker/TemplateString.js
var TemplateString = __webpack_require__(26);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/ckeditor/ExpressionExtension.js



var ExpressionExtension_name = 'expression';
var command = 'insert_expression';

function init(editor) {
    editor.widgets.add(ExpressionExtension_name, {
        button: 'Create Expression',
        template:
            '<span class="as-ck-widget-expression">&#0123;&#0123; expression &#0125;&#0125;</span>',
        allowedContent: 'span(!as-ck-widget-expression)',
        requiredContent: 'span(as-ck-widget-expression)',
        upcast: function (element) {
            return element.name === 'span' && element.hasClass('as-ck-widget-expression');
        }
    });


    editor.ui.addButton(command, {
        label: 'Insert expression',
        command: command,
    });


    editor.addCommand(command, {
        exec: function (editor) {
            if (editor.placeHolderElt) {
                editor.placeHolderElt.emit('command', { command: command, target: editor, type: 'command' });
            }
        }
    });
}

var parserDiv = Object(ACore["c" /* _ */])('div');

function explicit(data, placeHolderElt) {
    parserDiv.innerHTML = data;
    Object(ACore["b" /* $$ */])('.as-ck-widget-expression', parserDiv).forEach(function (elt) {
        var text = elt.innerHTML;
        text.replace(/&#0123;/g, '{').replace(/&#0125;/g, '}');
        elt.parentElement.replaceChild(Object(ACore["c" /* _ */])({ text: text }), elt)
    });
    return parserDiv.innerHTML;
}

function implicit(data, placeHolderElt) {
    var template = TemplateString["a" /* default */].parse(data);
    return template.parts.slice().map(function (part) {
        if (part.type === 1) {
            return '<span class="as-ck-widget-expression">&#0123;&#0123; ' + part.data.trim() + ' &#0125;&#0125;</span>'
        }
        else return part.data;
    }).join('');
}


/* harmony default export */ var ExpressionExtension = ({
    name: ExpressionExtension_name,
    command: command,
    implicit: implicit,
    explicit: explicit,
    plugin: {
        requires: 'widget',
        init: init
    },
    extendMethods: {
        /***
         * @this CKPlaceholder
         * @memberOf CKPlaceholder#
         * @param expression
         *
         */
        insertExpression: function (expression) {
            this.editor.insertHtml('<span class="as-ck-widget-expression">&#0123;&#0123; ' + expression.trim() + ' &#0125;&#0125;</span>')
        },
        getSelectedExpression: function () {
            var sel = this.editor.getSelection();
            if (!sel) return null;
            var elt = sel.getSelectedElement();
            if (!elt) return null;
            if (!elt.hasClass('cke_widget_wrapper_as-ck-widget-expression')) return null;
            var exp = elt.getText();
            exp = exp.replace(/&#0123;|&#0125;|\{|\}/g, '').trim();
            return exp;
        }
    }
});
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/ckeditor/SimpleTextExtension.js


var SimpleTextExtension_name = 'simple_text';

var SimpleTextExtension_parserDiv = Object(ACore["c" /* _ */])('div');

function SimpleTextExtension_explicit(data, placeHolderElt) {
    SimpleTextExtension_parserDiv.innerHTML = data.replace(/&nbsp;/g, ' ');
    return SimpleTextExtension_parserDiv.innerText;
}

function SimpleTextExtension_implicit(data, placeHolderElt) {
    return data
        //.replace(/</g, '&lt;').replace(/</g, '&gt;').replace(/"/g, '&quot;').replace(/&/g, '&amp;')
        .replace(/[\r\n]/g, '');
}


/* harmony default export */ var SimpleTextExtension = ({
    name: SimpleTextExtension_name,
    implicit: SimpleTextExtension_implicit,
    explicit: SimpleTextExtension_explicit,
});
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/ckeditor/VariableExtension.js



var VariableExtension_name = 'variable';
var VariableExtension_command = 'insert_variable';

function VariableExtension_init(editor) {
    editor.widgets.add(VariableExtension_name, {
        button: 'Create Variable',
        template:
            '<span class="as-ck-widget-variable" title="variable">variable</span>',
        allowedContent: 'span(!as-ck-widget-variable)',
        requiredContent: 'span(as-ck-widget-variable)',
        upcast: function (element) {
            return element.name === 'span' && element.hasClass('as-ck-widget-variable');
        }
    });


    editor.ui.addButton(VariableExtension_command, {
        label: 'Insert Variable',
        command: VariableExtension_command,
    });


    editor.addCommand(VariableExtension_command, {
        exec: function (editor) {
            if (editor.placeHolderElt) {
                editor.placeHolderElt.emit('command', { command: VariableExtension_command, target: editor, type: 'command' });
            }
        }
    });
}

var VariableExtension_parserDiv = Object(ACore["c" /* _ */])('div');

function VariableExtension_explicit(data, placeHolderElt) {
    VariableExtension_parserDiv.innerHTML = data;
    Object(ACore["b" /* $$ */])('.as-ck-widget-variable', VariableExtension_parserDiv).forEach(function (elt) {
        var text = elt.innerHTML;
        elt.parentElement.replaceChild(Object(ACore["c" /* _ */])({ text: text }), elt)
    });
    return VariableExtension_parserDiv.innerHTML;
}

var tokenRgx = /("([^\\"]|(\\.))*")|([a-zA-Z_$A-Z]([a-zA-Z_$A-Z0-9]*))/g;

function VariableExtension_implicit(data, placeHolderElt) {
    data = (data || '') + '';
    data = data.replace(tokenRgx, function (full, isString, u1, u2, isIdent) {
        if (isIdent && placeHolderElt.variables && placeHolderElt.variables[isIdent]) {
            return placeHolderElt.makeVariableHtml(isIdent);
        }
        else return full;
    });
    return data;

}


/* harmony default export */ var VariableExtension = ({
    name: VariableExtension_name,
    command: VariableExtension_command,
    implicit: VariableExtension_implicit,
    explicit: VariableExtension_explicit,
    plugin: {
        requires: 'widget',
        init: VariableExtension_init
    },
    extendMethods: {
        makeVariableHtml: function (variable, text) {
            variable = variable.trim();
            if (this.variables && this.variables[variable]) {
                text = this.variables[variable].text;
            }
            text = text || variable;
            return '<span class="as-ck-widget-variable"  title="' + text + '">' + variable.trim() + '</span>';
        },
        /***
         * @this CKPlaceholder
         * @memberOf CKPlaceholder#
         * @param variable
         *
         */
        insertVariable: function (variable, text) {
            this.editor.insertHtml(this.makeVariableHtml(variable, text));
        },
        getSelectedVariable: function () {
            var sel = this.editor.getSelection();
            if (!sel) return null;
            var elt = sel.getSelectedElement();
            if (!elt) return null;
            if (!elt.hasClass('cke_widget_wrapper_as-ck-widget-variable')) return null;
            var exp = elt.getText();
            exp = exp.trim();
            return exp;
        }
    }
});

/***
 * @name variables
 * @type {{}}
 * @memberOf CKPlaceholder#
 */
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/ckeditor/DynamicLinkExtension.js


var DynamicLinkExtension_name = 'dynamic_link';
var DynamicLinkExtension_command = 'insert_dynamic_link';

function DynamicLinkExtension_init(editor) {
    editor.widgets.add(DynamicLinkExtension_name, {
        button: 'Create Dynamic Link',
        template:
            '<a class="as-ck-widget-dynamic-link" data-link-id="1234" href="https://absol.cf">absol.cf</a>',
        allowedContent: 'a(!as-ck-widget-dynamic-link)',
        requiredContent: 'a(as-ck-widget-dynamic-link)',
        upcast: function (element) {
            return element.name === 'a' && element.hasClass('as-ck-widget-dynamic-link');
        }
    });


    editor.ui.addButton(DynamicLinkExtension_command, {
        label: 'Insert Dynamic Link',
        command: DynamicLinkExtension_command,
    });


    editor.addCommand(DynamicLinkExtension_command, {
        exec: function (editor) {
            if (editor.placeHolderElt) {
                editor.placeHolderElt.emit('command', { command: DynamicLinkExtension_command, target: editor, type: 'command' });
            }
        }
    });
}

var DynamicLinkExtension_parserDiv = Object(ACore["c" /* _ */])('div');

function DynamicLinkExtension_explicit(data, placeHolderElt) {
    DynamicLinkExtension_parserDiv.innerHTML = data;
    Object(ACore["b" /* $$ */])('.as-ck-widget-dynamic-link', DynamicLinkExtension_parserDiv).forEach(function (elt) {
    });
    return DynamicLinkExtension_parserDiv.innerHTML;
}

function DynamicLinkExtension_implicit(data, placeHolderElt) {
    DynamicLinkExtension_parserDiv.innerHTML = data;
    Object(ACore["b" /* $$ */])('.as-ck-widget-dynamic-link', DynamicLinkExtension_parserDiv).forEach(function (elt) {
        var id = elt.getAttribute('data-link-id');
        var info = placeHolderElt.dynamicLinks && placeHolderElt.dynamicLinks[id];
        console.log(info)
        if (info){
            elt.setAttribute('href', info.href);
            elt.innerHTML = info.text || info.href;
        }
    });
    return DynamicLinkExtension_parserDiv.innerHTML;
}


/* harmony default export */ var DynamicLinkExtension = ({
    name: DynamicLinkExtension_name,
    command: DynamicLinkExtension_command,
    implicit: DynamicLinkExtension_implicit,
    explicit: DynamicLinkExtension_explicit,
    plugin: {
        requires: 'widget',
        init: DynamicLinkExtension_init
    },
    extendMethods: {
        /***
         * @this CKPlaceholder
         * @memberOf CKPlaceholder#
         * @param {string} id
         * @param {string=} href
         * @param {string=} text
         *
         */
        insertDynamicLink: function (id, href, text) {
            var info = (this.dynamicLinks && this.dynamicLinks[id]) || {href:'.', text: 'undefined'};
            if (!href){
                href = info.href;
            }
            if (!text){
                text = info.text;
            }
            this.editor.insertHtml('<a class="as-ck-widget-dynamic-link" data-link-id="'+id+'" href="'+href+'">' + text + '</a>')
        },
        getSelectedDynamicLink: function () {
            var sel = this.editor.getSelection();
            if (!sel) return null;
            var elt = sel.getSelectedElement();
            if (!elt) return null;
            if (!elt.hasClass('cke_widget_wrapper_as-ck-widget-dynamic-link')) return null;
            return (elt.$.firstChild &&  elt.$.firstChild.getAttribute('data-link-id')) || null;
        }
    }
});

/***
 * @name dynamicLinks
 * @type {{}}
 * @memberOf CKPlaceholder#
 */

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/ckeditor/plugins.js









var ckContentStyleUrl;
var ckPluginInitialized = false;

var CKExtensions = [ExpressionExtension, SimpleTextExtension, VariableExtension, DynamicLinkExtension];

var CKExtensionDict = CKExtensions.reduce(function (ac, cr) {
    ac[cr.name] = cr;
    return ac;
}, {});


var CKStylesSetDefault = [
    {
        name: 'Notice',
        element: 'p',
        attributes: {
            class: 'as-ck-alert as-variant-notice'
        }
    },
    {
        name: 'Warning',
        element: 'p',
        attributes: {
            class: 'as-ck-alert as-variant-warning'
        }
    },
    {
        name: 'Tip',
        element: 'p',
        attributes: {
            class: 'as-ck-alert as-variant-info'
        }
    },
    {
        name: 'Success',
        element: 'p',
        attributes: {
            class: 'as-ck-alert as-variant-success'
        }
    }
];

function ckInit() {
    if (!window.CKEDITOR) return;
    if (ckPluginInitialized) return;
    var styleCode = ckcontentstyle_css;
    ckContentStyleUrl = URL.createObjectURL(Object(Converter_file["stringToBlob"])(styleCode, 'css'));
    ckPluginInitialized = true;
    document.head.appendChild(Object(ACore["c" /* _ */])('<link rel="stylesheet" href="' + ckContentStyleUrl + '">'));
    console.log('<link rel="stylesheet" href="' + ckContentStyleUrl + '">')
    CKEDITOR.stylesSet.add('as_styles_set_default', CKStylesSetDefault);
    CKExtensions.forEach(function (e) {
        if (e.plugin) {
            CKEDITOR.plugins.add(e.name, e.plugin)
        }
    })
}

function ckMakeDefaultConfig(config, extensions) {
    ckInit();
    config = config || {};
    config.stylesSet = ['as_styles_set_default'].concat(arrayUnique((config.stylesSet || '').trim().split(/\s*,\s*/)))
        .filter(function (c) {
            return !!c;
        }).join(',');
    if (!config.toolbar) {
        config.toolbar = [
            { name: 'basicstyles', items: ['Bold', 'Italic', 'Underline', 'Strike', 'Subscript', 'Superscript'] },
            { name: 'colors', items: ['TextColor', 'BGColor'] },
            { name: "format", items: ['CopyFormatting', 'RemoveFormat'] },
            {
                name: 'paragraph',
                items: ['NumberedList', 'BulletedList', '-', 'Outdent', 'Indent', '-', 'Blockquote', 'CreateDiv', '-', 'JustifyLeft', 'JustifyCenter', 'JustifyRight', 'JustifyBlock']
            },
            { name: 'styles', items: ['Styles', 'Format', 'Font', 'FontSize'] },
            { name: 'links', items: ['Link', 'Unlink', 'Anchor'] },
            {
                name: 'insert',
                items: ['Image', 'Table', 'HorizontalRule', 'Smiley', 'SpecialChar', 'PageBreak', 'Iframe']
            },
            { name: 'tools', items: ['Maximize', 'ShowBlocks'] },
            { name: 'editing', items: ['Find', 'Replace'] },
            // { name: "linkdb", items: ['LinkDB'] },
            {
                name: "extensions", items: extensions.map(function (eName) {
                    if (CKExtensionDict[eName] && CKExtensionDict[eName].command) {
                        return CKExtensionDict[eName].command;
                    }
                }).filter(function (u) {
                    return !!u;
                })
            },
            { name: 'document', items: ['Source'] }
        ];
    }

    config.toolbar = config.toolbar.filter(function (i) {
        return i.items && i.items.length > 0;
    })

    if (!config.height) {
        config.height = '500px';
    }

    var contentsCss = [ckContentStyleUrl];
    if (typeof config.contentsCss === "string") {
        contentsCss.push(config.contentsCss);
    }
    else if (config.contentsCss instanceof Array) {
        contentsCss.push.apply(contentsCss, config.contentsCss);
    }

    var has = contentsCss.some(function (url) {
        return url.indexOf('family=Material+Icons') >= 0;
    });
    if (!has) {
        contentsCss.push('https://fonts.googleapis.com/icon?family=Material+Icons');
    }
    has = contentsCss.some(function (url) {
        return url.indexOf(CKEDITOR.basePath + 'contents.css') >= 0;
    });
    if (!has) {
        contentsCss.push(CKEDITOR.basePath + 'contents.css?time=' + Math.random());
    }
    config.contentsCss = contentsCss;

    var extraPlugins = [];
    if (typeof config.extraPlugins === 'string') {
        extraPlugins.push.apply(extraPlugins, config.extraPlugins.trim().split(/\s*,\s*/));
    }
    else if (extraPlugins instanceof Array) {
        extraPlugins.push.apply(extraPlugins, config.extraPlugins)
    }

    extraPlugins = extraPlugins.filter(function (c) {
        return typeof c === 'string' && !!c;
    });
    CKExtensions.forEach(function (e) {
        if (extensions.indexOf(e.name) >= 0 && e.plugin) extraPlugins.push(e.name);
    });
    extraPlugins = arrayUnique(extraPlugins);
    config.extraPlugins = extraPlugins.join(',');
    config.allowedContent = true;//false: you must add button ui => bug

    Object.assign(config, {
        //style

        // htmlEncodeOutput: false,
        // entities: false,
        // basicEntities: false,
        // // config.cloudServices_uploadUrl: 'DDFFE2739B83A73DDF16AB641ECA2',
        // // config.cloudServices_tokenUrl: 'https://lab.daithangminh.vn/hr_system_settings/php/uploadMedia.php',
        // extraPlugins: 'LinkDB, Note',
        // filebrowserBrowseUrl: 'js/ckfinder/ckfinder.html',
        // filebrowserImageBrowseUrl: 'js/ckfinder/ckfinder.html?type=Images',
        // filebrowserFlashBrowseUrl: 'js/ckfinder/ckfinder.html?type=Flash',
        // filebrowserUploadUrl: 'js/ckfinder/core/connector/php/connector.php?command=QuickUpload&type=Files',
        // filebrowserImageUploadUrl: 'js/ckfinder/core/connector/php/connector.php?command=QuickUpload&type=Images',
        // filebrowserFlashUploadUrl: 'js/ckfinder/core/connector/php/connector.php?command=QuickUpload&type=Flash'
    });

    return config;
}

function ckAddDefaultStyleSet(ckEditor) {

}
// EXTERNAL MODULE: ./node_modules/process/browser.js
var browser = __webpack_require__(99);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/ckeditor/CKPlaceholder.js





/***
 * @extends AElement
 * @constructor
 */
function CKPlaceholder() {
    ckInit();
    this.$attachhook = Object(ACore["c" /* _ */])('attachhook').addTo(this);
    this.$attachhook.once('attached', this.eventHandler.attached);
    this._pendingData = '';
    this.editor = null;
    this._extensions = [];
    this._config = this._makeInitConfig();
    /***
     * @type {{}}
     * @name config
     * @memberOf CKPlaceholder#
     */
    /***
     * @type {string[]}
     * @name extensions
     * @memberOf CKPlaceholder#
     */
}

CKPlaceholder.tag = 'CKPlaceholder'.toLowerCase();

CKPlaceholder.render = function () {
    return Object(ACore["c" /* _ */])({
        extendEvent: ['editorcreated', 'editorready', 'change', 'command', 'focus'],
        class: 'as-ck-placeholder'
    });
};

CKPlaceholder.prototype.mode = 'replace';

/**
 *
 * @param {string}data
 * @private
 * @returns {string}
 */
CKPlaceholder.prototype._implicit = function (data) {
    if (typeof data !== "string") data = '';
    var self = this;
    return this._extensions.reverse().reduce(function (ac, cr) {
        var extension = CKExtensionDict[cr];
        if (extension.implicit) {
            ac = extension.implicit(ac, self);
        }
        return ac;
    }, data);
};

/**
 *
 * @param {string}data
 * @private
 * @returns {string}
 */
CKPlaceholder.prototype._explicit = function (data) {
    var self = this;
    return this._extensions.reduce(function (ac, cr) {
        var extension = CKExtensionDict[cr];
        if (extension && extension.explicit) {
            ac = extension.explicit(ac, self);
        }
        return ac;
    }, data);
};

/***
 * @returns {{}}
 * @protected
 */
CKPlaceholder.prototype._makeInitConfig = function () {
    return {};
};

/***
 * @memberOf CKPlaceholder#
 * @type {{}}
 */
CKPlaceholder.eventHandler = {};

/***
 * @this CKPlaceholder
 */
CKPlaceholder.eventHandler.attached = function () {
    this.$attachhook.remove();
    this.editor = this.mode === 'replace' ? CKEDITOR.replace(this, ckMakeDefaultConfig(this.config, this.extensions)) : CKEDITOR.inline(this, ckMakeDefaultConfig(this.config, this.extensions));
    this.editor.placeHolderElt = this;
    this.editor.on('instanceReady', this.eventHandler.instanceReady);
    this.editor.on('change', this.eventHandler.change);
    if (this.mode === 'replace'){
        this.editor.on('focus', function (event){
            this.emit('focus', {target: this, type:'focus', originalEvent: event});
        }.bind(this));
    }
    this._extensions.forEach(function (name) {
        var e = CKExtensionDict[name];
        if (e && e.extendMethods) {
            Object.assign(this, e.extendMethods);
        }
    }.bind(this));
    this.emit('editorcreated', { type: 'editorcreated', target: this, editor: this.editor }, this);
    if (this._pendingData.length > 0) {
        this.editor.setData(this._implicit(this._pendingData));
        this._pendingData = null;
    }
};

CKPlaceholder.eventHandler.instanceReady = function () {
    this.emit('editorready', { type: 'editorready', target: this, editor: this.editor }, this);
};

CKPlaceholder.eventHandler.change = function () {
    this.emit('change', { type: 'change', target: this, editor: this.editor }, this);
};


CKPlaceholder.property = {};

CKPlaceholder.property.data = {
    /***
     * @this CKPlaceholder
     * @param data
     */
    set: function (data) {
        if (typeof data !== "string") data = '';
        if (this.editor) {
            this.editor.setData(this._implicit(data));
        }
        else {
            this._pendingData = data;
        }
    },
    /***
     * @this CKPlaceholder
     * @returns {string}
     */
    get: function () {
        if (this.editor) return this._explicit(this.editor.getData());
        return this._pendingData;
    }
};

CKPlaceholder.property.rawData = {
    get: function () {
        if (this.editor) this.editor.getData();
        else return this._implicit(this._pendingData);
    }
};

CKPlaceholder.property.config = {
    set: function (value) {
        if (this.editor) {
            throw  new Error("Can not set config after the CKEditor created");
        }
        this._config = Object.assign(this._makeInitConfig(), value);
    },
    get: function () {
        return this._config;
    }
};

CKPlaceholder.property.extensions = {
    set: function (value) {
        if (this.editor) {
            throw  new Error("Can not set extensions after the CKEditor created");
        }
        value = value || [];
        if (typeof value === "string") value = [value];
        if (!(value instanceof Array)) value = [];
        this._extensions = value.filter(function (c) {
            return typeof c === "string" && c.length > 0 && CKExtensionDict[c];
        });
        this._extensions = value;
    },
    get: function () {
        return this._extensions;
    }
}

ACore["d" /* default */].install(CKPlaceholder);


/* harmony default export */ var ckeditor_CKPlaceholder = (CKPlaceholder);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/ckeditor/CKInlineShortText.js









/***
 * @extends CKPlaceholder
 * @constructor
 */
function CKInlineShortText() {
    ckeditor_CKPlaceholder.call(this);
    this.once('editorcreated', this.eventHandler.afterEditorCreated)
        .on('paste', this.eventHandler.paste, true)
        .once('editorready', this.eventHandler.afterEditorReady);

}

OOP["a" /* default */].mixClass(CKInlineShortText, ckeditor_CKPlaceholder);

CKInlineShortText.tag = 'CKInlineShortText'.toLowerCase();
CKInlineShortText.property = Object.assign({}, ckeditor_CKPlaceholder.property);
CKInlineShortText.eventHandler = Object.assign({}, ckeditor_CKPlaceholder.eventHandler);


CKInlineShortText.render = function () {
    return Object(ACore["c" /* _ */])({
        class: 'as-ck-inline-short-text',
        extendEvent: ['editorcreated', 'editorready', 'change', 'command'],
        id: Object(stringGenerate["randomIdent"])(8),
        attr: {
            contenteditable: 'true'
        }
    });
};

CKInlineShortText.prototype.mode = 'inline';

CKInlineShortText.prototype._makeInitConfig = function () {
    var config = {
        toolbar: [
            {
                name: 'extension',
                items: arrayRemoveNone(this._extensions.map(function (eName) {
                    if (CKExtensionDict[eName] && CKExtensionDict[eName].command) {
                        return CKExtensionDict[eName].command;
                    }
                }))
            }
        ],
        keystrokes: [
            [13 /* Enter */, 'blur'],
            [CKEDITOR.SHIFT + 13 /* Shift + Enter */, 'blur']
        ]
    };
    return config;
};

CKInlineShortText.property.extensions = Object.assign({}, ckeditor_CKPlaceholder.property.extensions,
    {
        set: function (value) {
            value = value || [];
            value.push('simple_text')
            value = arrayUnique(value);
            ckeditor_CKPlaceholder.property.extensions.set.call(this, value);
            this._config = this._makeInitConfig();
        }
    });


CKInlineShortText.prototype._hookScroll = function () {
    this.$scrollers = [];
    var c = this.parentElement;
    while (c) {
        this.$scrollers.push(c);
        c = c.parentElement;
    }
    this.$scrollers.push(document);
    this.$scrollers.forEach(function (elt) {
        elt.addEventListener('scroll', this.eventHandler.scroll);
    }.bind(this))
};

CKInlineShortText.prototype._unhookScroll = function () {
    this.$scrollers.forEach(function (elt) {
        elt.removeEventListener('scroll', this.eventHandler.scroll);
    }.bind(this))
};


CKInlineShortText.eventHandler.afterEditorCreated = function () {
    this.editor.on('paste', function (evt) {
        evt.cancel();
    });
};

CKInlineShortText.eventHandler.afterEditorReady = function (){
    this.$toolbarElt = this.$toolbarElt || Object(ACore["a" /* $ */])('#cke_' + this.attr('id'));
    this['removeToolbar'] = this.removeToolbar;
    this._hookScroll();
    setTimeout(this.eventHandler.tick, 5000);
}


CKInlineShortText.eventHandler.paste = function (event) {
    var self = this;
    var clipboardData = (event.clipboardData || window.clipboardData);
    /**Safari bug */
    event.preventDefault();

    if (clipboardData) {
        if (clipboardData.items) {
            var items = Array.prototype.slice.call(clipboardData.items);

            var plainTextItems = items.filter(function (item) {
                return item.type.indexOf('text/plain') >= 0;
            });
            if (plainTextItems.length > 0) {

                var plainTextItem = plainTextItems[0];//only one item
                plainTextItem.getAsString(function (text) {
                    self.editor.insertHtml(self._implicit(text))
                });
            }
        }
        else {
            var text = event.clipboardData.getData('text/plain');
            if (text) {
                self.editor.insertHtml(self._implicit(text))
            }

        }
    }
};

CKInlineShortText.eventHandler.tick = function () {
    if (!this.isDescendantOf(document.body)) {
        this._unhookScroll();
        return;
    }
    setTimeout(this.eventHandler.tick, 5000);
}

/***
 * @this CKInlineShortText
 */
CKInlineShortText.eventHandler.scroll = function () {
    // If we don't have any active instance of CKEDITOR - return
    if (!CKEDITOR.currentInstance) {
        return;
    }
    if (CKEDITOR.currentInstance.element.$ !== this) return;
    // Save the elements we need to work with
    if (!this.isDescendantOf(document.body)) {
        this._unhookScroll();
        return;
    }
    this.$toolbarElt = this.$toolbarElt || Object(ACore["a" /* $ */])('#cke_' + this.attr('id'));
    var toolbarElt = this.$toolbarElt;
    if (!toolbarElt) return;
    var bound = this.getBoundingClientRect();
    var toolBound = toolbarElt.getBoundingClientRect();
    var outbound = Object(Dom["f" /* traceOutBoundingClientRect */])(this);
    var left = Math.max(0, bound.left);
    var top = bound.top - toolBound.height;
    if (outbound.top > bound.bottom ||
        outbound.bottom < bound.top) {
        top = -1000;
    }
    else if (bound.top < toolBound.height) {
        top = bound.bottom;
    }
    toolbarElt.addStyle({
        top: top + 'px',
        left: left + 'px'
    });
};


CKInlineShortText.property.removeToolbar = {
    set: function (value) {
        this._removeToolbar = !!value;
        if (this.$toolbarElt) {
            if (this._removeToolbar) {
                this.$toolbarElt.addClass('as-hidden');
            }
            else {
                this.$toolbarElt.removeClass('as-hidden');
            }
        }
    },
    get: function () {
        return this._removeToolbar;
    }
};


ACore["d" /* default */].install(CKInlineShortText);

/* harmony default export */ var ckeditor_CKInlineShortText = (CKInlineShortText);
// EXTERNAL MODULE: ./node_modules/absol-acomp/css/verticaltimeline.css
var verticaltimeline = __webpack_require__(311);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/VerticalTimeline.js





/***
 * @extends AElement
 * @constructor
 */
function VerticalTimeline() {
    this._current = 0;
    this._items = [];
    this.$items = [];
    this.current = 0;
}


VerticalTimeline.tag = 'VerticalTimeline'.toLowerCase();

VerticalTimeline.render = function () {
    return Object(ACore["c" /* _ */])({
        class: 'as-vertical-timeline',
        child: []
    });
};

VerticalTimeline.prototype._makeItem = function (item, i) {
    var iconElt = Object(ACore["c" /* _ */])('span.mdi.mdi-circle');
    return Object(ACore["c" /* _ */])({
        class: 'as-vertical-timeline-item',
        props: { $icon: iconElt },
        child: [
            {
                class: 'as-vertical-timeline-icon-ctn',
                child: iconElt
            },
            {
                class: 'as-vertical-timeline-tile',
                child: {
                    tag: 'span',
                    child: { text: item.text }
                }
            }
        ]
    });
};


VerticalTimeline.property = {};

VerticalTimeline.property.items = {
    /***
     * @this VerticalTimeline
     * @param items
     */
    set: function (items) {
        items = items || [];
        this._items = items;
        this.clearChild();
        this.$items = items.map(function (item, i) {
            return this._makeItem(item, i);
        }.bind(this));

        this.addChild(this.$items);
        this.current = this._current;//update
    },
    get: function () {

    }
};

VerticalTimeline.property.current = {
    set: function (value) {
        value = Object(utils["isRealNumber"])(value) ? (value >> 0) : -1;
        this._current = value;
        var itemElt;
        for (var i = 0; i < this.$items.length; ++i) {
            itemElt = this.$items[i];//.$icon.removeClass('');
            if (i < value) {
                itemElt.$icon.removeClass('mdi-numeric-' + (i + 1) + '-circle')
                    .removeClass('mdi-circle')
                    .addClass('mdi-check-circle');
                itemElt.removeClass('as-inactive').removeClass('as-active');

            }
            else if (i === value) {
                itemElt.$icon.addClass('mdi-numeric-' + (i + 1) + '-circle')
                    .removeClass('mdi-circle')
                    .removeClass('mdi-check-circle');
                itemElt.removeClass('as-inactive').addClass('as-active');
            }
            else {
                itemElt.addClass('as-inactive').removeClass('as-active');
                itemElt.$icon.removeClass('mdi-numeric-' + (i + 1) + '-circle')
                    .addClass('mdi-circle')
                    .removeClass('mdi-check-circle');
            }
        }


    },
    get: function () {
        return Math.max(-1, Math.min(this._current, this._items.length));
    }
};


ACore["d" /* default */].install(VerticalTimeline);
/* harmony default export */ var js_VerticalTimeline = (VerticalTimeline);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/dom/install.js




































































































































var publicCreators = [
    js_AutoCompleteInput,
    BoardTable["a" /* default */],
    Board["a" /* default */],
    js_BScroller,
    js_ButtonArray,
    js_ButtonRange,
    js_CalendarInput,
    OldCalendarInput,
    CheckBoxInput["a" /* default */],
    js_CheckBox,
    CheckboxButton["a" /* default */],
    js_CheckListItem,
    js_CheckListBox,
    js_CheckTreeLeafOnlyBox,
    ChromeCalendar["a" /* default */],
    js_ChromeTimePicker,
    js_ChromeTime24Picker,
    js_CircleSectionLabel,
    js_CountdownClock,
    js_CountdownText,
    DateInYearPicker["a" /* default */],
    DateInYearInput["a" /* default */],
    js_DateTimeInput,
    js_DropZone,
    js_EmojiPickerTooltip,
    js_FileInputBox,
    js_FileListItem,
    js_FileListInput,
    Scroller["c" /* Scrollbar */],
    Scroller["d" /* VScrollbar */],
    Scroller["a" /* HScrollbar */],
    Scroller["e" /* VScroller */],
    Scroller["b" /* HScroller */],
    ContextMenu["a" /* default */],
    Menu["c" /* HMenu */],
    Menu["g" /* VMenuItem */],
    Menu["f" /* VMenu */],
    Menu["b" /* Dropright */],
    Menu["h" /* VMenuLine */],
    Menu["a" /* Dropdown */],
    Menu["d" /* HMenuItem */],
    Menu["f" /* VMenu */],
    Menu["i" /* VRootMenu */],
    Menu["e" /* MenuButton */],
    js_DateInput2,
    Hanger["a" /* default */],
    js_DraggableHStack,
    js_DraggableVStack,
    js_DropPanel,
    js_DropPanelStack,
    js_EditableText,
    EmojiPicker["a" /* default */],
    js_EmojiCounter,
    js_EmojiCounterList,
    Sprite["a" /* default */],
    ExpTree["b" /* ExpNode */],
    ExpTree["c" /* default */],
    ExpTree["a" /* ExpGroup */],
    js_DVExpTree,
    js_FlexiconButton,
    js_FlexiconInput,
    Follower["a" /* default */],
    js_FollowerToggler,
    js_Frame,
    js_FrameView,
    js_TabFrame,
    TabView["a" /* default */],
    js_SinglePage,
    js_HexaSectionLabel,
    js_VRuler,
    js_HRuler,
    js_IconSprite,
    js_LinearColorBar,
    js_MediaInput,
    MessageInput["b" /* default */],
    MessageInput["a" /* MessageQuote */],
    js_Modal,
    js_LoadingCubeModal,
    js_NumberInput,
    js_NumberSpanInput,
    OnsScreenWindow["a" /* default */],
    OnScreenWidget["a" /* default */],
    js_PageIndicator,
    js_PageSelector,
    js_PreInput,
    js_ProgressBar,
    js_QuickListButton,
    QuickMenu["a" /* default */],
    js_QuickPath,
    Radio["a" /* default */],
    RadioButton["a" /* default */],
    js_RadioInput,
    js_RibbonSplitButton,
    js_RibbonButton,
    js_RotatedText,
    SelectList["a" /* default */],
    js_RemoteSvg,
    js_ResizeBox,
    Searcher["a" /* default */],
    SelectListBox["b" /* default */],
    js_SelectTreeBox,
    SelectMenu2["a" /* default */],
    SelectBox["a" /* default */],
    MultiSelectMenu["a" /* default */],
    js_MultiCheckTreeLeafBox,
    js_MultiCheckTreeLeafMenu,
    SelectBoxItem["a" /* default */],

    js_DualSelectBox,
    js_DualSelectMenu,

    js_SelectTable,
    js_SelectTable2,
    js_SelectTreeMenu,
    js_SelectTreeLeafBox,
    js_SelectTreeLeafMenu,
    js_SpanInput,
    Snackbar["a" /* default */],
    js_StaticTabbar,
    js_Switch,
    js_TableScroller,
    js_TableVScroller,
    js_TextArea2,
    js_TextClipboard,
    js_TimeInput,
    js_Time24Input,
    js_TimeRange24Input,
    js_TimeSelectInput,
    js_TimePicker,
    js_DateTimeInput,
    Tooltip["a" /* default */],
    Toast["a" /* default */],
    js_TreeList,
    js_TreeListItem,
    js_TokenField,
    WidthHeightSizer,
    js_TrackBar,
    js_TrackBarInput,
    SpinnerIco,
    VerticalTreeDiagramNode,
    js_VerticalTreeDiagram,
    js_MultiCheckMenu,
    js_CheckTreeItem,
    js_CheckTreeBox,
    js_MultiCheckTreeMenu,
    js_YesNoQuestionDialog,
    js_TOCItem,
    js_TOCList,
    ckeditor_CKPlaceholder,
    ckeditor_CKInlineShortText,
    js_VerticalTimeline
];

/***
 *
 * @param {Dom} core
 */
function install(core) {
    core.install(publicCreators);
    core.install('checkboxbutton', CheckBoxInput["a" /* default */]);
    core.install('selectbox', MultiSelectMenu["a" /* default */]);
}

/* harmony default export */ var dom_install = __webpack_exports__["a"] = (install);

/***/ }),
/* 65 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _AElementNS__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(56);

/* harmony default export */ __webpack_exports__["a"] = (_AElementNS__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"]);


/***/ }),
/* 66 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* unused harmony export LangSys */
/* unused harmony export textNodeLanguageChangeHandler */
/* unused harmony export elementLanguageChangeHandler */
/* harmony import */ var _ResizeSystem__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(11);
/* harmony import */ var _Code_safeThrow__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31);




/***
 * @typedef LanguageSystemExtension
 * @property {function(key: string, code?: string): (string | null)} getText
 */


/****
 *
 * @constructor
 */
function LanguageSystem() {
    this.data = {};
    this.code = navigator.language || navigator.userLanguage;
    /***
     *
     * @type {LanguageSystemExtension[]}
     * @private
     */
    this._extensions = [];
}

LanguageSystem.prototype.notifyLanguageChange = function () {
    var sizeChange = false;

    function visit(elt) {
        if (elt.onlanguagechange) {
            try {
                elt.onlanguagechange();
                sizeChange = true;
            } catch (err) {
                Object(_Code_safeThrow__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"])(err);
            }
            if (elt.childNodes && elt.childNodes.length > 0) {
                Array.prototype.forEach.call(elt.childNodes, visit);
            }
        }
    }

    visit(document.body);
    if (sizeChange) _ResizeSystem__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].update();
};


/***
 *
 * @param {ChildNode | Text | HTMLElement | Element} node
 */
LanguageSystem.prototype.bind = function (node, key) {
    if (node.nodeType === 1) {
        this.bindTextNode(node, key);
    }
    else if (node.nodeType === 3) {
        this.bindElement(node, key);
    }
};

/***
 *
 * @param {Text | {__as_language_key: string}} node
 * @param {string} key
 */
LanguageSystem.prototype.bindTextNode = function (node, key) {
    node.__as_language_key = key;
    node.onlanguagechange = textNodeLanguageChangeHandler;

};

/***
 *
 * @param {ChildNode | HTMLElement | Element | {__as_language_key: string}} node
 * @param {string} key
 */
LanguageSystem.prototype.bindElement = function (node, key) {
    node.__as_language_key = key;
    node.onlanguagechange = elementLanguageChangeHandler;
};

/***
 *
 * @param {string} key
 * @param {string} [code]
 */
LanguageSystem.prototype.getText = function (key, code) {
    var code = code || this.code;
    var res;
    var ex;
    for (var i = this._extensions.length - 1; i >= 0; --i) {
        ex = this._extensions[i];
        res = ex.getText && ex.getText.apply(ex, arguments);
        if (res) break;
    }
    if (!res) {
        res = this.data[code] && this.data[code][key];
    }
    return res || null;
};

/***
 *
 * @param {LanguageSystemExtension} ex
 */
LanguageSystem.prototype.addExtension = function (ex){
    this._extensions.push(ex);
};


var LangSys = new LanguageSystem();

function textNodeLanguageChangeHandler() {
    if (this.__as_language_key) {
        var newText = LangSys.getText(this.__as_language_key);
        if (newText && newText.trim) {
            this.data = newText;
        }
    }
}

function elementLanguageChangeHandler() {
    if (this.__as_language_key) {
        var newText = LangSys.getText(this.__as_language_key);
        if (newText && newText.trim) {
            var textNode;
            for (var i = 0; i < this.childNodes.length; ++i) {
                if (this.childNodes[i].nodeType === 1) {
                    textNode = this.childNodes[i];
                    break;
                }
            }
            if (!textNode) {
                textNode = document.createTextNode('');
            }
            textNode.data = newText;
        }
    }
}

/* harmony default export */ __webpack_exports__["a"] = (LangSys);

/***/ }),
/* 67 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_searcher_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(202);
/* harmony import */ var _css_searcher_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_searcher_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2);
/* harmony import */ var absol_src_HTML5_AElement__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(8);





var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;


_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].creator['find-ico'] = function () {
    var res = _(
        '<svg class="find" width="100mm" height="100mm" version="1.1" viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg">' +
        ' <g transform="matrix(-1 0 0 1 99.478 -193.73)">' +
        '  <path d="m62.128 199.18c-18.859 0-34.148 15.289-34.148 34.148 0 5.4138 1.26 10.533 3.5026 15.081 0.6886 1.3965 1.4698 2.7392 2.3357 4.02-1.9962 2.1685-31.467 31.596-31.404 33.295 0.21757 5.8346 4.9404 8.7289 9.464 7.855 1.3264-0.25627 30.938-30.639 31.774-31.529 1.3906 0.89633 2.8508 1.6948 4.3702 2.3848 4.2995 1.9526 9.0756 3.04 14.105 3.04 18.859 0 34.147-15.288 34.147-34.147 3e-6 -18.859-15.288-34.148-34.147-34.148zm0.49444 8.2454a26.067 26.067 0 0 1 26.068 26.067 26.067 26.067 0 0 1-26.068 26.068 26.067 26.067 0 0 1-26.067-26.068 26.067 26.067 0 0 1 26.067-26.067z"/>' +
        ' </g>' +
        '</svg>'
    );
    return res;
};


_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].creator['times-circle-ico'] = function () {
    var res = _(
        '<svg class="times" width="100mm" height="100mm" version="1.1" viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg">\
            <g transform="translate(0,-197)">\
                <path d="m49.979 236.2-14.231-14.231-10.696 10.696 14.257 14.257-14.351 14.351 10.737 10.737 14.292-14.292 14.292 14.292 10.761-10.761-14.257-14.257 14.316-14.316-10.725-10.725zm50.021 10.804a50 50 0 0 1-50 50 50 50 0 0 1-50-50 50 50 0 0 1 50-50 50 50 0 0 1 50 50z" />\
            </g>\
        </svg>'
    );
    return res;
};


/**
 * @extends {AElement}
 * @constructor
 */
function SearchTextInput() {
    var thisSTI = this;
    this.defineEvent(['change', 'modify', 'stoptyping']);

    this.eventHandler = absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].bindFunctions(this, SearchTextInput.eventHandler);
    this.$button = $('button', this);
    this.$input = $('input', this);

    ['keyup', 'keydown', 'focus', 'blur'].forEach(function (evName){
        thisSTI.defineEvent(evName);
        thisSTI.$input.on(evName, function (event){
            thisSTI.emit(evName, event, thisSTI);
        });
    });

    this.$input.on('change', this.eventHandler.inputChange);
    this.$input.on('keyup', this.eventHandler.inputKeyUp);

    this.$button.on('click', function (event) {
        thisSTI.$input.value = '';
        thisSTI.eventHandler.inputKeyUp(event);
        setTimeout(function () {
            thisSTI.focus();
        }, 50);
    });
}

SearchTextInput.tag = 'SearchTextInput'.toLowerCase();

SearchTextInput.render = function () {
    return _(
        {
            class: 'absol-search-text-input',
            child: [
                {
                    class: 'absol-search-text-input-container',
                    child: {
                        tag: 'input',
                        attr: {
                            type: 'search',
                            placeholder: 'search...'
                        }
                    }
                },
                {
                    class: 'absol-search-text-button-container',
                    child: {
                        tag: 'button',
                        child: ['find-ico', 'times-circle-ico']
                    }
                }
            ]
        }
    );
};


SearchTextInput.property = {
    value: {
        set: function (value) {
            value = value || '';
            this.$input.value = value;
            this._lastTextModified = value;
            if (this.value.length > 0) {
                this.addClass('searching');
            }
            else {
                this.removeClass('searching');
            }
        },
        get: function () {
            return this.$input.value;
        }
    },
    placeholder: {
        set: function (value) {
            this.$input.attr('placeholder', value);
        },
        get: function () {
            return this.$placeholder.getAttribute('placeholder');
        }
    }
};

SearchTextInput.prototype.focus = function () {
    this.$input.focus();
};

SearchTextInput.prototype.blur = function () {
    this.$input.blur();
};


SearchTextInput.eventHandler = {};
SearchTextInput.eventHandler.inputChange = function (event) {
    event.value = this.value;
    if (typeof this.onchange == 'function') {
        this.onchange(event, this);
    }
    this.emit('change', event);
};

SearchTextInput.eventHandler.inputKeyUp = function (event) {
    if (this._lastTextModified != this.value) {
        if (this.value.length > 0) {
            this.addClass('searching');
        }
        else {
            this.removeClass('searching');
        }
        event.value = this.value;
        if (typeof this.onchange == 'function') {
            this.onchange(event, this);
        }
        this.emit('modify', event);
        if (this._updateTimeOut !== undefined) {
            clearTimeout(this._updateTimeOut);
            this._updateTimeOut = undefined;
        }
        this._updateTimeOut = setTimeout(function () {
            this.emit('stoptyping', event);
        }.bind(this), 500);
        this._lastTextModified = this.value;
    }
};


_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].creator.searchcrosstextinput = function () {
    var res = _('searchtextinput', true);
    return res;
};

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].creator.searchtextinput = SearchTextInput;

/* harmony default export */ __webpack_exports__["a"] = (SearchTextInput);

/***/ }),
/* 68 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return requireItem; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return releaseItem; });
/* harmony import */ var _css_selectbox_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(204);
/* harmony import */ var _css_selectbox_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_selectbox_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var _SelectMenu2__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(21);
/* harmony import */ var absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(3);
/* harmony import */ var _PositionTracker__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(50);
/* harmony import */ var _SelectBoxItem__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(42);
/* harmony import */ var _SelectListBox__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(19);
/* harmony import */ var absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(2);
/* harmony import */ var absol_src_HTML5_ResizeSystem__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(11);











var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;


function pressCloseEventHandler(event) {
    var parentElt = this.$parent;
    if (!parentElt) return;
    parentElt.eventHandler.pressCloseItem(this, event);
}

function pressHandler(event) {
    var parentElt = this.$parent;
    if (!parentElt) return;
    parentElt.eventHandler.pressItem(this, event);
}

/***
 *
 * @returns {SelectBoxItem}
 */
function makeItem() {
    return _({
        tag: 'selectboxitem',
        on: {
            close: pressCloseEventHandler,
            press: pressHandler
        }
    });
}

var itemPool = [];

function requireItem($parent) {
    var item;
    if (itemPool.length > 0) {
        item = itemPool.pop();
    } else {
        item = makeItem();
    }
    item.$parent = $parent;
    return item;
}

function releaseItem(item) {
    item.$parent = null;
    itemPool.push(item);
}


/***
 * @extends PositionTracker
 * @return {SelectBox}
 * @constructor
 */
function SelectBox() {
    this.on('click', this.eventHandler.click);
    this.$selectlistBox = _({
        tag: 'selectlistbox',
        props: {
            anchor: [1, 6, 2, 5],
            displayValue: _SelectListBox__WEBPACK_IMPORTED_MODULE_6__[/* VALUE_HIDDEN */ "a"]
        },
        on: {
            preupdateposition: this.eventHandler.preUpdateListPosition,
            pressitem: this.eventHandler.selectListBoxPressItem
        }
    });
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_7__[/* default */ "a"].drillProperty(this, this.$selectlistBox, 'enableSearch');
    this.$items = [];
    this._values = [];
    this.items = [];
    this.values = [];
    this.$selectlistBox.followTarget = this;
    this.disableClickToFocus = false;
    this.orderly = true;
    this.itemFocusable = false;
    this._activeValue = undefined;
    return this;
}

SelectBox.tag = 'selectbox';
SelectBox.render = function () {
    return _({
        tag: 'bscroller',
        class: ['absol-selectbox', 'absol-bscroller'],
        extendEvent: ['change', 'add', 'remove', 'activevaluechange'],
        attr: {
            tabindex: '1'
        }
    }, true);
};


SelectBox.prototype._requireItem = function (n) {
    var itemElt;
    while (this.$items.length < n) {
        itemElt = requireItem(this);
        this.addChild(itemElt);
        this.$items.push(itemElt);
    }

    while (this.$items.length > n) {
        itemElt = this.$items.pop();
        this.removeChild(itemElt);
        releaseItem(itemElt);
    }
};


SelectBox.prototype._assignItems = function (items) {
    for (var i = 0; i < this.$items.length && i < items.length; ++i) {
        this.$items[i].data = items[i];
    }
};

/***
 *
 * @param {string[] | number[]} values
 * @private
 */
SelectBox.prototype._getItemsByValues = function (values) {
    var selectListBoxElt = this.$selectlistBox;
    var itemHolders = values.reduce(function (ac, cr) {
        ac.push.apply(ac, selectListBoxElt.findItemsByValue(cr));
        return ac;
    }, []);
    if (this.orderly) {
        itemHolders.sort(function (a, b) {
            return a.idx - b.idx;
        });
    }

    return itemHolders.map(function (holder) {
        return holder.item;
    })

};


SelectBox.prototype._updateItems = function () {
    this.viewItemsByValues(this._values);
};

SelectBox.prototype.viewItemsByValues = function (values) {
    var items = this._getItemsByValues(values);
    var cBound = this.getBoundingClientRect();
    this._requireItem(items.length);
    this._assignItems(items);
    if (this.itemFocusable) {
        this._updateFocusItem();
    }
    var nBound = this.getBoundingClientRect();
    if (nBound.width != cBound.width || nBound.height != cBound.height) {
        absol_src_HTML5_ResizeSystem__WEBPACK_IMPORTED_MODULE_8__[/* default */ "a"].updateUp(this);
    }
};


SelectBox.property = {};
SelectBox.property.disabled = _SelectMenu2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].property.disabled;
SelectBox.property.hidden = _SelectMenu2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].property.hidden;
SelectBox.property.isFocus = _SelectMenu2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].property.isFocus;


SelectBox.prototype.init = function (props) {
    props = props || [];
    Object.keys(props).forEach(function (key) {
        if (props[key] === undefined) delete props[key];
    });
    this.super(props);
};

SelectBox.prototype._updateFocusItem = function () {
    for (var i = 0; i < this.$items.length; ++i) {
        this.$items[i].active = this.$items[i].value == this._activeValue;
    }
};


SelectBox.prototype.init = _SelectMenu2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].prototype.init;


SelectBox.property.items = {
    set: function (items) {
        items = items || [];
        this.$selectlistBox.items = items;
        this.addStyle('--list-min-width', this.$selectlistBox._estimateWidth + 'px');
        this._updateItems();
    },
    get: function () {
        return this.$selectlistBox.items
    }
};

SelectBox.property.values = {
    set: function (values) {
        values = values || [];
        values = (values instanceof Array) ? values : [values];
        this._values = values;
        this.$selectlistBox.values = values;
        this._updateItems();
    },
    get: function () {
        return this._values || [];
    }
};

SelectBox.property.orderly = {
    set: function (value) {
        var needUpdate = this._orderly === this._orderly;
        if (typeof value === 'function') {
            this._orderly;
        } else
            this._orderly = !!value;
        if (needUpdate) {
            this.values = this.values;
        }
    },
    get: function () {
        return !!this._orderly;
    }
};

SelectBox.property.disableClickToFocus = {
    set: function (value) {
        if (value) {
            this.addClass('as-disable-click-to-focus');
        } else {
            this.removeClass('as-disable-click-to-focus');
        }
    },
    get: function () {
        return this.containsClass('as-disable-click-to-focus');
    }
};

SelectBox.property.itemFocusable = {
    set: function (value) {
        if (value) {
            this.addClass('as-item-focusable');
        } else {
            this.removeClass('as-item-focusable');
        }
        this._updateFocusItem();
    },
    get: function () {
        return this.containsClass('as-item-focusable');
    }
};

SelectBox.property.activeValue = {
    set: function (value) {
        this._activeValue = value;
        if (this.itemFocusable) {
            this._updateFocusItem();
            //todo
        }
    },
    get: function () {
        return this._activeValue;
    }
};


SelectBox.eventHandler = Object.assign({}, _SelectMenu2__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].eventHandler);


SelectBox.eventHandler.click = function (event) {
    if (event.target === this && !this.disableClickToFocus) {
        this.isFocus = !this.isFocus;
    }
};


SelectBox.eventHandler.bodyClick = function (event) {
    if (!absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_3__[/* default */ "b"].hitElement(this.$selectlistBox, event) && event.target !== this) {
        this.isFocus = false;
    }
};


SelectBox.eventHandler.selectListBoxPressItem = function (event) {
    var data = event.data;
    var currentValues = this.$selectlistBox.values;
    currentValues.push(data.value);
    this.$selectlistBox.values = currentValues;
    this.$selectlistBox.updatePosition();
    this._activeValue = data.value;
    this._updateItems();
    this.isFocus = false;
    this.emit('add', Object.assign({}, event, {
        type: 'add',
        target: this,
        value: data.value,
        data: data,
        itemData: data
    }), this);
    this.emit('change', Object.assign({}, event, {
        type: 'change',
        action: 'add',
        target: this,
        value: data.value,
        data: data,
        values: this.values
    }), this);
};

SelectBox.eventHandler.pressCloseItem = function (item, event) {
    var value = item.value;
    var data = item.data;
    var currentValues = this.$selectlistBox.values;
    var index = currentValues.indexOf(value);
    if (index >= 0) {
        currentValues.splice(index, 1);
    }
    this.$selectlistBox.values = currentValues;
    this.$selectlistBox.updatePosition();
    this._values = currentValues;
    this._updateItems();
    this.emit('remove', Object.assign({}, event, {
        type: 'change',
        target: this,
        data: data,
        value: value,
        itemData: data
    }), this);
    this.emit('change', Object.assign({}, event, {
        type: 'change',
        action: 'remove',
        target: this,
        data: data,
        value: value,
        itemData: data
    }), this);
};

SelectBox.eventHandler.pressItem = function (item, event) {
    var value = item.value;
    if (this.itemFocusable) {
        var prevActiveValue = this.activeValue;
        if (value !== prevActiveValue) {

            this.activeValue = value;
            this.emit('activevaluechange', {
                target: this,
                originEvent: event,
                prevActiveValue: prevActiveValue,
                activeValue: value
            }, this);
        }
    }
};


SelectBox.eventHandler.pressCloseItem = function (item, event) {
    var value = item.value;
    var data = item.data;
    var index;
    index = this._values.indexOf(value);
    if (index >= 0) {
        this._values.splice(index, 1);
        this._updateItems();
        this.$selectlistBox.values = this._values;
        this.emit('remove', Object.assign({}, event, {
            type: 'change',
            target: this,
            data: data,
            value: value,
            itemData: data
        }), this);
        this.emit('change', Object.assign({}, event, {
            type: 'change',
            action: 'remove',
            target: this,
            data: data,
            value: value,
            itemData: data
        }), this);
    }
};

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(SelectBox);

/* harmony default export */ __webpack_exports__["a"] = (SelectBox);

/***/ }),
/* 69 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global) {/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1);



var _ = _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].$;

var originSetTimeout = setTimeout;
var originClearTimeout = clearTimeout;
var originSetInterval = setInterval;
var originClearInterval = clearInterval;
var pendingTimeout = 0;
var pendingInterval = 0;
var timeoutDict = {};
var intervalDict = {};

function DebugTask() {
    var res = _({
        class: 'absol-debug-task',
        child: [
            {
                child: [{
                    tag: 'span',
                    class: 'absol-debug-task-name',
                    child: { text: 'settimeout ' }
                },
                {
                    tag: 'span',
                    class: ['absol-debug-task-value', 'settimeout'],

                    child: { text: '0' }
                }]
            },
            {
                child: [{
                    tag: 'span',
                    class: 'absol-debug-task-name',
                    child: { text: 'setintervel ' }
                },
                {
                    tag: 'span',
                    class: ['absol-debug-task-value', 'setinterval'],
                    child: { text: '0' }
                },
                ]
            },
            {
                child: [{
                    tag: 'span',
                    class: 'absol-debug-task-name',
                    child: { text: 'Work ' }
                },
                {
                    tag: 'span',
                    class: ['absol-debug-task-value', 'work'],
                    child: { text: '0%' }
                },
                ]
            }
        ]
    });
    res._timeout = 0;
    res._interval = 0;
    res._work = 0;
    res.$setTimeOutValue = $('.absol-debug-task-value.settimeout', res);
    res.$setIntervalValue = $('.absol-debug-task-value.setinterval', res);
    res.$setWorkValue = $('.absol-debug-task-value.work', res);
    return res;
}

DebugTask.property = {};

DebugTask.property.timeout = {
    set: function (value) {
        this._timeout = value;
        this.$setTimeOutValue.innerHTML = value + '';
    },
    get: function () {
        return this._timeout;
    }
};

DebugTask.property.interval = {
    set: function (value) {
        this._interval = value;
        this.$setIntervalValue.innerHTML = value + '';
    },
    get: function () {
        return this._interval;
    }
};

DebugTask.property.work = {
    set: function (value) {
        this._work = value;
        value = (value * 100).toFixed(1);
        this.$setWorkValue.innerHTML = value + '%';
    },
    get: function () {
        return this._work;
    }
};


DebugTask.start = function () {
    if (DebugTask.started) return;
    if (!DebugTask.$view) {
        DebugTask.$view = _('debugtask');
    }

    var times = [];
    originSetInterval(function(){
        var now = performance.now();
        while (times.length > 0 && times[0].end < now - 2000) {
            times.shift();
        }
        if (times.length == 0)  DebugTask.$view.work = 0;
    },3000);
    global.setTimeout = function () {
        var args = Array.prototype.map.call(arguments, function (x) { return x; });
        var originCallback = arguments[0];
        if (typeof originCallback == 'undefined') return;
        if (typeof originCallback == 'string') {
            originCallback = new Function(originCallback);
        }
        args[0] = function () {
            var ret;
            try {
                var now = performance.now();
                while (times.length > 0 && times[0].end < now - 1000) {
                    times.shift();
                }
                ret = originCallback.apply(null, arguments);
                var now1 = performance.now();
                var long = now1 - now;
                times.push({
                    long:long,
                    start:now,
                    end:now1
                });
                var sTime = 0;
                for (var i = 0; i< times.length; ++i ){
                    sTime+= times[i].long;
                }
                DebugTask.$view.work = sTime/(Math.max(now1 - times[0].start, 1000));

            }
            catch (e) {
                console.error(e);
            }
            if (timeoutDict[timeoutId]) {
                pendingTimeout--;
                delete timeoutDict[timeoutId];
                DebugTask.$view.timeout = pendingTimeout;
            }
            return ret;
        }
        var timeoutId = originSetTimeout.apply(global, args)
        pendingTimeout++;
        timeoutDict[timeoutId] = true;

        DebugTask.$view.timeout = pendingTimeout;

        return timeoutId;
    }

    global.clearTimeout = function (timeoutId) {
        if (timeoutDict[timeoutId]) {
            pendingTimeout--;
            delete timeoutDict[timeoutId];
            DebugTask.$view.timeout = pendingTimeout;
        }
        return originClearTimeout.apply(global, arguments);

    };


    global.setInterval = function () {
        var args = Array.prototype.map.call(arguments, function (x) { return x; });
        var originCallback = arguments[0];
        if (typeof originCallback == 'undefined') return;
        if (typeof originCallback == 'string') {
            originCallback = new Function(originCallback);
        }
        args[0] = function () {
            var ret;
            try {
                var now = performance.now();
                while (times.length > 0 && times[0].end < now - 1000) {
                    times.shift();
                }
                ret = originCallback.apply(null, arguments);
                var now1 = performance.now();
                var long = now1 - now;
                times.push({
                    long:long,
                    start:now,
                    end:now1
                });
                var sTime = 0;
                for (var i = 0; i< times.length; ++i ){
                    sTime+= times[i].long;
                }
                DebugTask.$view.work = sTime/(Math.max(now1 - times[0].start, 1000));
            }
            catch (e) {
                console.error(e);
            }
            return ret;
        }
        var intervalId = originSetInterval.apply(global, args)
        pendingInterval++;
        intervalDict[intervalId] = true;

        DebugTask.$view.interval = pendingInterval;

        return intervalId;
    }

    global.clearInterval = function (intervalId) {
        var args = Array.prototype.map.call(arguments, function (x) { return x; });
        if (intervalDict[intervalId]) {
            pendingInterval--;
            delete intervalDict[intervalId];
            DebugTask.$view.interval = pendingInterval;
        }
        return originClearInterval.apply(global, args);

    };

    absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_1__[/* default */ "b"].documentReady.then(function () {
        DebugTask.$view.addTo(document.body);
    });
};

_ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].install('debugtask', DebugTask);



/* harmony default export */ __webpack_exports__["a"] = (DebugTask);


/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(44)))

/***/ }),
/* 70 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";

// EXTERNAL MODULE: ./node_modules/absol/src/JSMaker/TemplateString.js
var TemplateString = __webpack_require__(26);

// CONCATENATED MODULE: ./node_modules/absol/src/JSDocx/templates/document.tpl
/* harmony default export */ var templates_document = ("<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?>\n<w:document\n  xmlns:w=\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\"\n  xmlns:m=\"http://schemas.openxmlformats.org/officeDocument/2006/math\"\n  xmlns:r=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships\"\n  xmlns:wp=\"http://schemas.openxmlformats.org/drawingml/2006/wordprocessingDrawing\"\n  xmlns:a=\"http://schemas.openxmlformats.org/drawingml/2006/main\"\n  xmlns:ns6=\"http://schemas.openxmlformats.org/schemaLibrary/2006/main\"\n  xmlns:c=\"http://schemas.openxmlformats.org/drawingml/2006/chart\"\n  xmlns:ns8=\"http://schemas.openxmlformats.org/drawingml/2006/chartDrawing\"\n  xmlns:dgm=\"http://schemas.openxmlformats.org/drawingml/2006/diagram\"\n  xmlns:pic=\"http://schemas.openxmlformats.org/drawingml/2006/picture\"\n  xmlns:ns11=\"http://schemas.openxmlformats.org/drawingml/2006/spreadsheetDrawing\"\n  xmlns:dsp=\"http://schemas.microsoft.com/office/drawing/2008/diagram\"\n  xmlns:ns13=\"urn:schemas-microsoft-com:office:excel\"\n  xmlns:o=\"urn:schemas-microsoft-com:office:office\"\n  xmlns:v=\"urn:schemas-microsoft-com:vml\"\n  xmlns:w10=\"urn:schemas-microsoft-com:office:word\"\n  xmlns:ns17=\"urn:schemas-microsoft-com:office:powerpoint\"\n  xmlns:odx=\"http://opendope.org/xpaths\"\n  xmlns:odc=\"http://opendope.org/conditions\"\n  xmlns:odq=\"http://opendope.org/questions\"\n  xmlns:odi=\"http://opendope.org/components\"\n  xmlns:odgm=\"http://opendope.org/SmartArt/DataHierarchy\"\n  xmlns:ns24=\"http://schemas.openxmlformats.org/officeDocument/2006/bibliography\"\n  xmlns:ns25=\"http://schemas.openxmlformats.org/drawingml/2006/compatibility\"\n  xmlns:ns26=\"http://schemas.openxmlformats.org/drawingml/2006/lockedCanvas\">\n  <w:body>\n    <w:altChunk r:id=\"htmlChunk\" />\n    <w:sectPr>\n      <w:pgSz w:w=\"{{ pageSetting.width }}\" w:h=\"{{ pageSetting.height }}\" w:orient=\"{{ pageSetting.orient }}\" />\n      <w:pgMar w:top=\"{{ pageSetting.margins.top }}\"\n               w:right=\"{{ pageSetting.margins.right }}\"\n               w:bottom=\"{{ pageSetting.margins.bottom }}\"\n               w:left=\"{{ pageSetting.margins.left }}\"\n               w:header=\"{{ pageSetting.margins.header }}\"\n               w:footer=\"{{ pageSetting.margins.footer }}\"\n               w:gutter=\"{{ pageSetting.margins.gutter }}\"/>\n    </w:sectPr>\n  </w:body>\n</w:document>\n");
// CONCATENATED MODULE: ./node_modules/absol/src/JSDocx/templates/mht_document.tpl
/* harmony default export */ var mht_document = ("MIME-Version: 1.0\nContent-Type: multipart/related;\n    type=\"text/html\";\n    boundary=\"----=mhtDocumentPart\"\n\n\n------=mhtDocumentPart\nContent-Type: text/html;\n    charset=\"utf-8\"\nContent-Transfer-Encoding: quoted-printable\nContent-Location: file:///C:/fake/document.html\n\n{{ htmlSource }}\n\n{{ contentParts }}\n\n------=mhtDocumentPart--\n");
// CONCATENATED MODULE: ./node_modules/absol/src/JSDocx/templates/mht_part.tpl
/* harmony default export */ var mht_part = ("------=mhtDocumentPart\nContent-Type: {{ contentType }}\nContent-Transfer-Encoding: {{ contentEncoding }}\nContent-Location: {{ contentLocation }}\n\n{{ encodedContent }}\n");
// CONCATENATED MODULE: ./node_modules/absol/src/JSDocx/DocxTpl.js




/* harmony default export */ var DocxTpl = __webpack_exports__["a"] = ({
    document: new Function('pageSetting', 'return ' + TemplateString["a" /* default */].parse(templates_document).toJSCode()),
    mht_document: new Function('htmlSource', 'contentParts', 'return ' + TemplateString["a" /* default */].parse(mht_document).toJSCode()),
    mht_part: new Function('contentType', 'contentEncoding', 'contentLocation', 'encodedContent', 'return ' + TemplateString["a" /* default */].parse(mht_part).toJSCode())
});

/***/ }),
/* 71 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* unused harmony export EFFECT_ZONE_CLASS_NAME */
/* unused harmony export DRAG_ZONE_CLASS_NAME */
/* unused harmony export FREE_ZONE_CLASS_NAME */
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
/* harmony import */ var _css_boardtable_css__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(88);
/* harmony import */ var _css_boardtable_css__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_css_boardtable_css__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _Board__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(85);
/* harmony import */ var absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(9);
/* harmony import */ var absol_src_HTML5_Element__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(24);
/* harmony import */ var absol_src_Math_Rectangle__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(18);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(1);
/* harmony import */ var absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(3);
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(4);
/* harmony import */ var _Hanger__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(29);












var _ = _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].$;


/***
 * @extends AElement
 * @constructor
 */
function BoardTable() {
    var events = {
        touchstart: this.eventHandler.mousedown,
        mousedown: this.eventHandler.mousedown
    };
    _Hanger__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].prototype.on2.call(this, events);
    this._childHolders = [];
    this._dragEventData = null;
    this._friends = [];
    this._longPressEventData = null;
}

BoardTable.tag = 'boardtable';
BoardTable.render = function () {
    return _({
        class: 'as-board-table',
        extendEvent: ['sizechange', 'orderchange', 'itemleave', 'itementer', 'dragitemstart', 'dragitemend']
    });
};

var EFFECT_ZONE_CLASS_NAME = 'as-board-table-effect-zone';
var DRAG_ZONE_CLASS_NAME = 'as-board-drag-zone';
var FREE_ZONE_CLASS_NAME = 'as-board-free-zone';

BoardTable.EFFECT_ZONE_CLASS_NAME = EFFECT_ZONE_CLASS_NAME;
BoardTable.DRAG_ZONE_CLASS_NAME = DRAG_ZONE_CLASS_NAME;
BoardTable.FREE_ZONE_CLASS_NAME = FREE_ZONE_CLASS_NAME;

BoardTable.prototype.$preventContext = _({
    tag: 'textarea',
    class: 'as-board-table-prevent-context',
    props: { readOnly: true }
});

BoardTable.prototype.maxScrollSpeed = 300;


BoardTable.prototype.findDomChildBefore = function (elt) {
    var nodes = this.childNodes;
    for (var i = 0; i < nodes.length; ++i) {
        if (nodes[i] == elt) return nodes[i - 1];
    }
    return null;
};


BoardTable.prototype.findDomChildAfter = function (elt) {
    var nodes = this.childNodes;
    for (var i = 0; i < nodes.length; ++i) {
        if (nodes[i] == elt) return nodes[i + 1];
    }
    return null;
};


BoardTable.prototype.addChild = function (elt) {
    if (elt.classList.contains('as-board')) {
        elt.selfRemove();
        var atElt;
        if (this._childHolders.length > 0) {
            atElt = this.findDomChildAfter(this._childHolders[this._childHolders.length - 1].elt);
            if (atElt) {
                if (atElt != -1)
                    this.insertBefore(elt, atElt);
                else
                    throw new Error("Violation data!");
            }
            else {
                this.appendChild(elt);
            }
        }
        else {
            this.appendChild(elt);
        }
        var holder = {
            elt: elt,
        };
        elt.on('sizechange', holder.onsizechange);
        this._childHolders.push(holder);
    }
    else {
        this.appendChild(elt);
    }
    return this;
};


BoardTable.prototype.removeChild = function (elt) {
    var holderIndex = this.findChildHolderIndex(elt);
    if (holderIndex >= 0) {
        var holder = this._childHolders[holderIndex];
        holder.elt.off('sizechange', holder.onsizechange);
        this._childHolders.splice(holderIndex, 1);
        holder.elt.remove();
    }
    else {
        this.super(elt);
    }
};

BoardTable.prototype.findChildBefore = function (elt) {
    var holderIndex = this.findChildHolderIndex(elt);
    if (holderIndex < 0) return holderIndex;
    if (holderIndex < 1) return null;
    return this._childHolders[holderIndex - 1];
};


BoardTable.prototype.findChildAfter = function (elt) {
    var holderIndex = this.findChildHolderIndex(elt);
    if (holderIndex < 0) return holderIndex;
    if (holderIndex <= this._childHolders.length) return null;
    return this._childHolders[holderIndex + 1];
};

BoardTable.prototype.addChildBefore = function (elt, at) {
    elt.selfRemove();
    var atIndex = this.findChildHolderIndex(at);
    if (elt.classList.contains('as-board')) {
        if (atIndex < 0) {
            if (this._childHolders.length > 0) {
                if (this.findDomChildAfter(this._childHolders[this._childHolders.length - 1].elt) == at) {
                    atIndex = this._childHolders.length;
                }
                else {
                    throw new Error("Invalid position, you must insert board next to other board!");
                }
            }
        }

        this.insertBefore(elt, at);
        var holder = {
            elt: elt
        };
        this._childHolders.splice(atIndex, 0, holder);
    }
    else {
        if (atIndex > 0) {
            throw new Error("Invalid position, you can not insert othert type between two board!");
        }
        else {
            this.insertBefore(elt, at);
        }
    }
    return this;
};

BoardTable.prototype.addChildAfter = function (elt, at) {
    elt.selfRemove();
    var atIndex = this.findChildHolderIndex(at);
    var afterAt = this.findDomChildAfter(at);
    if (elt.classList.contains('as-board')) {
        if (atIndex < 0) {
            if (this._childHolders.length > 0) {
                if (this.findDomChildBefore(this._childHolders[0].elt) == at) {
                    atIndex = -1;
                }
                else
                    throw new Error("Invalid position,  you must insert board next to other board!");
            }
        }

        var holder = {
            elt: elt
        };
        if (!afterAt) {
            this.appendChild(elt);
        }
        else {
            this.insertBefore(elt, afterAt);
        }
        this._childHolders.splice(atIndex + 1, 0, holder);
    }
    else {
        if (this._childHolders.length > 1 && atIndex >= 0 && atIndex + 1 < this._childHolders.length) {
            throw new Error("Invalid position, you can not insert othert type between two board!");
        }
        else {
            if (!afterAt) {
                this.appendChild(elt);
            }
            else {
                this.insertBefore(elt, afterAt);
            }

        }
    }
    return this;
};

BoardTable.prototype.clearChild = function () {
    this._childHolders = [];
    return absol_src_HTML5_Element__WEBPACK_IMPORTED_MODULE_4__[/* default */ "a"].prototype.clearChild.call(this);
};


BoardTable.prototype.findChildHolder = function (elt) {
    return this._childHolders[this.findChildHolderIndex(elt)];
};


BoardTable.prototype.findChildHolderIndex = function (elt) {
    for (var i = 0; i < this._childHolders.length; ++i) {
        if (this._childHolders[i].elt == elt) return i;
    }
    return -1;
};


BoardTable.prototype.getEffectZone = function () {
    var ez = this;
    while (ez) {
        if (ez.classList.contains(EFFECT_ZONE_CLASS_NAME)) {
            return ez;
        }
        ez = ez.parentElement;
    }
    return this;
};

BoardTable.prototype._findDragZone = function (elt) {
    var res = null;
    while (elt != this && elt) {
        if (elt.classList.contains('as-board-table')) return null;//maybe in other
        if (!res && elt.classList.contains(DRAG_ZONE_CLASS_NAME)) {
            res = elt;
        }
        if (!res && elt.classList.contains(FREE_ZONE_CLASS_NAME)) return null;// do not drag
        elt = elt.parentElement;
    }
    return res;
};

BoardTable.prototype._findBoard = function (elt) {
    while (elt != this && elt) {
        if (elt.classList.contains('as-board')) return elt;
        elt = elt.parentElement;
    }
    return null;
};


BoardTable.prototype.getAllFriends = function () {
    var thisBT = this;
    var res = [];
    var friendQR;
    for (var i = 0; i < this._friends.length; ++i) {
        friendQR = this._friends[i];
        if (friendQR != this && friendQR && friendQR.classList && friendQR.classList.contains('as-board-table')) {
            res.push(friendQR);
        }
        else if (typeof friendQR == 'string') {// query
            $(friendQR, false, function (elt) {
                if (thisBT != elt && elt.classList && elt.classList.contains('as-board-table')) {
                    res.push(elt);
                }
                return false;
            });
        }
    }

    return res;
};


BoardTable.prototype._findHoverBoardIndex = function (clientX, clientY, excludes) {
    var cli = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"](clientX, clientY);
    var bound;
    for (var i = 0; i < this._childHolders.length; ++i) {
        // holder =
        if (excludes && excludes.indexOf(this._childHolders[i].elt) >= 0) continue;
        bound = absol_src_Math_Rectangle__WEBPACK_IMPORTED_MODULE_5__[/* default */ "a"].fromClientRect(this._childHolders[i].elt.getBoundingClientRect());
        if (bound.containsPoint(cli)) return i;
    }
    return -1;
};


/**
 * @type {BoardTable}
 */
BoardTable.eventHandler = {};


BoardTable.eventHandler.mousedown = function (event) {
    if (this._dragEventData) return;
    var mousePos;
    var pointerIdent = -1;
    var target;
    var isTouch = event.type === 'touchstart';
    if (isTouch) {
        var touch = event.changedTouches[0];
        target = touch.target;
        pointerIdent = touch.identifier;
        mousePos = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"](touch.clientX, touch.clientY);
    }
    else {
        mousePos = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"](event.clientX, event.clientY);
        target = event.target;
    }


    var dragzone = this._findDragZone(target);
    if (dragzone) {
        var boardElt = this._findBoard(dragzone);
        var holderIndex = this.findChildHolderIndex(boardElt);
        if (holderIndex < 0) return;// can not move
        var cBound = boardElt.getBoundingClientRect();
        var mouseBoardOffset = mousePos.sub(new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"](cBound.left, cBound.top));
        this._dragEventData = {
            boardElt: boardElt,
            state: 'WAIT',
            mouseStartPos: mousePos,
            mousePos: mousePos,
            mouseBoardOffset: mouseBoardOffset,
            holderIndex: holderIndex,
            boardBound: cBound,
            isTouch: isTouch,
            pointerIdent: pointerIdent
        };
        var cEvent = absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_7__[/* default */ "b"].copyEvent(event);

        if (isTouch) {
            _Hanger__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].prototype.on2.call(document.body, {
                touchend: this.eventHandler.touchFinishBeforeReadyDrag,
                touchcancel: this.eventHandler.touchFinishBeforeReadyDrag,
                touchmove: this.eventHandler.touchMoveBeforeReadyDrag
            });
            this.$preventContext.off('contextmenu', this.eventHandler.contextMenu);//event maybe not remove because of double click
            this.$preventContext.on('contextmenu', this.eventHandler.contextMenu);
            var thisBT = this;

            this._dragEventData._longPressTimeout = setTimeout(function () {
                thisBT._longPressEventData = -1;
                thisBT.$preventContext.addStyle({
                    '--x': mousePos.x + 'px',
                    '--y': mousePos.y + 'px'
                }).addTo(document.body);
                thisBT.eventHandler.readyDrag(cEvent);
            }, 400);
        }
        else {
            this.eventHandler.readyDrag(event);
        }
    }
};

BoardTable.eventHandler.touchFinishBeforeReadyDrag = function (event) {
    var thisBT = this;
    var dragEventData = this._dragEventData;
    if (!dragEventData) return;
    _Hanger__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].prototype.off2.call(document.body, {
        touchend: this.eventHandler.touchFinishBeforeReadyDrag,
        touchcancel: this.eventHandler.touchFinishBeforeReadyDrag,
        touchmove: this.eventHandler.touchMoveBeforeReadyDrag
    })
    if (this._dragEventData._longPressTimeout > 0) {
        clearTimeout(this._dragEventData._longPressTimeout);
    }
    if (dragEventData.state === 'WAIT') {
        this._dragEventData = null;// canceled
    }
    else {
        setTimeout(function () {
            thisBT.$preventContext.off('contextmenu', thisBT.eventHandler.contextMenu);
            thisBT.$preventContext.remove();
        }, 60);
    }


};

BoardTable.eventHandler.contextMenu = function (event) {
    event.preventDefault();
    this.$preventContext.off('contextmenu', this.eventHandler.contextMenu);
    this.$preventContext.remove();
    this.eventHandler.touchFinishBeforeReadyDrag(event);
}

BoardTable.eventHandler.touchMoveBeforeReadyDrag = function (event) {
    var dragEventData = this._dragEventData;
    var touch = Object(absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_7__[/* findChangedTouchByIdent */ "c"])(event, dragEventData.pointerIdent);
    if (!touch) return;
    var mousePos = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"](touch.clientX, touch.clientY);
    if (dragEventData.state === 'WAIT') {
        var dv = mousePos.sub(dragEventData.mouseStartPos);
        if (dv.abs() > 8) {
            this.eventHandler.touchFinishBeforeReadyDrag(event);
            this._dragEventData = null;// cancel
        }
    }
    else {
        this.$preventContext.addStyle({
            '--x': mousePos.x + 'px',
            '--y': mousePos.y + 'px'
        });
    }

};

BoardTable.eventHandler.readyDrag = function (event) {
    var dragEventData = this._dragEventData;
    dragEventData.state = "PRE_DRAG";
    var bodyEvents = {};
    if (dragEventData.isTouch) {
        bodyEvents.touchmove = this.eventHandler.mousemove;
        bodyEvents.touchcancel = this.eventHandler.mousefinish;
        bodyEvents.touchend = this.eventHandler.mousefinish;
    }
    else {
        bodyEvents.mousemove = this.eventHandler.mousemove;
        bodyEvents.mouseup = this.eventHandler.mousefinish;
        bodyEvents.mouseleave = this.eventHandler.mousefinish;
    }

    _Hanger__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].prototype.on2.call(document.body, bodyEvents);
    if (dragEventData.isTouch) {
        this.eventHandler.mousemove(event);
    }
};

BoardTable.eventHandler.mousemovePredrag = function (event) {
    var dragEventData = this._dragEventData;
    var mousePos = dragEventData.mousePos;
    var thisBT = this;
    event.preventDefault();
    var cBound = dragEventData.boardElt.getBoundingClientRect();
    if (mousePos.sub(dragEventData.mouseStartPos).abs() > 8 || dragEventData.isTouch) {
        dragEventData.placeHolderElt = $(dragEventData.boardElt.cloneNode(false))
            .addClass('as-board-place-holder')
            .addStyle({
                width: cBound.width + 'px',
                height: cBound.height + 'px'
            });
        dragEventData.friendHolders = this.getAllFriends().concat([this]).map(function (elt) {
            //include itself
            var effectZone = elt.getEffectZone();
            var res = {
                elt: elt,
                effectZone: effectZone
            }
            if (!dragEventData.isTouch) {
                var enterEvent = thisBT.eventHandler.enterFriendEffectZone.bind(thisBT, elt);
                _Hanger__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].prototype.on2.call(effectZone, dragEventData.isTouch ? 'touchmove' : 'mouseenter', enterEvent);
                res.enterEvent = enterEvent;
            }
            else {
                // use move event to detect
            }

            return res;
        });
        dragEventData.inEffectZoneOf = this
        dragEventData.cardStyle = {
            width: dragEventData.boardElt.style.width,
            height: dragEventData.boardElt.style.height
        };

        dragEventData.boardElt.addStyle({
            width: cBound.width + 'px',
            height: cBound.height + 'px'
        });

        this.insertBefore(dragEventData.placeHolderElt, dragEventData.boardElt);
        dragEventData.state = "DRAG";
        $(document.body).addClass('as-has-board-table-drag');
        dragEventData.boardElt.addClass('as-board-moving');
        dragEventData.boardAt = dragEventData.holderIndex;
        dragEventData.boardIn = thisBT;
        this.emit('dragitemstart', {
            type: 'dragitemstart',
            target: this,
            boardElt: this._dragEventData.boardElt
        }, this);
    }
};


BoardTable.eventHandler.mousemoveDragInSelf = function (event) {
    var dragEventData = this._dragEventData;
    var mousePos = dragEventData.mousePos;
    if (this._childHolders.length < 2) {
        if (dragEventData.boardIn != this) {
            this.insertBefore(dragEventData.placeHolderElt, this._childHolders[0].elt);
            dragEventData.boardIn = this;
            dragEventData.boardAt = 0;
        }
    }
    else {
        // bản thân chỉ có 1, hoặc nhiều hơn
        var i = this._findHoverBoardIndex(mousePos.x, mousePos.y, [dragEventData.boardElt]);
        if (i >= 0) {
            if (dragEventData.boardIn != this) {
                dragEventData.boardIn = this;
            }
            var viewIndex;
            if ((i < dragEventData.holderIndex && i < dragEventData.boardAt)
                || (i > dragEventData.holderIndex && i > dragEventData.boardAt)
                || dragEventData.holderIndex == dragEventData.boardAt) {
                viewIndex = i;
            }
            else {
                if (dragEventData.holderIndex > dragEventData.boardAt) {
                    viewIndex = i + 1;
                }
                else {
                    viewIndex = i - 1;
                }
            }

            var fbound = this._childHolders[i].elt.getBoundingClientRect();
            var displayStyple = this._childHolders[i].elt.getComputedStyleValue('display');

            if (mousePos.x > fbound.left && mousePos.x < fbound.right
                && mousePos.y > fbound.top && mousePos.y < fbound.bottom) {
                if (displayStyple.startsWith('inline')) {
                    if (dragEventData.boardBound.width < fbound.width) {
                        if (dragEventData.boardAt > viewIndex && mousePos.x > fbound.left + dragEventData.boardBound.width) {
                            viewIndex += 1;
                        }
                        else if (dragEventData.boardAt < viewIndex && mousePos.x < fbound.left + fbound.width - dragEventData.boardBound.width) {
                            viewIndex -= 1;
                        }
                    }
                }
                else {
                    if (dragEventData.boardBound.height < fbound.height) {
                        if (dragEventData.boardAt > viewIndex && mousePos.y >= fbound.top + dragEventData.boardBound.height) {
                            viewIndex += 1;
                        }
                        else if (dragEventData.boardAt < viewIndex && mousePos.y <= fbound.top + fbound.height - dragEventData.boardBound.height) {
                            viewIndex -= 1;
                        }
                    }
                }
                viewIndex = Math.max(0, Math.min(this._childHolders.length, viewIndex));
                if (viewIndex != dragEventData.boardAt) {
                    dragEventData.boardAt = viewIndex;
                    if (dragEventData.holderIndex >= viewIndex) {
                        this.insertBefore(dragEventData.placeHolderElt, this._childHolders[viewIndex].elt);
                    }
                    else {
                        var bf = absol_src_HTML5_Element__WEBPACK_IMPORTED_MODULE_4__[/* default */ "a"].prototype.findChildAfter.call(this, this._childHolders[viewIndex].elt);
                        if (bf)
                            this.insertBefore(dragEventData.placeHolderElt, bf);
                        else {
                            this.appendChild(dragEventData.placeHolderElt);
                        }
                    }
                }
            }
        }
    }
};

BoardTable.eventHandler.mousemoveDragInOther = function (event) {
    var dragEventData = this._dragEventData;
    var mousePos = dragEventData.mousePos;
    var other = dragEventData.inEffectZoneOf;
    if (other._childHolders.length == 0) {
        if (dragEventData.boardIn != other) {
            dragEventData.boardIn = other;
            dragEventData.boardAt = 0;
            other.appendChild(dragEventData.placeHolderElt);
        }
    }
    else {
        var i = other._findHoverBoardIndex(mousePos.x, mousePos.y);
        if (i >= 0) {
            if (dragEventData.boardIn != other) {
                dragEventData.boardIn = other;
            }
            var displayStyple = other._childHolders[i].elt.getComputedStyleValue('display');
            var di = 0;
            var bbound = other._childHolders[i].elt.getBoundingClientRect();

            if (displayStyple.startsWith('inline')) {
                if (mousePos.x > bbound.left + bbound.width / 2) di++;
            }
            else {
                if (mousePos.y > bbound.top + bbound.height / 2) di++;
            }
            i += di;
            if (i < other._childHolders.length) {
                other.insertBefore(dragEventData.placeHolderElt, other._childHolders[i].elt);
            }
            else {
                var bf = other.findChildAfter(other._childHolders[other._childHolders.length - 1].elt);
                if (bf) {
                    other.insertBefore(dragEventData.placeHolderElt, bf);
                }
                else {
                    other.appendChild(dragEventData.placeHolderElt)
                }
            }
            dragEventData.boardAt = i;
        }
    }
};


BoardTable.eventHandler.mousemoveDrag = function (event) {
    var dragEventData = this._dragEventData;
    if (dragEventData.inEffectZoneOf == this) {
        this.eventHandler.mousemoveDragInSelf(event);
    }
    else {
        this.eventHandler.mousemoveDragInOther(event);
    }
};

BoardTable.eventHandler.boarDrag = function (event) {
    var dragEventData = this._dragEventData;
    var mousePos = dragEventData.mousePos;
    var boardPos = mousePos.sub(dragEventData.mouseBoardOffset);
    dragEventData.boardElt.addStyle({
        left: boardPos.x + 'px',
        top: boardPos.y + 'px'
    });
};


BoardTable.eventHandler.dragOnEffectZone = function (event) {
    var dragEventData = this._dragEventData;
    var mousePos = dragEventData.mousePos;
    var friendHolders = dragEventData.friendHolders;
    var bound;
    for (var i = 0; i < friendHolders.length; ++i) {
        bound = absol_src_Math_Rectangle__WEBPACK_IMPORTED_MODULE_5__[/* default */ "a"].fromClientRect(friendHolders[i].effectZone.getBoundingClientRect());
        if (bound.containsPoint(mousePos)) {
            dragEventData.inEffectZoneOf = friendHolders[i].elt;
            break;
        }
    }
};

BoardTable.eventHandler.mousemoveOverflow = function (event) {
    if (!this._dragEventData) return;
    var dragEventData = this._dragEventData;
    var scrollerX = this._dragEventData.boardIn;
    var overflowStyle;
    while (scrollerX) {
        overflowStyle = window.getComputedStyle(scrollerX)['overflow'];
        if ((overflowStyle === 'auto' || overflowStyle === 'auto hidden' || overflowStyle === 'scroll' || scrollerX.tagName === 'HTML') && (scrollerX.clientWidth < scrollerX.scrollWidth)) break;
        scrollerX = scrollerX.parentElement;
    }
    var scrollerY = this._dragEventData.boardIn;
    while (scrollerY) {
        overflowStyle = window.getComputedStyle(scrollerY)['overflow'];
        if ((overflowStyle === 'auto' || overflowStyle === 'hidden auto' || overflowStyle === 'scroll' || scrollerY.tagName === 'HTML') && (scrollerY.clientHeight < scrollerY.scrollHeight)) break;
        scrollerY = scrollerY.parentElement;
    }

    var outBound;
    var bBound;
    var screenSize = absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_6__[/* default */ "b"].getScreenSize();
    var vx = 0;
    var vy = 0;
    bBound = this._dragEventData.boardElt.getBoundingClientRect();
    if (scrollerX) {
        if (dragEventData.$scrollerX !== scrollerX) {
            dragEventData.scrollerXValue = scrollerX.scrollLeft;
            dragEventData.$scrollerX = scrollerX;
        }
        outBound = scrollerX.getBoundingClientRect();
        outBound = {
            left: Math.max(outBound.left, 0),
            top: Math.max(outBound.top, 0),
            bottom: Math.min(outBound.bottom, screenSize.height),
            right: Math.min(outBound.right, screenSize.width)
        }
        if (bBound.left < outBound.left) {
            vx = bBound.left - outBound.left;
        }
        else if (bBound.right > outBound.right) {
            vx = bBound.right - outBound.right;
        }
    }
    else {
        dragEventData.$scrollerX = null;
    }

    if (scrollerY) {
        if (dragEventData.$scrollerY !== scrollerY) {
            dragEventData.scrollerYValue = scrollerY.scrollTop;
            dragEventData.$scrollerY = scrollerY;
        }
        outBound = scrollerY.getBoundingClientRect();
        outBound = {
            left: Math.max(outBound.left, 0),
            top: Math.max(outBound.top, 0),
            bottom: Math.min(outBound.bottom, screenSize.height),
            right: Math.min(outBound.right, screenSize.width)
        }
        if (bBound.top < outBound.top) {
            vy = bBound.top - outBound.top;
        }
        else if (bBound.bottom > outBound.bottom) {
            vy = bBound.bottom - outBound.bottom;
        }
    }
    else {
        dragEventData.$scrollerY = null;
    }


    vx = Math.max(-this.maxScrollSpeed, Math.min(this.maxScrollSpeed, vx * Math.sqrt(Math.abs(vx))));
    vy = Math.max(-this.maxScrollSpeed, Math.min(this.maxScrollSpeed, vy * Math.sqrt(Math.abs(vy))));
    if (vx !== 0 || vy !== 0) {
        var copyEvent = {
            type: event.type,
            preventDefault: function () {/* noop */
            },
            target: event.target
        };
        if (event.type === 'touchmove') {
            copyEvent.changedTouches = Array.prototype.map.call(event.changedTouches, function (it) {
                return { identifier: it.identifier, clientX: it.clientX, clientY: it.clientY, target: it.target }
            });
            copyEvent.touches = Array.prototype.map.call(event.touches, function (it) {
                return { identifier: it.identifier, clientX: it.clientX, clientY: it.clientY, target: it.target }
            });
        }
        else {
            copyEvent.clientX = event.clientX;
            copyEvent.clientY = event.clientY
        }
        var thisBT = this;
        var now = new Date().getTime();
        if (dragEventData.requestAnimationFrameId >= 0) {
            cancelAnimationFrame(dragEventData.requestAnimationFrameId);
        }
        dragEventData.requestAnimationFrameId = requestAnimationFrame(function () {
            dragEventData.requestAnimationFrameId = -1;
            var dt = (new Date().getTime() - now) / 1000;
            if (dragEventData.$scrollerY) {
                dragEventData.scrollerYValue += vy * dt;
                dragEventData.scrollerYValue = Math.max(0, Math.min(dragEventData.$scrollerY.scrollHeight - dragEventData.$scrollerY.clientHeight, dragEventData.scrollerYValue))
                dragEventData.$scrollerY.scrollTop = dragEventData.scrollerYValue;
            }

            if (dragEventData.$scrollerX) {
                dragEventData.scrollerXValue += vx * dt;
                dragEventData.scrollerXValue = Math.max(0, Math.min(dragEventData.$scrollerX.scrollWidth - dragEventData.$scrollerX.clientWidth, dragEventData.scrollerXValue))
                dragEventData.$scrollerX.scrollLeft = dragEventData.scrollerXValue;
            }

            if (thisBT._dragEventData && thisBT._dragEventData.state === "DRAG") {
                thisBT.eventHandler.mousemoveOverflow(copyEvent);
            }
        });
    }
};

BoardTable.eventHandler.mousemove = function (event) {
    var dragEventData = this._dragEventData;
    var isTouch = event.type === 'touchmove' || event.type === 'touchstart';// call from timeout
    if (dragEventData.isTouch !== isTouch) return;
    var mousePos;
    var pointerIdent;
    var touch = -2;
    if (isTouch) {
        touch = Object(absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_7__[/* findChangedTouchByIdent */ "c"])(event, dragEventData.pointerIdent);
        if (touch) {
            pointerIdent = touch.identifier;
            mousePos = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"](touch.clientX, touch.clientY);
        }
    }
    else {
        pointerIdent = -1;
        mousePos = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"](event.clientX, event.clientY);
    }
    if (dragEventData.pointerIdent !== pointerIdent) return;
    dragEventData.mousePos = mousePos;
    event.preventDefault();
    if (dragEventData.isTouch && dragEventData.state === 'DRAG') {
        this.eventHandler.dragOnEffectZone(event);//because touch not have mouseenter event
    }
    if (dragEventData.state === 'PRE_DRAG') {
        this.eventHandler.mousemovePredrag(event);
    }
    if (dragEventData.state === 'DRAG') {
        this.eventHandler.mousemoveDrag(event);
        this.eventHandler.boarDrag(event);
        this.eventHandler.mousemoveOverflow(event);
    }
};


BoardTable.eventHandler.mousefinish = function (event) {
    var dragEventData = this._dragEventData;
    var isTouch = event.type === 'touchend';
    if (dragEventData.isTouch !== isTouch) return;
    var mousePos;
    var pointerIdent;
    var touch = -2;
    if (isTouch) {
        touch = Object(absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_7__[/* findChangedTouchByIdent */ "c"])(event, dragEventData.pointerIdent);
        if (touch) {
            pointerIdent = touch.identifier;
            mousePos = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"](touch.clientX, touch.clientY);
        }
    }
    else {
        pointerIdent = -1;
        mousePos = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"](event.clientX, event.clientY);
    }
    if (dragEventData.pointerIdent !== pointerIdent) return;
    dragEventData.mousePos = mousePos;

    var changed;
    if (dragEventData.state == 'DRAG') {
        setTimeout(function () {
            $(document.body).removeClass('as-has-board-table-drag');
        }, 1)
        dragEventData.boardElt.removeClass('as-board-moving')
            .removeStyle('left')
            .removeStyle('top');
        dragEventData.boardElt.addStyle(dragEventData.cardStyle);
        dragEventData.placeHolderElt.remove();
        dragEventData.state = "FINISH";
        if (!dragEventData.isTouch)
            dragEventData.friendHolders.forEach(function (holder) {
                _Hanger__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].prototype.off2.call(holder.effectZone, 'mouseenter', holder.enterEvent);
            });

        if (dragEventData.boardIn == this) {
            if (dragEventData.holderIndex != dragEventData.boardAt) {
                if (dragEventData.holderIndex > dragEventData.boardAt) {
                    this.insertBefore(dragEventData.boardElt, this._childHolders[dragEventData.boardAt].elt);
                }
                else if (dragEventData.holderIndex < dragEventData.boardAt) {
                    var bf = absol_src_HTML5_Element__WEBPACK_IMPORTED_MODULE_4__[/* default */ "a"].prototype.findChildAfter.call(this, this._childHolders[dragEventData.boardAt].elt);
                    if (bf)
                        this.insertBefore(dragEventData.boardElt, bf);
                    else {
                        this.appendChild(dragEventData.boardElt);
                    }
                }
                var holder = this._childHolders.splice(dragEventData.holderIndex, 1)[0];
                this._childHolders.splice(dragEventData.boardAt, 0, holder);
                changed = 'orderchange';
                this.emit('orderchange', {
                    type: 'orderchange',
                    boardElt: holder.elt,
                    action: 'move',
                    from: dragEventData.holderIndex,
                    to: dragEventData.boardAt,
                    target: this,
                }, this);
            }
        }
        else {
            var holder = this._childHolders.splice(dragEventData.holderIndex, 1)[0];
            holder.elt.remove();
            ///remove all event
            var other = dragEventData.boardIn;
            changed = 'itemleave';
            this.emit('itemleave', {
                type: 'itemleave',
                item: holder.elt,
                from: { index: dragEventData.holderIndex, table: this },
                to: { index: dragEventData.boardAt, table: other },
                target: this
            }, this);
            if (other._childHolders.length == 0) {
                other.appendChild(holder.elt);
                other._childHolders.push(holder);
            }
            else {
                if (dragEventData.boardAt < other._childHolders.length) {
                    other.insertBefore(holder.elt, other._childHolders[dragEventData.boardAt].elt);
                    other._childHolders.splice(dragEventData.boardAt, 0, holder);
                }
                else {
                    var bf = other.findDomChildAfter(other._childHolders.elt);
                    if (bf) {
                        other.insertBefore(holder.elt, bf);
                    }
                    else {
                        other.appendChild(holder.elt);
                    }
                    other._childHolders.push(holder);
                }
            }
            other.emit('itementer', {
                type: 'itementer',
                item: holder.elt,
                target: other,
                from: { index: dragEventData.holderIndex, table: this },
                to: { index: dragEventData.boardAt, table: other }
            }, other);
        }
        this.emit('dragitemend', {
            type: 'dragitemend',
            target: this,
            changed: changed,
            boardElt: this._dragEventData.boardElt
        }, this);
    }

    var bodyEvents = {};
    if (dragEventData.isTouch) {
        bodyEvents.touchmove = this.eventHandler.mousemove;
        bodyEvents.touchcancel = this.eventHandler.mousefinish;
        bodyEvents.touchend = this.eventHandler.mousefinish;
    }
    else {
        bodyEvents.mousemove = this.eventHandler.mousemove;
        bodyEvents.mouseup = this.eventHandler.mousefinish;
        bodyEvents.mouseleave = this.eventHandler.mousefinish;
    }
    _Hanger__WEBPACK_IMPORTED_MODULE_9__[/* default */ "a"].prototype.off2.call(document.body, bodyEvents);
    this._dragEventData = null;
};

BoardTable.eventHandler.enterFriendEffectZone = function (friendElt, event) {
    this._dragEventData.inEffectZoneOf = friendElt;
};

BoardTable.prototype.getAllBoards = function () {
    return this._childHolders.map(function (holder) {
        return holder.elt;
    });
};


BoardTable.property = {};
BoardTable.property.friends = {
    set: function (value) {
        value = value || [];
        if (!(value instanceof Array))
            value = [value];
        this._friends = value;
    },
    get: function () {
        return this._friends;
    }
};

_ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].install(BoardTable);
/* harmony default export */ __webpack_exports__["a"] = (BoardTable);

/***/ }),
/* 72 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_radiobutton_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(196);
/* harmony import */ var _css_radiobutton_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_radiobutton_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1);
/* harmony import */ var absol_src_HTML5_AElement__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(8);






var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;


/***
 * @extends AElement
 * @constructor
 */
function RadioButton() {
    var thisRB = this;
    this.defineEvent('change');
    this.$input = $('input', this).on('change', this.notifyChange.bind(this));
    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].drillProperty(this, this.$input, ['value', 'checked']);

}

RadioButton.tag = 'radiobutton';

RadioButton.radioProto = _(
    '<svg class="absol-radio-icon" width="20" height="20" version="1.1" viewBox="0 0 5.2917 5.2917"' +
    '   xmlns="http://www.w3.org/2000/svg">' +
    '    <g transform="translate(0 -291.71)">' +
    '        <circle class="bound" cx="2.6458" cy="294.35" r="2.4626" style="stroke-opacity:.99497;stroke-width:.26458;" />' +
    '        <circle class="dot" cx="2.6458" cy="294.35"  r= "0.92604" style="fill-rule:evenodd;" />' +
    '    </g>' +
    '</svg>'
)

RadioButton.render = function () {
    return _({
        tag:'label',
        class: 'absol-radio-button',
        child: [
            { tag: 'input', attr: { type: 'radio' } },
            RadioButton.radioProto.cloneNode(true)
        ]
    });
};


RadioButton.prototype.notifyChange = function () {
    this.emit('change', { type: 'change', checked: this.checked, target: this }, this);
};


RadioButton.prototype.getAllFriend = function () {
    return Radio.getAllByName(this.name);
};


RadioButton.attribute = {
    checked: {
        set: function (value) {
            if (value == 'false' || value == null) {
                this.checked = false;
            }
            else {
                this.checked = true;
            }

        },
        get: function () {
            return this.checked ? 'true' : 'false'
        },
        remove: function () {
            this.checked = false;
        }
    },
    disabled: {
        set: function (value) {
            if (value == 'false' || value == null) {
                this.disabled = false;
            }
            else {
                this.disabled = true;
            }

        },
        get: function () {
            return this.disabled ? 'true' : 'false'
        },
        remove: function () {
            this.disabled = false;
        }
    },
    name: {
        set: function (value) {
            this.name = value;
        },
        get: function () {
            return this.name;
        },
        remove: function () {
            this.name = null;
        }
    }
}

RadioButton.property = {
    name: {
        set: function (name) {
            if (name == null) this.$input.removeAttribute('name');
            else
                this.$input.setAttribute('name', name);

        },
        get: function () {
            return this.$input.getAttribute('name');
        }
    },
    disabled: {
        set: function (value) {
            this.$input.disabled = !!value;
            if (value) {
                this.addClass('disabled');
            }
            else {
                this.removeClass('disabled');
            }
        },
        get: function () {
            return this.$input.disabled;
        }
    }
};

RadioButton.getAllByName = function (name) {
    return (document.getElementsByTagName('input') || []).filter(function (elt) {
        return elt.getAttribute('type') == 'radio' && elt.getAttribute('name') == name;
    });
};

RadioButton.getValueByName = function (name) {
    var inputs = RadioButton.getAllByName(name);
    var res = null;
    var input;
    for (var i = 0; i < inputs.length; ++i) {
        input = inputs[i];
        if (input.checked) {
            res = input.value;
        }
    }
    return res;
};



RadioButton.autoReplace = function () {
    var placeHolders = Array.prototype.slice.call(document.getElementsByTagName(this.tag));
    var ph;
    var attOfPH;
    var attrs;
    var style;
    var classList;
    var attNode;
    var attrName, attrValue;
    var props;
    for (var i = 0; i < placeHolders.length; ++i) {
        ph = placeHolders[i];
        attOfPH = ph.attributes;
        classList = [];
        style = {};
        attrs = {};
        props = {};
        for (var j = 0; j < attOfPH.length; ++j) {
            attNode = attOfPH[j];
            attrName = attNode.nodeName;
            attrValue = attNode.nodeValue;
            if (attrName == 'style') {
                attrValue.trim().split(';').reduce(function (style, prop) {
                    var p = prop.split(':');
                    if (p.length == 2) {
                        style[p[0].trim()] = p[1].trim();
                    }
                    return style;
                }, style);
            }
            else if (attrName == 'class') {
                classList = attrValue.trim().split(/\s+/);
            }
            else if (attrName == 'onchange') {
                props.onchange = new Function('event', 'sender', attrValue);
            }
            else {
                attrs[attrName] = attrValue;
            }
        }
        var newElt = _({
            tag: this.tag,
            attr: attrs,
            class: classList,
            style: style,
            props: props
        });
        $(ph).selfReplace(newElt);
    }
};

RadioButton.initAfterLoad = function (){
    absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_3__[/* default */ "b"].documentReady.then(function (){
        RadioButton.autoReplace();
    })
};


_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install('RadioButton'.toLowerCase(), RadioButton);

/* harmony default export */ __webpack_exports__["a"] = (RadioButton);

/***/ }),
/* 73 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_radio_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(198);
/* harmony import */ var _css_radio_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_radio_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2);
/* harmony import */ var _RadioButton__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(72);
/* harmony import */ var absol_src_HTML5_Svg__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(16);
/* harmony import */ var absol_src_HTML5_AElement__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(8);








var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;
var $$ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$$;
var _svg = absol_src_HTML5_Svg__WEBPACK_IMPORTED_MODULE_4__[/* default */ "a"].ShareInstance._;

/***
 * @extends AElement
 * @constructor
 */
function Radio() {
    var thisR = this;
    this.defineEvent('change');
    this.$input = $('input', this)
        .on('change', this.notifyChange.bind(this));
    this.$labels = $$('span', this);

    absol_src_HTML5_OOP__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].drillProperty(this, this.$input, ['value', 'checked']);
}

Radio.tag = 'radio';

Radio.radioProto = _(
    '<svg class="absol-radio-icon" width="20" height="20" version="1.1" viewBox="0 0 5.2917 5.2917"' +
    '   xmlns="http://www.w3.org/2000/svg">' +
    '    <g transform="translate(0 -291.71)">' +
    '        <circle class="bound" cx="2.6458" cy="294.35" r="2.4626" style="stroke-opacity:.99497;stroke-width:.26458;" />' +
    '        <circle class="dot" cx="2.6458" cy="294.35"  r= "0.92604" style="fill-rule:evenodd;" />' +
    '    </g>' +
    '</svg>'
)

Radio.render = function () {
    return _({
        tag: 'label',
        class: 'absol-radio',
        child: [
            { tag: 'input', attr: { type: 'radio' } },
            { tag: 'span', class: 'absol-radio-left-label' },
            Radio.radioProto.cloneNode(true),
            { tag: 'span', class: 'absol-radio-right-label' }
        ]
    });
};


Radio.prototype.notifyChange = function () {
    this.emit('change', { type: 'change', checked: this.checked, target: this }, this);
};


Radio.prototype.getAllFriend = function () {
    return Radio.getAllByName(this.name);
};


Radio.attribute = _RadioButton__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"].attribute;

Radio.property = {
    name: {
        set: function (name) {
            this.$input.setAttribute('name', name);

        },
        get: function () {
            return this.$input.getAttribute('name');
        }
    },
    text: {
        set: function (value) {
            value = (value || '').trim();
            this.$labels[0].clearChild();
            this.$labels[1].clearChild();

            if (value) {
                this.$labels[0].addChild(_({ text: value }));
                this.$labels[1].addChild(_({ text: value }));
            }

        },
        get: function () {
            return this.$labels[0].firstChild.data;
        }
    },
    disabled: {
        set: function (value) {
            this.$input.disabled = !!value;
            if (value) {
                this.addClass('disabled');
            }
            else {
                this.removeClass('disabled');
            }
        },
        get: function () {
            return this.$input.disabled;
        }
    }
};

Radio.getAllByName = function (name) {
    return (Array.apply(null, document.getElementsByTagName('input')) || []).filter(function (elt) {
        return elt.getAttribute('type') == 'radio' && elt.getAttribute('name') == name;
    });
};

Radio.getValueByName = function (name) {
    var inputs = Radio.getAllByName(name);
    var res = null;
    var input;
    for (var i = 0; i < inputs.length; ++i) {
        input = inputs[i];
        if (input.checked) {
            res = input.value;
        }
    }
    return res;
};


_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(Radio);

/* harmony default export */ __webpack_exports__["a"] = (Radio);

/***/ }),
/* 74 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_onscreenwidget_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(247);
/* harmony import */ var _css_onscreenwidget_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_onscreenwidget_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var _Hanger__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(29);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1);
/* harmony import */ var absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(9);
/* harmony import */ var absol_src_String_stringGenerate__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(12);







var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;
var $$ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$$;


/***
 * @extends Hanger
 * @constructor
 */
function OnScreenWidget() {
    this.id = 'unset-id-' + Object(absol_src_String_stringGenerate__WEBPACK_IMPORTED_MODULE_5__["randomIdent"])();
    this.on({
        dragstart: this.eventHandler.widgetStartDrag,
        drag: this.eventHandler.widgetDrag,
        dragend: this.eventHandler.widgetDragEnd
    });

    this.addEventListener('click', function (event) {
        if (!this._preventClick)
            this.emit('click', event, this);
    });
    this.$attachhook = _('attachhook').addTo(this);
    this.$attachhook.on('attached', this.eventHandler.attached);
    this.config = null;
}

OnScreenWidget.tag = 'OnScreenWidget'.toLowerCase();

OnScreenWidget.render = function () {
    return _({
        tag: 'hanger',
        extendEvent: 'click',
        class: ['as-onscreen-widget', 'as-size-loading'],
        props:{
            hangOn: 3
        }
    });
};

OnScreenWidget.prototype.configPrefix = 'on-screen-widget-';

OnScreenWidget.prototype._genConfig = function () {
    this._widgetBound = this.getBoundingClientRect();
    var screenSize = Object(absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_3__[/* getScreenSize */ "d"])();
    return {
        cx: (this._widgetBound.left + this._widgetBound.width / 2) * 100 / screenSize.width,
        cy: (this._widgetBound.top + this._widgetBound.height / 2) * 100 / screenSize.height
    }

}

OnScreenWidget.prototype._saveConfig = function () {
    var id = this.id || '';
    if (id.startsWith('unset-id-') || !this.config) return;
    localStorage.setItem(this.configPrefix + id, JSON.stringify(this.config));
};

OnScreenWidget.prototype._loadConfig = function () {
    var id = this.id || '';
    if (id.startsWith('unset-id-')) return;
    var config = null;
    try {
        config = JSON.parse(localStorage.getItem(this.configPrefix + id));
        if ((typeof config !== "object") || (typeof config.cx !== "number") || (typeof config.cy !== 'number')) {
            config = this.config || this._genConfig();
        }
    } catch (error) {
        config = this.config || this._genConfig();
    }

    var cx = config.cx || 0;
    var cy = config.cy || 0;
    this.addStyle({
        '--cx': cx / 100,
        '--cy': cy / 100
    });
    this.config = config;
};


OnScreenWidget.prototype._updateCSSSize = function () {
    var bound = this.getBoundingClientRect();
    this.addStyle({
        '--client-height': bound.height + 'px',
        '--client-width': bound.width + 'px'
    });
    this.removeClass('as-size-loading');
};

/***
 *
 * @type {OnScreenWidget|{}}
 */
OnScreenWidget.eventHandler = {};

OnScreenWidget.eventHandler.attached = function () {
    var images = $$('img', this);
    var syncs = images.map(function (img) {
        if (img.classList.contains('absol-attachhook')) return Promise.resolve();
        return Object(absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_3__[/* waitImageLoaded */ "g"])(img, 100);
    });
    var thisW = this;
    Promise.all(syncs).then(function () {
        thisW._updateCSSSize();
        thisW._loadConfig();
    });
};

OnScreenWidget.eventHandler.widgetStartDrag = function (event) {
    this._widgetBound = this.getBoundingClientRect();
    this._preventClick = true;
};

OnScreenWidget.eventHandler.widgetDrag = function (event) {
    event.preventDefault();
    var screenSize = Object(absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_3__[/* getScreenSize */ "d"])();
    var p0 = new absol_src_Math_Vec2__WEBPACK_IMPORTED_MODULE_4__[/* default */ "a"](this._widgetBound.left, this._widgetBound.top);
    var dv = event.currentPoint.sub(event.startingPoint);
    var p1 = p0.add(dv);
    var cx = (p1.x - 2) * 100 / (screenSize.width - this._widgetBound.width - 4);
    var cy = (p1.y - 2) * 100 / (screenSize.height - this._widgetBound.height - 4);
    cx = Math.max(0, Math.min(100, cx));
    cy = Math.max(0, Math.min(100, cy));
    this.addStyle({
        '--cx': cx / 100,
        '--cy': cy / 100
    });
    if (this.config) {
        this.config.cx = cx;
        this.config.cy = cy;
    }
};

OnScreenWidget.eventHandler.widgetDragEnd = function () {
    var thisWG = this;
    setTimeout(function () {
        thisWG._preventClick = false;
    }, 100);
    this._saveConfig();
};

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(OnScreenWidget);

/* harmony default export */ __webpack_exports__["a"] = (OnScreenWidget);

/***/ }),
/* 75 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/***
 *
 * @param {T} value
 * @constructor
 * @template T
 */
function Ref(value) {
    this.set(value);
}

Ref.prototype.toString = function () {
    return this.value + '';
};

/***
 *
 * @return {T}
 */
Ref.prototype.valueOf = function () {
    return this.value;
};

/***
 *
 * @param {T}value
 */
Ref.prototype.set = function (value) {
    this.value = value;
};

/**
 *
 * @return {T}
 */
Ref.prototype.get = function () {
    return this.value;
}

/* harmony default export */ __webpack_exports__["a"] = (Ref);







/***/ }),
/* 76 */
/***/ (function(module) {

module.exports = JSON.parse("[\"3g2\",\"3ga\",\"3gp\",\"7z\",\"aa\",\"aac\",\"ac\",\"accdb\",\"accdt\",\"ace\",\"adn\",\"ai\",\"aif\",\"aifc\",\"aiff\",\"ait\",\"amr\",\"ani\",\"apk\",\"app\",\"applescript\",\"asax\",\"asc\",\"ascx\",\"asf\",\"ash\",\"ashx\",\"asm\",\"asmx\",\"asp\",\"aspx\",\"asx\",\"au\",\"aup\",\"avi\",\"axd\",\"aze\",\"bak\",\"bash\",\"bat\",\"bin\",\"blank\",\"bmp\",\"bowerrc\",\"bpg\",\"browser\",\"bz2\",\"bzempty\",\"c\",\"cab\",\"cad\",\"caf\",\"cal\",\"cd\",\"cdda\",\"cer\",\"cfg\",\"cfm\",\"cfml\",\"cgi\",\"chm\",\"class\",\"cmd\",\"code-workspace\",\"codekit\",\"coffee\",\"coffeelintignore\",\"com\",\"compile\",\"conf\",\"config\",\"cpp\",\"cptx\",\"cr2\",\"crdownload\",\"crt\",\"crypt\",\"cs\",\"csh\",\"cson\",\"csproj\",\"css\",\"csv\",\"cue\",\"cur\",\"dart\",\"dat\",\"data\",\"db\",\"dbf\",\"deb\",\"default\",\"dgn\",\"dist\",\"diz\",\"dll\",\"dmg\",\"dng\",\"doc\",\"docb\",\"docm\",\"docx\",\"dot\",\"dotm\",\"dotx\",\"download\",\"dpj\",\"ds_store\",\"dsn\",\"dtd\",\"dwg\",\"dxf\",\"editorconfig\",\"el\",\"elf\",\"eml\",\"enc\",\"eot\",\"eps\",\"epub\",\"eslintignore\",\"exe\",\"f4v\",\"fax\",\"fb2\",\"fla\",\"flac\",\"flv\",\"fnt\",\"folder\",\"fon\",\"gadget\",\"gdp\",\"gem\",\"gif\",\"gitattributes\",\"gitignore\",\"go\",\"gpg\",\"gpl\",\"gradle\",\"gz\",\"h\",\"handlebars\",\"hbs\",\"heic\",\"hlp\",\"hs\",\"hsl\",\"htm\",\"html\",\"ibooks\",\"icns\",\"ico\",\"ics\",\"idx\",\"iff\",\"ifo\",\"image\",\"img\",\"iml\",\"in\",\"inc\",\"indd\",\"inf\",\"info\",\"ini\",\"inv\",\"iso\",\"j2\",\"jar\",\"java\",\"jpe\",\"jpeg\",\"jpg\",\"js\",\"json\",\"jsp\",\"jsx\",\"key\",\"kf8\",\"kmk\",\"ksh\",\"kt\",\"kts\",\"kup\",\"less\",\"lex\",\"licx\",\"lisp\",\"lit\",\"lnk\",\"lock\",\"log\",\"lua\",\"m\",\"m2v\",\"m3u\",\"m3u8\",\"m4\",\"m4a\",\"m4r\",\"m4v\",\"map\",\"master\",\"mc\",\"md\",\"mdb\",\"mdf\",\"me\",\"mi\",\"mid\",\"midi\",\"mk\",\"mkv\",\"mm\",\"mng\",\"mo\",\"mobi\",\"mod\",\"mov\",\"mp2\",\"mp3\",\"mp4\",\"mpa\",\"mpd\",\"mpe\",\"mpeg\",\"mpg\",\"mpga\",\"mpp\",\"mpt\",\"msg\",\"msi\",\"msu\",\"nef\",\"nes\",\"nfo\",\"nix\",\"npmignore\",\"ocx\",\"odb\",\"ods\",\"odt\",\"ogg\",\"ogv\",\"ost\",\"otf\",\"ott\",\"ova\",\"ovf\",\"p12\",\"p7b\",\"pages\",\"part\",\"pcd\",\"pdb\",\"pdf\",\"pem\",\"pfx\",\"pgp\",\"ph\",\"phar\",\"php\",\"pid\",\"pkg\",\"pl\",\"plist\",\"pm\",\"png\",\"po\",\"pom\",\"pot\",\"potx\",\"pps\",\"ppsx\",\"ppt\",\"pptm\",\"pptx\",\"prop\",\"ps\",\"ps1\",\"psd\",\"psp\",\"pst\",\"pub\",\"py\",\"pyc\",\"qt\",\"ra\",\"ram\",\"rar\",\"raw\",\"rb\",\"rdf\",\"rdl\",\"reg\",\"resx\",\"retry\",\"rm\",\"rom\",\"rpm\",\"rpt\",\"rsa\",\"rss\",\"rst\",\"rtf\",\"ru\",\"rub\",\"sass\",\"scss\",\"sdf\",\"sed\",\"sh\",\"sit\",\"sitemap\",\"skin\",\"sldm\",\"sldx\",\"sln\",\"sol\",\"sphinx\",\"sql\",\"sqlite\",\"step\",\"stl\",\"svg\",\"swd\",\"swf\",\"swift\",\"swp\",\"sys\",\"tar\",\"tax\",\"tcsh\",\"tex\",\"tfignore\",\"tga\",\"tgz\",\"tif\",\"tiff\",\"tmp\",\"tmx\",\"torrent\",\"tpl\",\"ts\",\"tsv\",\"ttf\",\"twig\",\"txt\",\"udf\",\"vb\",\"vbproj\",\"vbs\",\"vcd\",\"vcf\",\"vcs\",\"vdi\",\"vdx\",\"vmdk\",\"vob\",\"vox\",\"vscodeignore\",\"vsd\",\"vss\",\"vst\",\"vsx\",\"vtx\",\"war\",\"wav\",\"wbk\",\"webinfo\",\"webm\",\"webp\",\"wma\",\"wmf\",\"wmv\",\"woff\",\"woff2\",\"wps\",\"wsf\",\"xaml\",\"xcf\",\"xfl\",\"xlm\",\"xls\",\"xlsm\",\"xlsx\",\"xlt\",\"xltm\",\"xltx\",\"xml\",\"xpi\",\"xps\",\"xrb\",\"xsd\",\"xsl\",\"xspf\",\"xz\",\"yaml\",\"yml\",\"z\",\"zip\",\"zsh\"]");

/***/ }),
/* 77 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_dateinyearinput_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(303);
/* harmony import */ var _css_dateinyearinput_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_dateinyearinput_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_DomSignal__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(20);
/* harmony import */ var absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5);






/***
 * @extends AElement
 * @constructor
 */
function DateInYearPicker() {
    this._month = null;
    this._date = null;
    this.$domSignal = Object(_ACore__WEBPACK_IMPORTED_MODULE_1__[/* _ */ "c"])('attachhook').addTo(this);
    this.domSignal = new absol_src_HTML5_DomSignal__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"](this.$domSignal);
    this._setupMonth();
    this._setupDate();
}


DateInYearPicker.tag = 'DateInYearPicker'.toLowerCase();

DateInYearPicker.render = function () {
    return Object(_ACore__WEBPACK_IMPORTED_MODULE_1__[/* _ */ "c"])({
        extendEvent: ['change'],
        class: 'as-date-in-year-picker',
        child: [
            {
                class: 'as-date-in-year-picker-table',
                child: [
                    {
                        class: 'as-date-in-year-picker-row',
                        child: [
                            {
                                class: 'as-date-in-year-picker-cell',
                                child: {tag: 'span', child: {text: 'Month'}}

                            },
                            {
                                class: 'as-date-in-year-picker-cell',
                                child: {tag: 'span', child: {text: 'Date'}}
                            }
                        ]
                    },
                    {
                        class: 'as-date-in-year-picker-row',
                        child: [
                            {
                                class: 'as-date-in-year-picker-cell',

                                child: {
                                    class: 'as-date-in-year-picker-month-col',
                                    child: [
                                        {
                                            class: 'as-date-in-year-picker-month-viewport',
                                            child: [
                                                {
                                                    class: 'as-date-in-year-picker-month-scroller',
                                                    child: Array(36).fill(null).map(function (u, i) {
                                                        return {
                                                            tag: 'button',
                                                            class: 'as-date-in-year-picker-month',
                                                            child: {
                                                                tag: 'span',
                                                                child: {text: 1 + i % 12 + ''}
                                                            },
                                                            props: {
                                                                monthL: i % 12
                                                            }
                                                        }
                                                    })
                                                }
                                            ]
                                        },
                                        {
                                            tag: 'button',
                                            class: ['as-date-in-year-picker-month-btn', 'as-up'],
                                            child: 'span.mdi.mdi-chevron-up'
                                        },
                                        {
                                            tag: 'button',
                                            class: ['as-date-in-year-picker-month-btn', 'as-down'],
                                            child: 'span.mdi.mdi-chevron-down'
                                        }
                                    ]
                                }
                            },
                            {
                                class: 'as-date-in-year-picker-cell',
                                child: {
                                    class: 'as-date-in-year-picker-days',
                                    child: Array(5).fill(null).map(function (u, i) {
                                        return {
                                            class: 'as-date-in-year-picker-week',
                                            child: Array(7).fill(null).map(function (u1, j) {
                                                return {
                                                    class: 'as-date-in-year-picker-day',
                                                    child: {
                                                        tag: 'span',
                                                        child: {text: i * 7 + j + 1 + ''}
                                                    }
                                                };
                                            })
                                        };

                                    })
                                }
                            }
                        ]
                    }
                ]
            }
        ]

    });
};


DateInYearPicker.prototype._setupMonth = function () {
    this._monthScrollDy = 0;
    this.$monthScroller = Object(_ACore__WEBPACK_IMPORTED_MODULE_1__[/* $ */ "a"])('.as-date-in-year-picker-month-scroller', this)
        .on('scroll', this.eventHandler.monthScroll)
        .once('wheel', this.eventHandler.monthScroll);
    this.$monthUpBtn = Object(_ACore__WEBPACK_IMPORTED_MODULE_1__[/* $ */ "a"])('.as-date-in-year-picker-month-btn.as-up', this)
        .on('pointerdown', this.eventHandler.monthPressDown);
    this.$monthDownBtn = Object(_ACore__WEBPACK_IMPORTED_MODULE_1__[/* $ */ "a"])('.as-date-in-year-picker-month-btn.as-down', this)
        .on('pointerdown', this.eventHandler.monthPressUp);
    this.$months = Object(_ACore__WEBPACK_IMPORTED_MODULE_1__[/* $$ */ "b"])('.as-date-in-year-picker-month', this);
    for (var i = 0; i < 36; ++i)
        this.$months[i].on('click', this.eventHandler.clickMonth.bind(this, i % 12));

};

DateInYearPicker.prototype._setupDate = function () {
    this.$days = Object(_ACore__WEBPACK_IMPORTED_MODULE_1__[/* $$ */ "b"])('.as-date-in-year-picker-day', this);
    var i;
    for (i = 31; i < 35; ++i) {
        this.$days[i].addStyle('visibility', 'hidden');
    }
    for (i = 0; i < 31; ++i) {
        this.$days[i].on('click', this.eventHandler.clickDate.bind(this, i + 1));
    }
};

DateInYearPicker.prototype.scrollIntoSelected = function () {
    if (!this.isDescendantOf(document.body)) {
        this.domSignal.emit('scrollIntoSelected');
        return;
    }

    var d = Infinity;
    var dy;
    var y;
    var ly, hy;
    if (this._month !== null) {
        for (var k = 0; k < 3; ++k) {
            y = this._month * 28 + 28 * 12 * k;
            ly = this.$monthScroller.scrollTop;
            hy = ly + 112 - 28;
            if (ly <= y && hy >= y) {
                dy = 0;
                break;
            }
            if (y < ly && ly - y < d) {
                d = ly - y;
                dy = y - ly;
            }

            if (y > hy && y - hy < d) {
                d = y - hy;
                dy = y - hy;
            }
        }

        this.$monthScroller.scrollTop += dy;
    }
};

/***
 * @memberOf DateInYearPicker#
 * @type {{}}
 */
DateInYearPicker.eventHandler = {};


/***
 * @this DateInYearPicker
 */
DateInYearPicker.eventHandler.monthPressDown = function () {
    document.addEventListener('pointerup', this.eventHandler.monthRelease);
    this._monthScrollDy = -8;
    this.eventHandler.monthTick();

};

/**
 * @this DateInYearPicker
 */
DateInYearPicker.eventHandler.monthPressUp = function () {
    document.addEventListener('pointerup', this.eventHandler.monthRelease);
    this._monthScrollDy = 8;
    this.eventHandler.monthTick();
};

/**
 * @this DateInYearPicker
 */
DateInYearPicker.eventHandler.monthTick = function () {
    if (!this._monthScrollDy) return;
    var d = this._monthScrollDy;
    if (this.$monthScroller.scrollTop + d < 0) d += 28 * 12;
    this.$monthScroller.scrollTop += d;
    setTimeout(this.eventHandler.monthTick, 30);
};

DateInYearPicker.eventHandler.monthRelease = function () {
    document.removeEventListener('pointerup', this.eventHandler.monthRelease);
    this._monthScrollDy = 0;
};

/**
 * @this DateInYearPicker
 */
DateInYearPicker.eventHandler.monthScroll = function () {
    var scrollTop = this.$monthScroller.scrollTop;
    if (scrollTop < 28 * 12) {
        this.$monthScroller.scrollTop += 28 * 12;
    } else if (scrollTop > 28 * 12 * 2) {
        this.$monthScroller.scrollTop -= 28 * 12;
    }
};

/**
 * @this DateInYearPicker
 */
DateInYearPicker.eventHandler.clickMonth = function (month, event) {
    var pDate = this.date;
    if (this.month === month) return;
    this.month = month;
    this.emit('change', {type: 'change', originalEvent: event, target: this}, this);
};


/**
 * @this DateInYearPicker
 */
DateInYearPicker.eventHandler.clickDate = function (date, event) {
    if (this.date === date) return
    this.date = date;
    this.emit('change', {type: 'change', originalEvent: event, target: this}, this);
};


DateInYearPicker.property = {};

DateInYearPicker.property.date = {
    set: function (value) {
        if (typeof value !== 'number') value = null;
        var cM, dim;
        if (this._month === null) {
            dim = 31;
        } else {
            cM = new Date(2000, this._month, 1);
            dim = Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_3__["compareDate"])(Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_3__["nextMonth"])(cM), cM);
        }
        if (typeof value === "number")
            value = Math.max(1, Math.min(dim, Math.floor(value)));
        if (isNaN(value)) value = null;
        if (this._date === value) return;
        if (this._date !== null) {
            this.$days[this._date - 1].removeClass('as-selected');
        }
        this._date = value;
        if (this._date !== null) {
            this.$days[this._date - 1].addClass('as-selected');
        }

    },
    get: function () {
        return this._date;
    }
};

DateInYearPicker.property.month = {
    /***
     * @this DateInYearPicker
     * @param value
     */
    set: function (value) {
        if (typeof value == 'number') {
            value = Math.max(0, Math.min(11, Math.floor(value)));
        } else value = null;
        if (isNaN(value)) value = null;
        if (this._month === value) return;
        if (this._month !== null) {
            this.$months[this._month].removeClass('as-selected');
            this.$months[this._month + 12].removeClass('as-selected');
            this.$months[this._month + 24].removeClass('as-selected');
        }
        this._month = value;
        var cM, dim;
        if (this._month !== null) {
            this.$months[this._month].addClass('as-selected');
            this.$months[this._month + 12].addClass('as-selected');
            this.$months[this._month + 24].addClass('as-selected');
            this.scrollIntoSelected();
            cM = new Date(2000, this._month, 1);
            dim = Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_3__["compareDate"])(Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_3__["nextMonth"])(cM), cM);

        } else {
            dim = 31;
        }
        for (var i = 29; i < 31; ++i) {
            if (i < dim) {
                this.$days[i].removeStyle('visibility');
            } else {
                this.$days[i].addStyle('visibility', 'hidden');
            }
        }
        this.date = Math.min(this.date, dim);
    },
    get: function () {
        return this._month;
    }
};


DateInYearPicker.property.value = {
    set: function (value) {
        value = value || {month: null, date: null};
        this.month = value.month;
        this.date = value.date;
    },
    get: function () {
        return {month: this.month, date: this.date};
    }
};

_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(DateInYearPicker);

/* harmony default export */ __webpack_exports__["a"] = (DateInYearPicker);


/***/ }),
/* 78 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
/* harmony import */ var _js_DebugTask__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(69);
/* harmony import */ var _css_debugtask_css__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(326);
/* harmony import */ var _css_debugtask_css__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_css_debugtask_css__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var _js_Draggable__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(49);
/* harmony import */ var _js_EmojiChars__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(79);
/* harmony import */ var _js_EmojiAnims__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(33);
/* harmony import */ var _js_dom_install__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(64);
/* harmony import */ var _js_tool_BlurTrigger__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(58);













var AComp = {
    core: _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"],
    $: _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].$,
    _: _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"]._,
    creator: _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].creator,
    buildDom: _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].buildDom,
    runDebugTask: _js_DebugTask__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"].start.bind(_js_DebugTask__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"]),
    Draggable: _js_Draggable__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"],
    EmojiChars: _js_EmojiChars__WEBPACK_IMPORTED_MODULE_4__[/* default */ "a"],
    EmojiAnims: _js_EmojiAnims__WEBPACK_IMPORTED_MODULE_5__[/* default */ "a"],
    install: _js_dom_install__WEBPACK_IMPORTED_MODULE_6__[/* default */ "a"],
    BlurTrigger: _js_tool_BlurTrigger__WEBPACK_IMPORTED_MODULE_7__[/* default */ "a"]
};

window.runDebugTask = _js_DebugTask__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"].start.bind(_js_DebugTask__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"]);

/* harmony default export */ __webpack_exports__["a"] = (AComp);

/***/ }),
/* 79 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
var EmojiChars = [["Smileys & Emotion", [["face-smiling", [[["U+1F600"], "😀", "grinning face"], [["U+1F603"], "😃", "grinning face with big eyes"], [["U+1F604"], "😄", "grinning face with smiling eyes"], [["U+1F601"], "😁", "beaming face with smiling eyes"], [["U+1F606"], "😆", "grinning squinting face"], [["U+1F605"], "😅", "grinning face with sweat"], [["U+1F923"], "🤣", "rolling on the floor laughing"], [["U+1F602"], "😂", "face with tears of joy"], [["U+1F642"], "🙂", "slightly smiling face"], [["U+1F643"], "🙃", "upside-down face"], [["U+1F609"], "😉", "winking face"], [["U+1F60A"], "😊", "smiling face with smiling eyes"], [["U+1F607"], "😇", "smiling face with halo"]]], ["face-affection", [[["U+1F970"], "🥰", "smiling face with hearts"], [["U+1F60D"], "😍", "smiling face with heart-eyes"], [["U+1F929"], "🤩", "star-struck"], [["U+1F618"], "😘", "face blowing a kiss"], [["U+1F617"], "😗", "kissing face"], [["U+263A"], "☺", "smiling face"], [["U+1F61A"], "😚", "kissing face with closed eyes"], [["U+1F619"], "😙", "kissing face with smiling eyes"], [["U+1F972"], "🥲", "⊛ smiling face with tear"]]], ["face-tongue", [[["U+1F60B"], "😋", "face savoring food"], [["U+1F61B"], "😛", "face with tongue"], [["U+1F61C"], "😜", "winking face with tongue"], [["U+1F92A"], "🤪", "zany face"], [["U+1F61D"], "😝", "squinting face with tongue"], [["U+1F911"], "🤑", "money-mouth face"]]], ["face-hand", [[["U+1F917"], "🤗", "hugging face"], [["U+1F92D"], "🤭", "face with hand over mouth"], [["U+1F92B"], "🤫", "shushing face"], [["U+1F914"], "🤔", "thinking face"]]], ["face-neutral-skeptical", [[["U+1F910"], "🤐", "zipper-mouth face"], [["U+1F928"], "🤨", "face with raised eyebrow"], [["U+1F610"], "😐", "neutral face"], [["U+1F611"], "😑", "expressionless face"], [["U+1F636"], "😶", "face without mouth"], [["U+1F60F"], "😏", "smirking face"], [["U+1F612"], "😒", "unamused face"], [["U+1F644"], "🙄", "face with rolling eyes"], [["U+1F62C"], "😬", "grimacing face"], [["U+1F925"], "🤥", "lying face"]]], ["face-sleepy", [[["U+1F60C"], "😌", "relieved face"], [["U+1F614"], "😔", "pensive face"], [["U+1F62A"], "😪", "sleepy face"], [["U+1F924"], "🤤", "drooling face"], [["U+1F634"], "😴", "sleeping face"]]], ["face-unwell", [[["U+1F637"], "😷", "face with medical mask"], [["U+1F912"], "🤒", "face with thermometer"], [["U+1F915"], "🤕", "face with head-bandage"], [["U+1F922"], "🤢", "nauseated face"], [["U+1F92E"], "🤮", "face vomiting"], [["U+1F927"], "🤧", "sneezing face"], [["U+1F975"], "🥵", "hot face"], [["U+1F976"], "🥶", "cold face"], [["U+1F974"], "🥴", "woozy face"], [["U+1F635"], "😵", "dizzy face"], [["U+1F92F"], "🤯", "exploding head"]]], ["face-hat", [[["U+1F920"], "🤠", "cowboy hat face"], [["U+1F973"], "🥳", "partying face"], [["U+1F978"], "🥸", "⊛ disguised face"]]], ["face-glasses", [[["U+1F60E"], "😎", "smiling face with sunglasses"], [["U+1F913"], "🤓", "nerd face"], [["U+1F9D0"], "🧐", "face with monocle"]]], ["face-concerned", [[["U+1F615"], "😕", "confused face"], [["U+1F61F"], "😟", "worried face"], [["U+1F641"], "🙁", "slightly frowning face"], [["U+2639"], "☹", "frowning face"], [["U+1F62E"], "😮", "face with open mouth"], [["U+1F62F"], "😯", "hushed face"], [["U+1F632"], "😲", "astonished face"], [["U+1F633"], "😳", "flushed face"], [["U+1F97A"], "🥺", "pleading face"], [["U+1F626"], "😦", "frowning face with open mouth"], [["U+1F627"], "😧", "anguished face"], [["U+1F628"], "😨", "fearful face"], [["U+1F630"], "😰", "anxious face with sweat"], [["U+1F625"], "😥", "sad but relieved face"], [["U+1F622"], "😢", "crying face"], [["U+1F62D"], "😭", "loudly crying face"], [["U+1F631"], "😱", "face screaming in fear"], [["U+1F616"], "😖", "confounded face"], [["U+1F623"], "😣", "persevering face"], [["U+1F61E"], "😞", "disappointed face"], [["U+1F613"], "😓", "downcast face with sweat"], [["U+1F629"], "😩", "weary face"], [["U+1F62B"], "😫", "tired face"], [["U+1F971"], "🥱", "yawning face"]]], ["face-negative", [[["U+1F624"], "😤", "face with steam from nose"], [["U+1F621"], "😡", "pouting face"], [["U+1F620"], "😠", "angry face"], [["U+1F92C"], "🤬", "face with symbols on mouth"], [["U+1F608"], "😈", "smiling face with horns"], [["U+1F47F"], "👿", "angry face with horns"], [["U+1F480"], "💀", "skull"], [["U+2620"], "☠", "skull and crossbones"]]], ["face-costume", [[["U+1F4A9"], "💩", "pile of poo"], [["U+1F921"], "🤡", "clown face"], [["U+1F479"], "👹", "ogre"], [["U+1F47A"], "👺", "goblin"], [["U+1F47B"], "👻", "ghost"], [["U+1F47D"], "👽", "alien"], [["U+1F47E"], "👾", "alien monster"], [["U+1F916"], "🤖", "robot"]]], ["cat-face", [[["U+1F63A"], "😺", "grinning cat"], [["U+1F638"], "😸", "grinning cat with smiling eyes"], [["U+1F639"], "😹", "cat with tears of joy"], [["U+1F63B"], "😻", "smiling cat with heart-eyes"], [["U+1F63C"], "😼", "cat with wry smile"], [["U+1F63D"], "😽", "kissing cat"], [["U+1F640"], "🙀", "weary cat"], [["U+1F63F"], "😿", "crying cat"], [["U+1F63E"], "😾", "pouting cat"]]], ["monkey-face", [[["U+1F648"], "🙈", "see-no-evil monkey"], [["U+1F649"], "🙉", "hear-no-evil monkey"], [["U+1F64A"], "🙊", "speak-no-evil monkey"]]], ["emotion", [[["U+1F48B"], "💋", "kiss mark"], [["U+1F48C"], "💌", "love letter"], [["U+1F498"], "💘", "heart with arrow"], [["U+1F49D"], "💝", "heart with ribbon"], [["U+1F496"], "💖", "sparkling heart"], [["U+1F497"], "💗", "growing heart"], [["U+1F493"], "💓", "beating heart"], [["U+1F49E"], "💞", "revolving hearts"], [["U+1F495"], "💕", "two hearts"], [["U+1F49F"], "💟", "heart decoration"], [["U+2763"], "❣", "heart exclamation"], [["U+1F494"], "💔", "broken heart"], [["U+2764"], "❤", "red heart"], [["U+1F9E1"], "🧡", "orange heart"], [["U+1F49B"], "💛", "yellow heart"], [["U+1F49A"], "💚", "green heart"], [["U+1F499"], "💙", "blue heart"], [["U+1F49C"], "💜", "purple heart"], [["U+1F90E"], "🤎", "brown heart"], [["U+1F5A4"], "🖤", "black heart"], [["U+1F90D"], "🤍", "white heart"], [["U+1F4AF"], "💯", "hundred points"], [["U+1F4A2"], "💢", "anger symbol"], [["U+1F4A5"], "💥", "collision"], [["U+1F4AB"], "💫", "dizzy"], [["U+1F4A6"], "💦", "sweat droplets"], [["U+1F4A8"], "💨", "dashing away"], [["U+1F573"], "🕳", "hole"], [["U+1F4A3"], "💣", "bomb"], [["U+1F4AC"], "💬", "speech balloon"], [["U+1F441", "U+FE0F", "U+200D", "U+1F5E8", "U+FE0F"], "👁️‍🗨️", "eye in speech bubble"], [["U+1F5E8"], "🗨", "left speech bubble"], [["U+1F5EF"], "🗯", "right anger bubble"], [["U+1F4AD"], "💭", "thought balloon"], [["U+1F4A4"], "💤", "zzz"]]]]], ["People & Body", [["hand-fingers-open", [[["U+1F44B"], "👋", "waving hand"], [["U+1F91A"], "🤚", "raised back of hand"], [["U+1F590"], "🖐", "hand with fingers splayed"], [["U+270B"], "✋", "raised hand"], [["U+1F596"], "🖖", "vulcan salute"]]], ["hand-fingers-partial", [[["U+1F44C"], "👌", "OK hand"], [["U+1F90C"], "🤌", "⊛ pinched fingers"], [["U+1F90F"], "🤏", "pinching hand"], [["U+270C"], "✌", "victory hand"], [["U+1F91E"], "🤞", "crossed fingers"], [["U+1F91F"], "🤟", "love-you gesture"], [["U+1F918"], "🤘", "sign of the horns"], [["U+1F919"], "🤙", "call me hand"]]], ["hand-single-finger", [[["U+1F448"], "👈", "backhand index pointing left"], [["U+1F449"], "👉", "backhand index pointing right"], [["U+1F446"], "👆", "backhand index pointing up"], [["U+1F595"], "🖕", "middle finger"], [["U+1F447"], "👇", "backhand index pointing down"], [["U+261D"], "☝", "index pointing up"]]], ["hand-fingers-closed", [[["U+1F44D"], "👍", "thumbs up"], [["U+1F44E"], "👎", "thumbs down"], [["U+270A"], "✊", "raised fist"], [["U+1F44A"], "👊", "oncoming fist"], [["U+1F91B"], "🤛", "left-facing fist"], [["U+1F91C"], "🤜", "right-facing fist"]]], ["hands", [[["U+1F44F"], "👏", "clapping hands"], [["U+1F64C"], "🙌", "raising hands"], [["U+1F450"], "👐", "open hands"], [["U+1F932"], "🤲", "palms up together"], [["U+1F91D"], "🤝", "handshake"], [["U+1F64F"], "🙏", "folded hands"]]], ["hand-prop", [[["U+270D"], "✍", "writing hand"], [["U+1F485"], "💅", "nail polish"], [["U+1F933"], "🤳", "selfie"]]], ["body-parts", [[["U+1F4AA"], "💪", "flexed biceps"], [["U+1F9BE"], "🦾", "mechanical arm"], [["U+1F9BF"], "🦿", "mechanical leg"], [["U+1F9B5"], "🦵", "leg"], [["U+1F9B6"], "🦶", "foot"], [["U+1F442"], "👂", "ear"], [["U+1F9BB"], "🦻", "ear with hearing aid"], [["U+1F443"], "👃", "nose"], [["U+1F9E0"], "🧠", "brain"], [["U+1F9B7"], "🦷", "tooth"], [["U+1F9B4"], "🦴", "bone"], [["U+1F440"], "👀", "eyes"], [["U+1F441"], "👁", "eye"], [["U+1F445"], "👅", "tongue"], [["U+1F444"], "👄", "mouth"]]], ["person", [[["U+1F476"], "👶", "baby"], [["U+1F9D2"], "🧒", "child"], [["U+1F466"], "👦", "boy"], [["U+1F467"], "👧", "girl"], [["U+1F9D1"], "🧑", "person"], [["U+1F471"], "👱", "person: blond hair"], [["U+1F468"], "👨", "man"], [["U+1F9D4"], "🧔", "man: beard"], [["U+1F468", "U+200D", "U+1F9B0"], "👨‍🦰", "man: red hair"], [["U+1F468", "U+200D", "U+1F9B1"], "👨‍🦱", "man: curly hair"], [["U+1F468", "U+200D", "U+1F9B3"], "👨‍🦳", "man: white hair"], [["U+1F468", "U+200D", "U+1F9B2"], "👨‍🦲", "man: bald"], [["U+1F469"], "👩", "woman"], [["U+1F469", "U+200D", "U+1F9B0"], "👩‍🦰", "woman: red hair"], [["U+1F9D1", "U+200D", "U+1F9B0"], "🧑‍🦰", "person: red hair"], [["U+1F469", "U+200D", "U+1F9B1"], "👩‍🦱", "woman: curly hair"], [["U+1F9D1", "U+200D", "U+1F9B1"], "🧑‍🦱", "person: curly hair"], [["U+1F469", "U+200D", "U+1F9B3"], "👩‍🦳", "woman: white hair"], [["U+1F9D1", "U+200D", "U+1F9B3"], "🧑‍🦳", "person: white hair"], [["U+1F469", "U+200D", "U+1F9B2"], "👩‍🦲", "woman: bald"], [["U+1F9D1", "U+200D", "U+1F9B2"], "🧑‍🦲", "person: bald"], [["U+1F471", "U+200D", "U+2640", "U+FE0F"], "👱‍♀️", "woman: blond hair"], [["U+1F471", "U+200D", "U+2642", "U+FE0F"], "👱‍♂️", "man: blond hair"], [["U+1F9D3"], "🧓", "older person"], [["U+1F474"], "👴", "old man"], [["U+1F475"], "👵", "old woman"]]], ["person-gesture", [[["U+1F64D"], "🙍", "person frowning"], [["U+1F64D", "U+200D", "U+2642", "U+FE0F"], "🙍‍♂️", "man frowning"], [["U+1F64D", "U+200D", "U+2640", "U+FE0F"], "🙍‍♀️", "woman frowning"], [["U+1F64E"], "🙎", "person pouting"], [["U+1F64E", "U+200D", "U+2642", "U+FE0F"], "🙎‍♂️", "man pouting"], [["U+1F64E", "U+200D", "U+2640", "U+FE0F"], "🙎‍♀️", "woman pouting"], [["U+1F645"], "🙅", "person gesturing NO"], [["U+1F645", "U+200D", "U+2642", "U+FE0F"], "🙅‍♂️", "man gesturing NO"], [["U+1F645", "U+200D", "U+2640", "U+FE0F"], "🙅‍♀️", "woman gesturing NO"], [["U+1F646"], "🙆", "person gesturing OK"], [["U+1F646", "U+200D", "U+2642", "U+FE0F"], "🙆‍♂️", "man gesturing OK"], [["U+1F646", "U+200D", "U+2640", "U+FE0F"], "🙆‍♀️", "woman gesturing OK"], [["U+1F481"], "💁", "person tipping hand"], [["U+1F481", "U+200D", "U+2642", "U+FE0F"], "💁‍♂️", "man tipping hand"], [["U+1F481", "U+200D", "U+2640", "U+FE0F"], "💁‍♀️", "woman tipping hand"], [["U+1F64B"], "🙋", "person raising hand"], [["U+1F64B", "U+200D", "U+2642", "U+FE0F"], "🙋‍♂️", "man raising hand"], [["U+1F64B", "U+200D", "U+2640", "U+FE0F"], "🙋‍♀️", "woman raising hand"], [["U+1F9CF"], "🧏", "deaf person"], [["U+1F9CF", "U+200D", "U+2642", "U+FE0F"], "🧏‍♂️", "deaf man"], [["U+1F9CF", "U+200D", "U+2640", "U+FE0F"], "🧏‍♀️", "deaf woman"], [["U+1F647"], "🙇", "person bowing"], [["U+1F647", "U+200D", "U+2642", "U+FE0F"], "🙇‍♂️", "man bowing"], [["U+1F647", "U+200D", "U+2640", "U+FE0F"], "🙇‍♀️", "woman bowing"], [["U+1F926"], "🤦", "person facepalming"], [["U+1F926", "U+200D", "U+2642", "U+FE0F"], "🤦‍♂️", "man facepalming"], [["U+1F926", "U+200D", "U+2640", "U+FE0F"], "🤦‍♀️", "woman facepalming"], [["U+1F937"], "🤷", "person shrugging"], [["U+1F937", "U+200D", "U+2642", "U+FE0F"], "🤷‍♂️", "man shrugging"], [["U+1F937", "U+200D", "U+2640", "U+FE0F"], "🤷‍♀️", "woman shrugging"]]], ["person-role", [[["U+1F9D1", "U+200D", "U+2695", "U+FE0F"], "🧑‍⚕️", "health worker"], [["U+1F468", "U+200D", "U+2695", "U+FE0F"], "👨‍⚕️", "man health worker"], [["U+1F469", "U+200D", "U+2695", "U+FE0F"], "👩‍⚕️", "woman health worker"], [["U+1F9D1", "U+200D", "U+1F393"], "🧑‍🎓", "student"], [["U+1F468", "U+200D", "U+1F393"], "👨‍🎓", "man student"], [["U+1F469", "U+200D", "U+1F393"], "👩‍🎓", "woman student"], [["U+1F9D1", "U+200D", "U+1F3EB"], "🧑‍🏫", "teacher"], [["U+1F468", "U+200D", "U+1F3EB"], "👨‍🏫", "man teacher"], [["U+1F469", "U+200D", "U+1F3EB"], "👩‍🏫", "woman teacher"], [["U+1F9D1", "U+200D", "U+2696", "U+FE0F"], "🧑‍⚖️", "judge"], [["U+1F468", "U+200D", "U+2696", "U+FE0F"], "👨‍⚖️", "man judge"], [["U+1F469", "U+200D", "U+2696", "U+FE0F"], "👩‍⚖️", "woman judge"], [["U+1F9D1", "U+200D", "U+1F33E"], "🧑‍🌾", "farmer"], [["U+1F468", "U+200D", "U+1F33E"], "👨‍🌾", "man farmer"], [["U+1F469", "U+200D", "U+1F33E"], "👩‍🌾", "woman farmer"], [["U+1F9D1", "U+200D", "U+1F373"], "🧑‍🍳", "cook"], [["U+1F468", "U+200D", "U+1F373"], "👨‍🍳", "man cook"], [["U+1F469", "U+200D", "U+1F373"], "👩‍🍳", "woman cook"], [["U+1F9D1", "U+200D", "U+1F527"], "🧑‍🔧", "mechanic"], [["U+1F468", "U+200D", "U+1F527"], "👨‍🔧", "man mechanic"], [["U+1F469", "U+200D", "U+1F527"], "👩‍🔧", "woman mechanic"], [["U+1F9D1", "U+200D", "U+1F3ED"], "🧑‍🏭", "factory worker"], [["U+1F468", "U+200D", "U+1F3ED"], "👨‍🏭", "man factory worker"], [["U+1F469", "U+200D", "U+1F3ED"], "👩‍🏭", "woman factory worker"], [["U+1F9D1", "U+200D", "U+1F4BC"], "🧑‍💼", "office worker"], [["U+1F468", "U+200D", "U+1F4BC"], "👨‍💼", "man office worker"], [["U+1F469", "U+200D", "U+1F4BC"], "👩‍💼", "woman office worker"], [["U+1F9D1", "U+200D", "U+1F52C"], "🧑‍🔬", "scientist"], [["U+1F468", "U+200D", "U+1F52C"], "👨‍🔬", "man scientist"], [["U+1F469", "U+200D", "U+1F52C"], "👩‍🔬", "woman scientist"], [["U+1F9D1", "U+200D", "U+1F4BB"], "🧑‍💻", "technologist"], [["U+1F468", "U+200D", "U+1F4BB"], "👨‍💻", "man technologist"], [["U+1F469", "U+200D", "U+1F4BB"], "👩‍💻", "woman technologist"], [["U+1F9D1", "U+200D", "U+1F3A4"], "🧑‍🎤", "singer"], [["U+1F468", "U+200D", "U+1F3A4"], "👨‍🎤", "man singer"], [["U+1F469", "U+200D", "U+1F3A4"], "👩‍🎤", "woman singer"], [["U+1F9D1", "U+200D", "U+1F3A8"], "🧑‍🎨", "artist"], [["U+1F468", "U+200D", "U+1F3A8"], "👨‍🎨", "man artist"], [["U+1F469", "U+200D", "U+1F3A8"], "👩‍🎨", "woman artist"], [["U+1F9D1", "U+200D", "U+2708", "U+FE0F"], "🧑‍✈️", "pilot"], [["U+1F468", "U+200D", "U+2708", "U+FE0F"], "👨‍✈️", "man pilot"], [["U+1F469", "U+200D", "U+2708", "U+FE0F"], "👩‍✈️", "woman pilot"], [["U+1F9D1", "U+200D", "U+1F680"], "🧑‍🚀", "astronaut"], [["U+1F468", "U+200D", "U+1F680"], "👨‍🚀", "man astronaut"], [["U+1F469", "U+200D", "U+1F680"], "👩‍🚀", "woman astronaut"], [["U+1F9D1", "U+200D", "U+1F692"], "🧑‍🚒", "firefighter"], [["U+1F468", "U+200D", "U+1F692"], "👨‍🚒", "man firefighter"], [["U+1F469", "U+200D", "U+1F692"], "👩‍🚒", "woman firefighter"], [["U+1F46E"], "👮", "police officer"], [["U+1F46E", "U+200D", "U+2642", "U+FE0F"], "👮‍♂️", "man police officer"], [["U+1F46E", "U+200D", "U+2640", "U+FE0F"], "👮‍♀️", "woman police officer"], [["U+1F575"], "🕵", "detective"], [["U+1F575", "U+FE0F", "U+200D", "U+2642", "U+FE0F"], "🕵️‍♂️", "man detective"], [["U+1F575", "U+FE0F", "U+200D", "U+2640", "U+FE0F"], "🕵️‍♀️", "woman detective"], [["U+1F482"], "💂", "guard"], [["U+1F482", "U+200D", "U+2642", "U+FE0F"], "💂‍♂️", "man guard"], [["U+1F482", "U+200D", "U+2640", "U+FE0F"], "💂‍♀️", "woman guard"], [["U+1F977"], "🥷", "⊛ ninja"], [["U+1F477"], "👷", "construction worker"], [["U+1F477", "U+200D", "U+2642", "U+FE0F"], "👷‍♂️", "man construction worker"], [["U+1F477", "U+200D", "U+2640", "U+FE0F"], "👷‍♀️", "woman construction worker"], [["U+1F934"], "🤴", "prince"], [["U+1F478"], "👸", "princess"], [["U+1F473"], "👳", "person wearing turban"], [["U+1F473", "U+200D", "U+2642", "U+FE0F"], "👳‍♂️", "man wearing turban"], [["U+1F473", "U+200D", "U+2640", "U+FE0F"], "👳‍♀️", "woman wearing turban"], [["U+1F472"], "👲", "person with skullcap"], [["U+1F9D5"], "🧕", "woman with headscarf"], [["U+1F935"], "🤵", "person in tuxedo"], [["U+1F935", "U+200D", "U+2642", "U+FE0F"], "🤵‍♂️", "⊛ man in tuxedo"], [["U+1F935", "U+200D", "U+2640", "U+FE0F"], "🤵‍♀️", "⊛ woman in tuxedo"], [["U+1F470"], "👰", "person with veil"], [["U+1F930"], "🤰", "pregnant woman"], [["U+1F931"], "🤱", "breast-feeding"]]], ["person-fantasy", [[["U+1F47C"], "👼", "baby angel"], [["U+1F385"], "🎅", "Santa Claus"], [["U+1F936"], "🤶", "Mrs. Claus"], [["U+1F9B8"], "🦸", "superhero"], [["U+1F9B8", "U+200D", "U+2642", "U+FE0F"], "🦸‍♂️", "man superhero"], [["U+1F9B8", "U+200D", "U+2640", "U+FE0F"], "🦸‍♀️", "woman superhero"], [["U+1F9B9"], "🦹", "supervillain"], [["U+1F9B9", "U+200D", "U+2642", "U+FE0F"], "🦹‍♂️", "man supervillain"], [["U+1F9B9", "U+200D", "U+2640", "U+FE0F"], "🦹‍♀️", "woman supervillain"], [["U+1F9D9"], "🧙", "mage"], [["U+1F9D9", "U+200D", "U+2642", "U+FE0F"], "🧙‍♂️", "man mage"], [["U+1F9D9", "U+200D", "U+2640", "U+FE0F"], "🧙‍♀️", "woman mage"], [["U+1F9DA"], "🧚", "fairy"], [["U+1F9DA", "U+200D", "U+2642", "U+FE0F"], "🧚‍♂️", "man fairy"], [["U+1F9DA", "U+200D", "U+2640", "U+FE0F"], "🧚‍♀️", "woman fairy"], [["U+1F9DB"], "🧛", "vampire"], [["U+1F9DB", "U+200D", "U+2642", "U+FE0F"], "🧛‍♂️", "man vampire"], [["U+1F9DB", "U+200D", "U+2640", "U+FE0F"], "🧛‍♀️", "woman vampire"], [["U+1F9DC"], "🧜", "merperson"], [["U+1F9DC", "U+200D", "U+2642", "U+FE0F"], "🧜‍♂️", "merman"], [["U+1F9DC", "U+200D", "U+2640", "U+FE0F"], "🧜‍♀️", "mermaid"], [["U+1F9DD"], "🧝", "elf"], [["U+1F9DD", "U+200D", "U+2642", "U+FE0F"], "🧝‍♂️", "man elf"], [["U+1F9DD", "U+200D", "U+2640", "U+FE0F"], "🧝‍♀️", "woman elf"], [["U+1F9DE"], "🧞", "genie"], [["U+1F9DE", "U+200D", "U+2642", "U+FE0F"], "🧞‍♂️", "man genie"], [["U+1F9DE", "U+200D", "U+2640", "U+FE0F"], "🧞‍♀️", "woman genie"], [["U+1F9DF"], "🧟", "zombie"], [["U+1F9DF", "U+200D", "U+2642", "U+FE0F"], "🧟‍♂️", "man zombie"], [["U+1F9DF", "U+200D", "U+2640", "U+FE0F"], "🧟‍♀️", "woman zombie"]]], ["person-activity", [[["U+1F486"], "💆", "person getting massage"], [["U+1F486", "U+200D", "U+2642", "U+FE0F"], "💆‍♂️", "man getting massage"], [["U+1F486", "U+200D", "U+2640", "U+FE0F"], "💆‍♀️", "woman getting massage"], [["U+1F487"], "💇", "person getting haircut"], [["U+1F487", "U+200D", "U+2642", "U+FE0F"], "💇‍♂️", "man getting haircut"], [["U+1F487", "U+200D", "U+2640", "U+FE0F"], "💇‍♀️", "woman getting haircut"], [["U+1F6B6"], "🚶", "person walking"], [["U+1F6B6", "U+200D", "U+2642", "U+FE0F"], "🚶‍♂️", "man walking"], [["U+1F6B6", "U+200D", "U+2640", "U+FE0F"], "🚶‍♀️", "woman walking"], [["U+1F9CD"], "🧍", "person standing"], [["U+1F9CD", "U+200D", "U+2642", "U+FE0F"], "🧍‍♂️", "man standing"], [["U+1F9CD", "U+200D", "U+2640", "U+FE0F"], "🧍‍♀️", "woman standing"], [["U+1F9CE"], "🧎", "person kneeling"], [["U+1F9CE", "U+200D", "U+2642", "U+FE0F"], "🧎‍♂️", "man kneeling"], [["U+1F9CE", "U+200D", "U+2640", "U+FE0F"], "🧎‍♀️", "woman kneeling"], [["U+1F9D1", "U+200D", "U+1F9AF"], "🧑‍🦯", "person with white cane"], [["U+1F468", "U+200D", "U+1F9AF"], "👨‍🦯", "man with white cane"], [["U+1F469", "U+200D", "U+1F9AF"], "👩‍🦯", "woman with white cane"], [["U+1F9D1", "U+200D", "U+1F9BC"], "🧑‍🦼", "person in motorized wheelchair"], [["U+1F468", "U+200D", "U+1F9BC"], "👨‍🦼", "man in motorized wheelchair"], [["U+1F469", "U+200D", "U+1F9BC"], "👩‍🦼", "woman in motorized wheelchair"], [["U+1F9D1", "U+200D", "U+1F9BD"], "🧑‍🦽", "person in manual wheelchair"], [["U+1F468", "U+200D", "U+1F9BD"], "👨‍🦽", "man in manual wheelchair"], [["U+1F469", "U+200D", "U+1F9BD"], "👩‍🦽", "woman in manual wheelchair"], [["U+1F3C3"], "🏃", "person running"], [["U+1F3C3", "U+200D", "U+2642", "U+FE0F"], "🏃‍♂️", "man running"], [["U+1F3C3", "U+200D", "U+2640", "U+FE0F"], "🏃‍♀️", "woman running"], [["U+1F483"], "💃", "woman dancing"], [["U+1F57A"], "🕺", "man dancing"], [["U+1F574"], "🕴", "person in suit levitating"], [["U+1F46F"], "👯", "people with bunny ears"], [["U+1F46F", "U+200D", "U+2642", "U+FE0F"], "👯‍♂️", "men with bunny ears"], [["U+1F46F", "U+200D", "U+2640", "U+FE0F"], "👯‍♀️", "women with bunny ears"], [["U+1F9D6"], "🧖", "person in steamy room"], [["U+1F9D6", "U+200D", "U+2642", "U+FE0F"], "🧖‍♂️", "man in steamy room"], [["U+1F9D6", "U+200D", "U+2640", "U+FE0F"], "🧖‍♀️", "woman in steamy room"], [["U+1F9D7"], "🧗", "person climbing"], [["U+1F9D7", "U+200D", "U+2642", "U+FE0F"], "🧗‍♂️", "man climbing"], [["U+1F9D7", "U+200D", "U+2640", "U+FE0F"], "🧗‍♀️", "woman climbing"]]], ["person-sport", [[["U+1F93A"], "🤺", "person fencing"], [["U+1F3C7"], "🏇", "horse racing"], [["U+26F7"], "⛷", "skier"], [["U+1F3C2"], "🏂", "snowboarder"], [["U+1F3CC"], "🏌", "person golfing"], [["U+1F3CC", "U+FE0F", "U+200D", "U+2642", "U+FE0F"], "🏌️‍♂️", "man golfing"], [["U+1F3CC", "U+FE0F", "U+200D", "U+2640", "U+FE0F"], "🏌️‍♀️", "woman golfing"], [["U+1F3C4"], "🏄", "person surfing"], [["U+1F3C4", "U+200D", "U+2642", "U+FE0F"], "🏄‍♂️", "man surfing"], [["U+1F3C4", "U+200D", "U+2640", "U+FE0F"], "🏄‍♀️", "woman surfing"], [["U+1F6A3"], "🚣", "person rowing boat"], [["U+1F6A3", "U+200D", "U+2642", "U+FE0F"], "🚣‍♂️", "man rowing boat"], [["U+1F6A3", "U+200D", "U+2640", "U+FE0F"], "🚣‍♀️", "woman rowing boat"], [["U+1F3CA"], "🏊", "person swimming"], [["U+1F3CA", "U+200D", "U+2642", "U+FE0F"], "🏊‍♂️", "man swimming"], [["U+1F3CA", "U+200D", "U+2640", "U+FE0F"], "🏊‍♀️", "woman swimming"], [["U+26F9"], "⛹", "person bouncing ball"], [["U+26F9", "U+FE0F", "U+200D", "U+2642", "U+FE0F"], "⛹️‍♂️", "man bouncing ball"], [["U+26F9", "U+FE0F", "U+200D", "U+2640", "U+FE0F"], "⛹️‍♀️", "woman bouncing ball"], [["U+1F3CB"], "🏋", "person lifting weights"], [["U+1F3CB", "U+FE0F", "U+200D", "U+2642", "U+FE0F"], "🏋️‍♂️", "man lifting weights"], [["U+1F3CB", "U+FE0F", "U+200D", "U+2640", "U+FE0F"], "🏋️‍♀️", "woman lifting weights"], [["U+1F6B4"], "🚴", "person biking"], [["U+1F6B4", "U+200D", "U+2642", "U+FE0F"], "🚴‍♂️", "man biking"], [["U+1F6B4", "U+200D", "U+2640", "U+FE0F"], "🚴‍♀️", "woman biking"], [["U+1F6B5"], "🚵", "person mountain biking"], [["U+1F6B5", "U+200D", "U+2642", "U+FE0F"], "🚵‍♂️", "man mountain biking"], [["U+1F6B5", "U+200D", "U+2640", "U+FE0F"], "🚵‍♀️", "woman mountain biking"], [["U+1F938"], "🤸", "person cartwheeling"], [["U+1F938", "U+200D", "U+2642", "U+FE0F"], "🤸‍♂️", "man cartwheeling"], [["U+1F938", "U+200D", "U+2640", "U+FE0F"], "🤸‍♀️", "woman cartwheeling"], [["U+1F93C"], "🤼", "people wrestling"], [["U+1F93C", "U+200D", "U+2642", "U+FE0F"], "🤼‍♂️", "men wrestling"], [["U+1F93C", "U+200D", "U+2640", "U+FE0F"], "🤼‍♀️", "women wrestling"], [["U+1F93D"], "🤽", "person playing water polo"], [["U+1F93D", "U+200D", "U+2642", "U+FE0F"], "🤽‍♂️", "man playing water polo"], [["U+1F93D", "U+200D", "U+2640", "U+FE0F"], "🤽‍♀️", "woman playing water polo"], [["U+1F93E"], "🤾", "person playing handball"], [["U+1F93E", "U+200D", "U+2642", "U+FE0F"], "🤾‍♂️", "man playing handball"], [["U+1F93E", "U+200D", "U+2640", "U+FE0F"], "🤾‍♀️", "woman playing handball"], [["U+1F939"], "🤹", "person juggling"], [["U+1F939", "U+200D", "U+2642", "U+FE0F"], "🤹‍♂️", "man juggling"], [["U+1F939", "U+200D", "U+2640", "U+FE0F"], "🤹‍♀️", "woman juggling"]]], ["person-resting", [[["U+1F9D8"], "🧘", "person in lotus position"], [["U+1F9D8", "U+200D", "U+2642", "U+FE0F"], "🧘‍♂️", "man in lotus position"], [["U+1F9D8", "U+200D", "U+2640", "U+FE0F"], "🧘‍♀️", "woman in lotus position"], [["U+1F6C0"], "🛀", "person taking bath"], [["U+1F6CC"], "🛌", "person in bed"]]], ["family", [[["U+1F9D1", "U+200D", "U+1F91D", "U+200D", "U+1F9D1"], "🧑‍🤝‍🧑", "people holding hands"], [["U+1F46D"], "👭", "women holding hands"], [["U+1F46B"], "👫", "woman and man holding hands"], [["U+1F46C"], "👬", "men holding hands"], [["U+1F48F"], "💏", "kiss"], [["U+1F469", "U+200D", "U+2764", "U+FE0F", "U+200D", "U+1F48B", "U+200D", "U+1F468"], "👩‍❤️‍💋‍👨", "kiss: woman, man"], [["U+1F468", "U+200D", "U+2764", "U+FE0F", "U+200D", "U+1F48B", "U+200D", "U+1F468"], "👨‍❤️‍💋‍👨", "kiss: man, man"], [["U+1F469", "U+200D", "U+2764", "U+FE0F", "U+200D", "U+1F48B", "U+200D", "U+1F469"], "👩‍❤️‍💋‍👩", "kiss: woman, woman"], [["U+1F491"], "💑", "couple with heart"], [["U+1F469", "U+200D", "U+2764", "U+FE0F", "U+200D", "U+1F468"], "👩‍❤️‍👨", "couple with heart: woman, man"], [["U+1F468", "U+200D", "U+2764", "U+FE0F", "U+200D", "U+1F468"], "👨‍❤️‍👨", "couple with heart: man, man"], [["U+1F469", "U+200D", "U+2764", "U+FE0F", "U+200D", "U+1F469"], "👩‍❤️‍👩", "couple with heart: woman, woman"], [["U+1F46A"], "👪", "family"], [["U+1F468", "U+200D", "U+1F469", "U+200D", "U+1F466"], "👨‍👩‍👦", "family: man, woman, boy"], [["U+1F468", "U+200D", "U+1F469", "U+200D", "U+1F467"], "👨‍👩‍👧", "family: man, woman, girl"], [["U+1F468", "U+200D", "U+1F469", "U+200D", "U+1F467", "U+200D", "U+1F466"], "👨‍👩‍👧‍👦", "family: man, woman, girl, boy"], [["U+1F468", "U+200D", "U+1F469", "U+200D", "U+1F466", "U+200D", "U+1F466"], "👨‍👩‍👦‍👦", "family: man, woman, boy, boy"], [["U+1F468", "U+200D", "U+1F469", "U+200D", "U+1F467", "U+200D", "U+1F467"], "👨‍👩‍👧‍👧", "family: man, woman, girl, girl"], [["U+1F468", "U+200D", "U+1F468", "U+200D", "U+1F466"], "👨‍👨‍👦", "family: man, man, boy"], [["U+1F468", "U+200D", "U+1F468", "U+200D", "U+1F467"], "👨‍👨‍👧", "family: man, man, girl"], [["U+1F468", "U+200D", "U+1F468", "U+200D", "U+1F467", "U+200D", "U+1F466"], "👨‍👨‍👧‍👦", "family: man, man, girl, boy"], [["U+1F468", "U+200D", "U+1F468", "U+200D", "U+1F466", "U+200D", "U+1F466"], "👨‍👨‍👦‍👦", "family: man, man, boy, boy"], [["U+1F468", "U+200D", "U+1F468", "U+200D", "U+1F467", "U+200D", "U+1F467"], "👨‍👨‍👧‍👧", "family: man, man, girl, girl"], [["U+1F469", "U+200D", "U+1F469", "U+200D", "U+1F466"], "👩‍👩‍👦", "family: woman, woman, boy"], [["U+1F469", "U+200D", "U+1F469", "U+200D", "U+1F467"], "👩‍👩‍👧", "family: woman, woman, girl"], [["U+1F469", "U+200D", "U+1F469", "U+200D", "U+1F467", "U+200D", "U+1F466"], "👩‍👩‍👧‍👦", "family: woman, woman, girl, boy"], [["U+1F469", "U+200D", "U+1F469", "U+200D", "U+1F466", "U+200D", "U+1F466"], "👩‍👩‍👦‍👦", "family: woman, woman, boy, boy"], [["U+1F469", "U+200D", "U+1F469", "U+200D", "U+1F467", "U+200D", "U+1F467"], "👩‍👩‍👧‍👧", "family: woman, woman, girl, girl"], [["U+1F468", "U+200D", "U+1F466"], "👨‍👦", "family: man, boy"], [["U+1F468", "U+200D", "U+1F466", "U+200D", "U+1F466"], "👨‍👦‍👦", "family: man, boy, boy"], [["U+1F468", "U+200D", "U+1F467"], "👨‍👧", "family: man, girl"], [["U+1F468", "U+200D", "U+1F467", "U+200D", "U+1F466"], "👨‍👧‍👦", "family: man, girl, boy"], [["U+1F468", "U+200D", "U+1F467", "U+200D", "U+1F467"], "👨‍👧‍👧", "family: man, girl, girl"], [["U+1F469", "U+200D", "U+1F466"], "👩‍👦", "family: woman, boy"], [["U+1F469", "U+200D", "U+1F466", "U+200D", "U+1F466"], "👩‍👦‍👦", "family: woman, boy, boy"], [["U+1F469", "U+200D", "U+1F467"], "👩‍👧", "family: woman, girl"], [["U+1F469", "U+200D", "U+1F467", "U+200D", "U+1F466"], "👩‍👧‍👦", "family: woman, girl, boy"], [["U+1F469", "U+200D", "U+1F467", "U+200D", "U+1F467"], "👩‍👧‍👧", "family: woman, girl, girl"]]], ["person-symbol", [[["U+1F5E3"], "🗣", "speaking head"], [["U+1F464"], "👤", "bust in silhouette"], [["U+1F465"], "👥", "busts in silhouette"], [["U+1FAC2"], "🫂", "⊛ people hugging"], [["U+1F463"], "👣", "footprints"]]]]], ["Component", [["hair-style", [[["U+1F9B0"], "🦰", "red hair"], [["U+1F9B1"], "🦱", "curly hair"], [["U+1F9B3"], "🦳", "white hair"], [["U+1F9B2"], "🦲", "bald"]]]]], ["Animals & Nature", [["animal-mammal", [[["U+1F435"], "🐵", "monkey face"], [["U+1F412"], "🐒", "monkey"], [["U+1F98D"], "🦍", "gorilla"], [["U+1F9A7"], "🦧", "orangutan"], [["U+1F436"], "🐶", "dog face"], [["U+1F415"], "🐕", "dog"], [["U+1F9AE"], "🦮", "guide dog"], [["U+1F415", "U+200D", "U+1F9BA"], "🐕‍🦺", "service dog"], [["U+1F429"], "🐩", "poodle"], [["U+1F43A"], "🐺", "wolf"], [["U+1F98A"], "🦊", "fox"], [["U+1F99D"], "🦝", "raccoon"], [["U+1F431"], "🐱", "cat face"], [["U+1F408"], "🐈", "cat"], [["U+1F981"], "🦁", "lion"], [["U+1F42F"], "🐯", "tiger face"], [["U+1F405"], "🐅", "tiger"], [["U+1F406"], "🐆", "leopard"], [["U+1F434"], "🐴", "horse face"], [["U+1F40E"], "🐎", "horse"], [["U+1F984"], "🦄", "unicorn"], [["U+1F993"], "🦓", "zebra"], [["U+1F98C"], "🦌", "deer"], [["U+1F42E"], "🐮", "cow face"], [["U+1F402"], "🐂", "ox"], [["U+1F403"], "🐃", "water buffalo"], [["U+1F404"], "🐄", "cow"], [["U+1F437"], "🐷", "pig face"], [["U+1F416"], "🐖", "pig"], [["U+1F417"], "🐗", "boar"], [["U+1F43D"], "🐽", "pig nose"], [["U+1F40F"], "🐏", "ram"], [["U+1F411"], "🐑", "ewe"], [["U+1F410"], "🐐", "goat"], [["U+1F42A"], "🐪", "camel"], [["U+1F42B"], "🐫", "two-hump camel"], [["U+1F999"], "🦙", "llama"], [["U+1F992"], "🦒", "giraffe"], [["U+1F418"], "🐘", "elephant"], [["U+1F98F"], "🦏", "rhinoceros"], [["U+1F99B"], "🦛", "hippopotamus"], [["U+1F42D"], "🐭", "mouse face"], [["U+1F401"], "🐁", "mouse"], [["U+1F400"], "🐀", "rat"], [["U+1F439"], "🐹", "hamster"], [["U+1F430"], "🐰", "rabbit face"], [["U+1F407"], "🐇", "rabbit"], [["U+1F43F"], "🐿", "chipmunk"], [["U+1F994"], "🦔", "hedgehog"], [["U+1F987"], "🦇", "bat"], [["U+1F43B"], "🐻", "bear"], [["U+1F43B", "U+200D", "U+2744", "U+FE0F"], "🐻‍❄️", "⊛ polar bear"], [["U+1F428"], "🐨", "koala"], [["U+1F43C"], "🐼", "panda"], [["U+1F9A5"], "🦥", "sloth"], [["U+1F9A6"], "🦦", "otter"], [["U+1F9A8"], "🦨", "skunk"], [["U+1F998"], "🦘", "kangaroo"], [["U+1F9A1"], "🦡", "badger"], [["U+1F43E"], "🐾", "paw prints"]]], ["animal-bird", [[["U+1F983"], "🦃", "turkey"], [["U+1F414"], "🐔", "chicken"], [["U+1F413"], "🐓", "rooster"], [["U+1F423"], "🐣", "hatching chick"], [["U+1F424"], "🐤", "baby chick"], [["U+1F425"], "🐥", "front-facing baby chick"], [["U+1F426"], "🐦", "bird"], [["U+1F427"], "🐧", "penguin"], [["U+1F54A"], "🕊", "dove"], [["U+1F985"], "🦅", "eagle"], [["U+1F986"], "🦆", "duck"], [["U+1F9A2"], "🦢", "swan"], [["U+1F989"], "🦉", "owl"], [["U+1FAB6"], "🪶", "⊛ feather"], [["U+1F9A9"], "🦩", "flamingo"], [["U+1F99A"], "🦚", "peacock"], [["U+1F99C"], "🦜", "parrot"]]], ["animal-amphibian", [[["U+1F438"], "🐸", "frog"]]], ["animal-reptile", [[["U+1F40A"], "🐊", "crocodile"], [["U+1F422"], "🐢", "turtle"], [["U+1F98E"], "🦎", "lizard"], [["U+1F40D"], "🐍", "snake"], [["U+1F432"], "🐲", "dragon face"], [["U+1F409"], "🐉", "dragon"], [["U+1F995"], "🦕", "sauropod"], [["U+1F996"], "🦖", "T-Rex"]]], ["animal-marine", [[["U+1F433"], "🐳", "spouting whale"], [["U+1F40B"], "🐋", "whale"], [["U+1F42C"], "🐬", "dolphin"], [["U+1F41F"], "🐟", "fish"], [["U+1F420"], "🐠", "tropical fish"], [["U+1F421"], "🐡", "blowfish"], [["U+1F988"], "🦈", "shark"], [["U+1F419"], "🐙", "octopus"], [["U+1F41A"], "🐚", "spiral shell"]]], ["animal-bug", [[["U+1F40C"], "🐌", "snail"], [["U+1F98B"], "🦋", "butterfly"], [["U+1F41B"], "🐛", "bug"], [["U+1F41C"], "🐜", "ant"], [["U+1F41D"], "🐝", "honeybee"], [["U+1F41E"], "🐞", "lady beetle"], [["U+1F997"], "🦗", "cricket"], [["U+1F577"], "🕷", "spider"], [["U+1F578"], "🕸", "spider web"], [["U+1F982"], "🦂", "scorpion"], [["U+1F99F"], "🦟", "mosquito"], [["U+1F9A0"], "🦠", "microbe"]]], ["plant-flower", [[["U+1F490"], "💐", "bouquet"], [["U+1F338"], "🌸", "cherry blossom"], [["U+1F4AE"], "💮", "white flower"], [["U+1F3F5"], "🏵", "rosette"], [["U+1F339"], "🌹", "rose"], [["U+1F940"], "🥀", "wilted flower"], [["U+1F33A"], "🌺", "hibiscus"], [["U+1F33B"], "🌻", "sunflower"], [["U+1F33C"], "🌼", "blossom"], [["U+1F337"], "🌷", "tulip"]]], ["plant-other", [[["U+1F331"], "🌱", "seedling"], [["U+1FAB4"], "🪴", "⊛ potted plant"], [["U+1F332"], "🌲", "evergreen tree"], [["U+1F333"], "🌳", "deciduous tree"], [["U+1F334"], "🌴", "palm tree"], [["U+1F335"], "🌵", "cactus"], [["U+1F33E"], "🌾", "sheaf of rice"], [["U+1F33F"], "🌿", "herb"], [["U+2618"], "☘", "shamrock"], [["U+1F340"], "🍀", "four leaf clover"], [["U+1F341"], "🍁", "maple leaf"], [["U+1F342"], "🍂", "fallen leaf"], [["U+1F343"], "🍃", "leaf fluttering in wind"]]]]], ["Food & Drink", [["food-fruit", [[["U+1F347"], "🍇", "grapes"], [["U+1F348"], "🍈", "melon"], [["U+1F349"], "🍉", "watermelon"], [["U+1F34A"], "🍊", "tangerine"], [["U+1F34B"], "🍋", "lemon"], [["U+1F34C"], "🍌", "banana"], [["U+1F34D"], "🍍", "pineapple"], [["U+1F96D"], "🥭", "mango"], [["U+1F34E"], "🍎", "red apple"], [["U+1F34F"], "🍏", "green apple"], [["U+1F350"], "🍐", "pear"], [["U+1F351"], "🍑", "peach"], [["U+1F352"], "🍒", "cherries"], [["U+1F353"], "🍓", "strawberry"], [["U+1FAD0"], "🫐", "⊛ blueberries"], [["U+1F95D"], "🥝", "kiwi fruit"], [["U+1F345"], "🍅", "tomato"], [["U+1FAD2"], "🫒", "⊛ olive"], [["U+1F965"], "🥥", "coconut"]]], ["food-vegetable", [[["U+1F951"], "🥑", "avocado"], [["U+1F346"], "🍆", "eggplant"], [["U+1F954"], "🥔", "potato"], [["U+1F955"], "🥕", "carrot"], [["U+1F33D"], "🌽", "ear of corn"], [["U+1F336"], "🌶", "hot pepper"], [["U+1F952"], "🥒", "cucumber"], [["U+1F96C"], "🥬", "leafy green"], [["U+1F966"], "🥦", "broccoli"], [["U+1F9C4"], "🧄", "garlic"], [["U+1F9C5"], "🧅", "onion"], [["U+1F344"], "🍄", "mushroom"], [["U+1F95C"], "🥜", "peanuts"], [["U+1F330"], "🌰", "chestnut"]]], ["food-prepared", [[["U+1F35E"], "🍞", "bread"], [["U+1F950"], "🥐", "croissant"], [["U+1F956"], "🥖", "baguette bread"], [["U+1FAD3"], "🫓", "⊛ flatbread"], [["U+1F968"], "🥨", "pretzel"], [["U+1F96F"], "🥯", "bagel"], [["U+1F95E"], "🥞", "pancakes"], [["U+1F9C7"], "🧇", "waffle"], [["U+1F9C0"], "🧀", "cheese wedge"], [["U+1F356"], "🍖", "meat on bone"], [["U+1F357"], "🍗", "poultry leg"], [["U+1F969"], "🥩", "cut of meat"], [["U+1F953"], "🥓", "bacon"], [["U+1F354"], "🍔", "hamburger"], [["U+1F35F"], "🍟", "french fries"], [["U+1F355"], "🍕", "pizza"], [["U+1F32D"], "🌭", "hot dog"], [["U+1F96A"], "🥪", "sandwich"], [["U+1F32E"], "🌮", "taco"], [["U+1F32F"], "🌯", "burrito"], [["U+1FAD4"], "🫔", "⊛ tamale"], [["U+1F959"], "🥙", "stuffed flatbread"], [["U+1F9C6"], "🧆", "falafel"], [["U+1F95A"], "🥚", "egg"], [["U+1F373"], "🍳", "cooking"], [["U+1F958"], "🥘", "shallow pan of food"], [["U+1F372"], "🍲", "pot of food"], [["U+1FAD5"], "🫕", "⊛ fondue"], [["U+1F963"], "🥣", "bowl with spoon"], [["U+1F957"], "🥗", "green salad"], [["U+1F37F"], "🍿", "popcorn"], [["U+1F9C8"], "🧈", "butter"], [["U+1F9C2"], "🧂", "salt"], [["U+1F96B"], "🥫", "canned food"]]], ["food-asian", [[["U+1F371"], "🍱", "bento box"], [["U+1F358"], "🍘", "rice cracker"], [["U+1F359"], "🍙", "rice ball"], [["U+1F35A"], "🍚", "cooked rice"], [["U+1F35B"], "🍛", "curry rice"], [["U+1F35C"], "🍜", "steaming bowl"], [["U+1F35D"], "🍝", "spaghetti"], [["U+1F360"], "🍠", "roasted sweet potato"], [["U+1F362"], "🍢", "oden"], [["U+1F363"], "🍣", "sushi"], [["U+1F364"], "🍤", "fried shrimp"], [["U+1F365"], "🍥", "fish cake with swirl"], [["U+1F96E"], "🥮", "moon cake"], [["U+1F361"], "🍡", "dango"], [["U+1F95F"], "🥟", "dumpling"], [["U+1F960"], "🥠", "fortune cookie"], [["U+1F961"], "🥡", "takeout box"]]], ["food-marine", [[["U+1F980"], "🦀", "crab"], [["U+1F99E"], "🦞", "lobster"], [["U+1F990"], "🦐", "shrimp"], [["U+1F991"], "🦑", "squid"], [["U+1F9AA"], "🦪", "oyster"]]], ["food-sweet", [[["U+1F366"], "🍦", "soft ice cream"], [["U+1F367"], "🍧", "shaved ice"], [["U+1F368"], "🍨", "ice cream"], [["U+1F369"], "🍩", "doughnut"], [["U+1F36A"], "🍪", "cookie"], [["U+1F382"], "🎂", "birthday cake"], [["U+1F370"], "🍰", "shortcake"], [["U+1F9C1"], "🧁", "cupcake"], [["U+1F967"], "🥧", "pie"], [["U+1F36B"], "🍫", "chocolate bar"], [["U+1F36C"], "🍬", "candy"], [["U+1F36D"], "🍭", "lollipop"], [["U+1F36E"], "🍮", "custard"], [["U+1F36F"], "🍯", "honey pot"]]], ["drink", [[["U+1F37C"], "🍼", "baby bottle"], [["U+1F95B"], "🥛", "glass of milk"], [["U+2615"], "☕", "hot beverage"], [["U+1F375"], "🍵", "teacup without handle"], [["U+1F376"], "🍶", "sake"], [["U+1F37E"], "🍾", "bottle with popping cork"], [["U+1F377"], "🍷", "wine glass"], [["U+1F378"], "🍸", "cocktail glass"], [["U+1F379"], "🍹", "tropical drink"], [["U+1F37A"], "🍺", "beer mug"], [["U+1F37B"], "🍻", "clinking beer mugs"], [["U+1F942"], "🥂", "clinking glasses"], [["U+1F943"], "🥃", "tumbler glass"], [["U+1F964"], "🥤", "cup with straw"], [["U+1F9CB"], "🧋", "⊛ bubble tea"], [["U+1F9C3"], "🧃", "beverage box"], [["U+1F9C9"], "🧉", "mate"], [["U+1F9CA"], "🧊", "ice"]]], ["dishware", [[["U+1F962"], "🥢", "chopsticks"], [["U+1F37D"], "🍽", "fork and knife with plate"], [["U+1F374"], "🍴", "fork and knife"], [["U+1F944"], "🥄", "spoon"], [["U+1F52A"], "🔪", "kitchen knife"], [["U+1F3FA"], "🏺", "amphora"]]]]], ["Travel & Places", [["place-map", [[["U+1F30D"], "🌍", "globe showing Europe-Africa"], [["U+1F30E"], "🌎", "globe showing Americas"], [["U+1F30F"], "🌏", "globe showing Asia-Australia"], [["U+1F310"], "🌐", "globe with meridians"], [["U+1F5FA"], "🗺", "world map"], [["U+1F5FE"], "🗾", "map of Japan"], [["U+1F9ED"], "🧭", "compass"]]], ["place-geographic", [[["U+1F3D4"], "🏔", "snow-capped mountain"], [["U+26F0"], "⛰", "mountain"], [["U+1F30B"], "🌋", "volcano"], [["U+1F5FB"], "🗻", "mount fuji"], [["U+1F3D5"], "🏕", "camping"], [["U+1F3D6"], "🏖", "beach with umbrella"], [["U+1F3DC"], "🏜", "desert"], [["U+1F3DD"], "🏝", "desert island"], [["U+1F3DE"], "🏞", "national park"]]], ["place-building", [[["U+1F3DF"], "🏟", "stadium"], [["U+1F3DB"], "🏛", "classical building"], [["U+1F3D7"], "🏗", "building construction"], [["U+1F9F1"], "🧱", "brick"], [["U+1FAA8"], "🪨", "⊛ rock"], [["U+1FAB5"], "🪵", "⊛ wood"], [["U+1F3D8"], "🏘", "houses"], [["U+1F3DA"], "🏚", "derelict house"], [["U+1F3E0"], "🏠", "house"], [["U+1F3E1"], "🏡", "house with garden"], [["U+1F3E2"], "🏢", "office building"], [["U+1F3E3"], "🏣", "Japanese post office"], [["U+1F3E4"], "🏤", "post office"], [["U+1F3E5"], "🏥", "hospital"], [["U+1F3E6"], "🏦", "bank"], [["U+1F3E8"], "🏨", "hotel"], [["U+1F3E9"], "🏩", "love hotel"], [["U+1F3EA"], "🏪", "convenience store"], [["U+1F3EB"], "🏫", "school"], [["U+1F3EC"], "🏬", "department store"], [["U+1F3ED"], "🏭", "factory"], [["U+1F3EF"], "🏯", "Japanese castle"], [["U+1F3F0"], "🏰", "castle"], [["U+1F492"], "💒", "wedding"], [["U+1F5FC"], "🗼", "Tokyo tower"], [["U+1F5FD"], "🗽", "Statue of Liberty"]]], ["place-religious", [[["U+26EA"], "⛪", "church"], [["U+1F54C"], "🕌", "mosque"], [["U+1F6D5"], "🛕", "hindu temple"], [["U+1F54D"], "🕍", "synagogue"], [["U+26E9"], "⛩", "shinto shrine"], [["U+1F54B"], "🕋", "kaaba"]]], ["place-other", [[["U+26F2"], "⛲", "fountain"], [["U+26FA"], "⛺", "tent"], [["U+1F301"], "🌁", "foggy"], [["U+1F303"], "🌃", "night with stars"], [["U+1F3D9"], "🏙", "cityscape"], [["U+1F304"], "🌄", "sunrise over mountains"], [["U+1F305"], "🌅", "sunrise"], [["U+1F306"], "🌆", "cityscape at dusk"], [["U+1F307"], "🌇", "sunset"], [["U+1F309"], "🌉", "bridge at night"], [["U+2668"], "♨", "hot springs"], [["U+1F3A0"], "🎠", "carousel horse"], [["U+1F3A1"], "🎡", "ferris wheel"], [["U+1F3A2"], "🎢", "roller coaster"], [["U+1F488"], "💈", "barber pole"], [["U+1F3AA"], "🎪", "circus tent"]]], ["transport-ground", [[["U+1F682"], "🚂", "locomotive"], [["U+1F683"], "🚃", "railway car"], [["U+1F684"], "🚄", "high-speed train"], [["U+1F685"], "🚅", "bullet train"], [["U+1F686"], "🚆", "train"], [["U+1F687"], "🚇", "metro"], [["U+1F688"], "🚈", "light rail"], [["U+1F689"], "🚉", "station"], [["U+1F68A"], "🚊", "tram"], [["U+1F69D"], "🚝", "monorail"], [["U+1F69E"], "🚞", "mountain railway"], [["U+1F68B"], "🚋", "tram car"], [["U+1F68C"], "🚌", "bus"], [["U+1F68D"], "🚍", "oncoming bus"], [["U+1F68E"], "🚎", "trolleybus"], [["U+1F690"], "🚐", "minibus"], [["U+1F691"], "🚑", "ambulance"], [["U+1F692"], "🚒", "fire engine"], [["U+1F693"], "🚓", "police car"], [["U+1F694"], "🚔", "oncoming police car"], [["U+1F695"], "🚕", "taxi"], [["U+1F696"], "🚖", "oncoming taxi"], [["U+1F697"], "🚗", "automobile"], [["U+1F698"], "🚘", "oncoming automobile"], [["U+1F699"], "🚙", "sport utility vehicle"], [["U+1F69A"], "🚚", "delivery truck"], [["U+1F69B"], "🚛", "articulated lorry"], [["U+1F69C"], "🚜", "tractor"], [["U+1F3CE"], "🏎", "racing car"], [["U+1F3CD"], "🏍", "motorcycle"], [["U+1F6F5"], "🛵", "motor scooter"], [["U+1F9BD"], "🦽", "manual wheelchair"], [["U+1F9BC"], "🦼", "motorized wheelchair"], [["U+1F6FA"], "🛺", "auto rickshaw"], [["U+1F6B2"], "🚲", "bicycle"], [["U+1F6F4"], "🛴", "kick scooter"], [["U+1F6F9"], "🛹", "skateboard"], [["U+1F6FC"], "🛼", "⊛ roller skate"], [["U+1F68F"], "🚏", "bus stop"], [["U+1F6E3"], "🛣", "motorway"], [["U+1F6E4"], "🛤", "railway track"], [["U+1F6E2"], "🛢", "oil drum"], [["U+26FD"], "⛽", "fuel pump"], [["U+1F6A8"], "🚨", "police car light"], [["U+1F6A5"], "🚥", "horizontal traffic light"], [["U+1F6A6"], "🚦", "vertical traffic light"], [["U+1F6D1"], "🛑", "stop sign"], [["U+1F6A7"], "🚧", "construction"]]], ["transport-water", [[["U+2693"], "⚓", "anchor"], [["U+26F5"], "⛵", "sailboat"], [["U+1F6F6"], "🛶", "canoe"], [["U+1F6A4"], "🚤", "speedboat"], [["U+1F6F3"], "🛳", "passenger ship"], [["U+26F4"], "⛴", "ferry"], [["U+1F6E5"], "🛥", "motor boat"], [["U+1F6A2"], "🚢", "ship"]]], ["transport-air", [[["U+2708"], "✈", "airplane"], [["U+1F6E9"], "🛩", "small airplane"], [["U+1F6EB"], "🛫", "airplane departure"], [["U+1F6EC"], "🛬", "airplane arrival"], [["U+1FA82"], "🪂", "parachute"], [["U+1F4BA"], "💺", "seat"], [["U+1F681"], "🚁", "helicopter"], [["U+1F69F"], "🚟", "suspension railway"], [["U+1F6A0"], "🚠", "mountain cableway"], [["U+1F6A1"], "🚡", "aerial tramway"], [["U+1F6F0"], "🛰", "satellite"], [["U+1F680"], "🚀", "rocket"], [["U+1F6F8"], "🛸", "flying saucer"]]], ["hotel", [[["U+1F6CE"], "🛎", "bellhop bell"], [["U+1F9F3"], "🧳", "luggage"]]], ["time", [[["U+231B"], "⌛", "hourglass done"], [["U+23F3"], "⏳", "hourglass not done"], [["U+231A"], "⌚", "watch"], [["U+23F0"], "⏰", "alarm clock"], [["U+23F1"], "⏱", "stopwatch"], [["U+23F2"], "⏲", "timer clock"], [["U+1F570"], "🕰", "mantelpiece clock"], [["U+1F55B"], "🕛", "twelve o’clock"], [["U+1F567"], "🕧", "twelve-thirty"], [["U+1F550"], "🕐", "one o’clock"], [["U+1F55C"], "🕜", "one-thirty"], [["U+1F551"], "🕑", "two o’clock"], [["U+1F55D"], "🕝", "two-thirty"], [["U+1F552"], "🕒", "three o’clock"], [["U+1F55E"], "🕞", "three-thirty"], [["U+1F553"], "🕓", "four o’clock"], [["U+1F55F"], "🕟", "four-thirty"], [["U+1F554"], "🕔", "five o’clock"], [["U+1F560"], "🕠", "five-thirty"], [["U+1F555"], "🕕", "six o’clock"], [["U+1F561"], "🕡", "six-thirty"], [["U+1F556"], "🕖", "seven o’clock"], [["U+1F562"], "🕢", "seven-thirty"], [["U+1F557"], "🕗", "eight o’clock"], [["U+1F563"], "🕣", "eight-thirty"], [["U+1F558"], "🕘", "nine o’clock"], [["U+1F564"], "🕤", "nine-thirty"], [["U+1F559"], "🕙", "ten o’clock"], [["U+1F565"], "🕥", "ten-thirty"], [["U+1F55A"], "🕚", "eleven o’clock"], [["U+1F566"], "🕦", "eleven-thirty"]]], ["sky & weather", [[["U+1F311"], "🌑", "new moon"], [["U+1F312"], "🌒", "waxing crescent moon"], [["U+1F313"], "🌓", "first quarter moon"], [["U+1F314"], "🌔", "waxing gibbous moon"], [["U+1F315"], "🌕", "full moon"], [["U+1F316"], "🌖", "waning gibbous moon"], [["U+1F317"], "🌗", "last quarter moon"], [["U+1F318"], "🌘", "waning crescent moon"], [["U+1F319"], "🌙", "crescent moon"], [["U+1F31A"], "🌚", "new moon face"], [["U+1F31B"], "🌛", "first quarter moon face"], [["U+1F31C"], "🌜", "last quarter moon face"], [["U+1F321"], "🌡", "thermometer"], [["U+2600"], "☀", "sun"], [["U+1F31D"], "🌝", "full moon face"], [["U+1F31E"], "🌞", "sun with face"], [["U+1FA90"], "🪐", "ringed planet"], [["U+2B50"], "⭐", "star"], [["U+1F31F"], "🌟", "glowing star"], [["U+1F320"], "🌠", "shooting star"], [["U+1F30C"], "🌌", "milky way"], [["U+2601"], "☁", "cloud"], [["U+26C5"], "⛅", "sun behind cloud"], [["U+26C8"], "⛈", "cloud with lightning and rain"], [["U+1F324"], "🌤", "sun behind small cloud"], [["U+1F325"], "🌥", "sun behind large cloud"], [["U+1F326"], "🌦", "sun behind rain cloud"], [["U+1F327"], "🌧", "cloud with rain"], [["U+1F328"], "🌨", "cloud with snow"], [["U+1F329"], "🌩", "cloud with lightning"], [["U+1F32A"], "🌪", "tornado"], [["U+1F32B"], "🌫", "fog"], [["U+1F32C"], "🌬", "wind face"], [["U+1F300"], "🌀", "cyclone"], [["U+1F308"], "🌈", "rainbow"], [["U+1F302"], "🌂", "closed umbrella"], [["U+2602"], "☂", "umbrella"], [["U+2614"], "☔", "umbrella with rain drops"], [["U+26F1"], "⛱", "umbrella on ground"], [["U+26A1"], "⚡", "high voltage"], [["U+2744"], "❄", "snowflake"], [["U+2603"], "☃", "snowman"], [["U+26C4"], "⛄", "snowman without snow"], [["U+2604"], "☄", "comet"], [["U+1F525"], "🔥", "fire"], [["U+1F4A7"], "💧", "droplet"], [["U+1F30A"], "🌊", "water wave"]]]]], ["Activities", [["event", [[["U+1F383"], "🎃", "jack-o-lantern"], [["U+1F384"], "🎄", "Christmas tree"], [["U+1F386"], "🎆", "fireworks"], [["U+1F387"], "🎇", "sparkler"], [["U+1F9E8"], "🧨", "firecracker"], [["U+2728"], "✨", "sparkles"], [["U+1F388"], "🎈", "balloon"], [["U+1F389"], "🎉", "party popper"], [["U+1F38A"], "🎊", "confetti ball"], [["U+1F38B"], "🎋", "tanabata tree"], [["U+1F38D"], "🎍", "pine decoration"], [["U+1F38E"], "🎎", "Japanese dolls"], [["U+1F38F"], "🎏", "carp streamer"], [["U+1F390"], "🎐", "wind chime"], [["U+1F391"], "🎑", "moon viewing ceremony"], [["U+1F9E7"], "🧧", "red envelope"], [["U+1F380"], "🎀", "ribbon"], [["U+1F381"], "🎁", "wrapped gift"], [["U+1F397"], "🎗", "reminder ribbon"], [["U+1F39F"], "🎟", "admission tickets"], [["U+1F3AB"], "🎫", "ticket"]]], ["award-medal", [[["U+1F396"], "🎖", "military medal"], [["U+1F3C6"], "🏆", "trophy"], [["U+1F3C5"], "🏅", "sports medal"], [["U+1F947"], "🥇", "1st place medal"], [["U+1F948"], "🥈", "2nd place medal"], [["U+1F949"], "🥉", "3rd place medal"]]], ["sport", [[["U+26BD"], "⚽", "soccer ball"], [["U+26BE"], "⚾", "baseball"], [["U+1F94E"], "🥎", "softball"], [["U+1F3C0"], "🏀", "basketball"], [["U+1F3D0"], "🏐", "volleyball"], [["U+1F3C8"], "🏈", "american football"], [["U+1F3C9"], "🏉", "rugby football"], [["U+1F3BE"], "🎾", "tennis"], [["U+1F94F"], "🥏", "flying disc"], [["U+1F3B3"], "🎳", "bowling"], [["U+1F3CF"], "🏏", "cricket game"], [["U+1F3D1"], "🏑", "field hockey"], [["U+1F3D2"], "🏒", "ice hockey"], [["U+1F94D"], "🥍", "lacrosse"], [["U+1F3D3"], "🏓", "ping pong"], [["U+1F3F8"], "🏸", "badminton"], [["U+1F94A"], "🥊", "boxing glove"], [["U+1F94B"], "🥋", "martial arts uniform"], [["U+1F945"], "🥅", "goal net"], [["U+26F3"], "⛳", "flag in hole"], [["U+26F8"], "⛸", "ice skate"], [["U+1F3A3"], "🎣", "fishing pole"], [["U+1F93F"], "🤿", "diving mask"], [["U+1F3BD"], "🎽", "running shirt"], [["U+1F3BF"], "🎿", "skis"], [["U+1F6F7"], "🛷", "sled"], [["U+1F94C"], "🥌", "curling stone"]]], ["game", [[["U+1F3AF"], "🎯", "direct hit"], [["U+1FA80"], "🪀", "yo-yo"], [["U+1FA81"], "🪁", "kite"], [["U+1F3B1"], "🎱", "pool 8 ball"], [["U+1F52E"], "🔮", "crystal ball"], [["U+1FA84"], "🪄", "⊛ magic wand"], [["U+1F9FF"], "🧿", "nazar amulet"], [["U+1F3AE"], "🎮", "video game"], [["U+1F579"], "🕹", "joystick"], [["U+1F3B0"], "🎰", "slot machine"], [["U+1F3B2"], "🎲", "game die"], [["U+1F9E9"], "🧩", "puzzle piece"], [["U+1F9F8"], "🧸", "teddy bear"], [["U+1FA85"], "🪅", "⊛ piñata"], [["U+1FA86"], "🪆", "⊛ nesting dolls"], [["U+2660"], "♠", "spade suit"], [["U+2665"], "♥", "heart suit"], [["U+2666"], "♦", "diamond suit"], [["U+2663"], "♣", "club suit"], [["U+265F"], "♟", "chess pawn"], [["U+1F0CF"], "🃏", "joker"], [["U+1F004"], "🀄", "mahjong red dragon"], [["U+1F3B4"], "🎴", "flower playing cards"]]], ["arts & crafts", [[["U+1F3AD"], "🎭", "performing arts"], [["U+1F5BC"], "🖼", "framed picture"], [["U+1F3A8"], "🎨", "artist palette"], [["U+1F9F5"], "🧵", "thread"], [["U+1FAA1"], "🪡", "⊛ sewing needle"], [["U+1F9F6"], "🧶", "yarn"], [["U+1FAA2"], "🪢", "⊛ knot"]]]]], ["Objects", [["clothing", [[["U+1F453"], "👓", "glasses"], [["U+1F576"], "🕶", "sunglasses"], [["U+1F97D"], "🥽", "goggles"], [["U+1F97C"], "🥼", "lab coat"], [["U+1F9BA"], "🦺", "safety vest"], [["U+1F454"], "👔", "necktie"], [["U+1F455"], "👕", "t-shirt"], [["U+1F456"], "👖", "jeans"], [["U+1F9E3"], "🧣", "scarf"], [["U+1F9E4"], "🧤", "gloves"], [["U+1F9E5"], "🧥", "coat"], [["U+1F9E6"], "🧦", "socks"], [["U+1F457"], "👗", "dress"], [["U+1F458"], "👘", "kimono"], [["U+1F97B"], "🥻", "sari"], [["U+1FA71"], "🩱", "one-piece swimsuit"], [["U+1FA72"], "🩲", "briefs"], [["U+1FA73"], "🩳", "shorts"], [["U+1F459"], "👙", "bikini"], [["U+1F45A"], "👚", "woman’s clothes"], [["U+1F45B"], "👛", "purse"], [["U+1F45C"], "👜", "handbag"], [["U+1F45D"], "👝", "clutch bag"], [["U+1F6CD"], "🛍", "shopping bags"], [["U+1F392"], "🎒", "backpack"], [["U+1FA74"], "🩴", "⊛ thong sandal"], [["U+1F45E"], "👞", "man’s shoe"], [["U+1F45F"], "👟", "running shoe"], [["U+1F97E"], "🥾", "hiking boot"], [["U+1F97F"], "🥿", "flat shoe"], [["U+1F460"], "👠", "high-heeled shoe"], [["U+1F461"], "👡", "woman’s sandal"], [["U+1FA70"], "🩰", "ballet shoes"], [["U+1F462"], "👢", "woman’s boot"], [["U+1F451"], "👑", "crown"], [["U+1F452"], "👒", "woman’s hat"], [["U+1F3A9"], "🎩", "top hat"], [["U+1F393"], "🎓", "graduation cap"], [["U+1F9E2"], "🧢", "billed cap"], [["U+1FA96"], "🪖", "⊛ military helmet"], [["U+26D1"], "⛑", "rescue worker’s helmet"], [["U+1F4FF"], "📿", "prayer beads"], [["U+1F484"], "💄", "lipstick"], [["U+1F48D"], "💍", "ring"], [["U+1F48E"], "💎", "gem stone"]]], ["sound", [[["U+1F507"], "🔇", "muted speaker"], [["U+1F508"], "🔈", "speaker low volume"], [["U+1F509"], "🔉", "speaker medium volume"], [["U+1F50A"], "🔊", "speaker high volume"], [["U+1F4E2"], "📢", "loudspeaker"], [["U+1F4E3"], "📣", "megaphone"], [["U+1F4EF"], "📯", "postal horn"], [["U+1F514"], "🔔", "bell"], [["U+1F515"], "🔕", "bell with slash"]]], ["music", [[["U+1F3BC"], "🎼", "musical score"], [["U+1F3B5"], "🎵", "musical note"], [["U+1F3B6"], "🎶", "musical notes"], [["U+1F399"], "🎙", "studio microphone"], [["U+1F39A"], "🎚", "level slider"], [["U+1F39B"], "🎛", "control knobs"], [["U+1F3A4"], "🎤", "microphone"], [["U+1F3A7"], "🎧", "headphone"], [["U+1F4FB"], "📻", "radio"]]], ["musical-instrument", [[["U+1F3B7"], "🎷", "saxophone"], [["U+1FA97"], "🪗", "⊛ accordion"], [["U+1F3B8"], "🎸", "guitar"], [["U+1F3B9"], "🎹", "musical keyboard"], [["U+1F3BA"], "🎺", "trumpet"], [["U+1F3BB"], "🎻", "violin"], [["U+1FA95"], "🪕", "banjo"], [["U+1F941"], "🥁", "drum"], [["U+1FA98"], "🪘", "⊛ long drum"]]], ["phone", [[["U+1F4F1"], "📱", "mobile phone"], [["U+1F4F2"], "📲", "mobile phone with arrow"], [["U+260E"], "☎", "telephone"], [["U+1F4DE"], "📞", "telephone receiver"], [["U+1F4DF"], "📟", "pager"], [["U+1F4E0"], "📠", "fax machine"]]], ["computer", [[["U+1F50B"], "🔋", "battery"], [["U+1F50C"], "🔌", "electric plug"], [["U+1F4BB"], "💻", "laptop"], [["U+1F5A5"], "🖥", "desktop computer"], [["U+1F5A8"], "🖨", "printer"], [["U+2328"], "⌨", "keyboard"], [["U+1F5B1"], "🖱", "computer mouse"], [["U+1F5B2"], "🖲", "trackball"], [["U+1F4BD"], "💽", "computer disk"], [["U+1F4BE"], "💾", "floppy disk"], [["U+1F4BF"], "💿", "optical disk"], [["U+1F4C0"], "📀", "dvd"], [["U+1F9EE"], "🧮", "abacus"]]], ["light & video", [[["U+1F3A5"], "🎥", "movie camera"], [["U+1F39E"], "🎞", "film frames"], [["U+1F4FD"], "📽", "film projector"], [["U+1F3AC"], "🎬", "clapper board"], [["U+1F4FA"], "📺", "television"], [["U+1F4F7"], "📷", "camera"], [["U+1F4F8"], "📸", "camera with flash"], [["U+1F4F9"], "📹", "video camera"], [["U+1F4FC"], "📼", "videocassette"], [["U+1F50D"], "🔍", "magnifying glass tilted left"], [["U+1F50E"], "🔎", "magnifying glass tilted right"], [["U+1F56F"], "🕯", "candle"], [["U+1F4A1"], "💡", "light bulb"], [["U+1F526"], "🔦", "flashlight"], [["U+1F3EE"], "🏮", "red paper lantern"], [["U+1FA94"], "🪔", "diya lamp"]]], ["book-paper", [[["U+1F4D4"], "📔", "notebook with decorative cover"], [["U+1F4D5"], "📕", "closed book"], [["U+1F4D6"], "📖", "open book"], [["U+1F4D7"], "📗", "green book"], [["U+1F4D8"], "📘", "blue book"], [["U+1F4D9"], "📙", "orange book"], [["U+1F4DA"], "📚", "books"], [["U+1F4D3"], "📓", "notebook"], [["U+1F4D2"], "📒", "ledger"], [["U+1F4C3"], "📃", "page with curl"], [["U+1F4DC"], "📜", "scroll"], [["U+1F4C4"], "📄", "page facing up"], [["U+1F4F0"], "📰", "newspaper"], [["U+1F5DE"], "🗞", "rolled-up newspaper"], [["U+1F4D1"], "📑", "bookmark tabs"], [["U+1F516"], "🔖", "bookmark"], [["U+1F3F7"], "🏷", "label"]]], ["money", [[["U+1F4B0"], "💰", "money bag"], [["U+1FA99"], "🪙", "⊛ coin"], [["U+1F4B4"], "💴", "yen banknote"], [["U+1F4B5"], "💵", "dollar banknote"], [["U+1F4B6"], "💶", "euro banknote"], [["U+1F4B7"], "💷", "pound banknote"], [["U+1F4B8"], "💸", "money with wings"], [["U+1F4B3"], "💳", "credit card"], [["U+1F9FE"], "🧾", "receipt"], [["U+1F4B9"], "💹", "chart increasing with yen"]]], ["mail", [[["U+2709"], "✉", "envelope"], [["U+1F4E7"], "📧", "e-mail"], [["U+1F4E8"], "📨", "incoming envelope"], [["U+1F4E9"], "📩", "envelope with arrow"], [["U+1F4E4"], "📤", "outbox tray"], [["U+1F4E5"], "📥", "inbox tray"], [["U+1F4E6"], "📦", "package"], [["U+1F4EB"], "📫", "closed mailbox with raised flag"], [["U+1F4EA"], "📪", "closed mailbox with lowered flag"], [["U+1F4EC"], "📬", "open mailbox with raised flag"], [["U+1F4ED"], "📭", "open mailbox with lowered flag"], [["U+1F4EE"], "📮", "postbox"], [["U+1F5F3"], "🗳", "ballot box with ballot"]]], ["writing", [[["U+270F"], "✏", "pencil"], [["U+2712"], "✒", "black nib"], [["U+1F58B"], "🖋", "fountain pen"], [["U+1F58A"], "🖊", "pen"], [["U+1F58C"], "🖌", "paintbrush"], [["U+1F58D"], "🖍", "crayon"], [["U+1F4DD"], "📝", "memo"]]], ["office", [[["U+1F4BC"], "💼", "briefcase"], [["U+1F4C1"], "📁", "file folder"], [["U+1F4C2"], "📂", "open file folder"], [["U+1F5C2"], "🗂", "card index dividers"], [["U+1F4C5"], "📅", "calendar"], [["U+1F4C6"], "📆", "tear-off calendar"], [["U+1F5D2"], "🗒", "spiral notepad"], [["U+1F5D3"], "🗓", "spiral calendar"], [["U+1F4C7"], "📇", "card index"], [["U+1F4C8"], "📈", "chart increasing"], [["U+1F4C9"], "📉", "chart decreasing"], [["U+1F4CA"], "📊", "bar chart"], [["U+1F4CB"], "📋", "clipboard"], [["U+1F4CC"], "📌", "pushpin"], [["U+1F4CD"], "📍", "round pushpin"], [["U+1F4CE"], "📎", "paperclip"], [["U+1F587"], "🖇", "linked paperclips"], [["U+1F4CF"], "📏", "straight ruler"], [["U+1F4D0"], "📐", "triangular ruler"], [["U+2702"], "✂", "scissors"], [["U+1F5C3"], "🗃", "card file box"], [["U+1F5C4"], "🗄", "file cabinet"], [["U+1F5D1"], "🗑", "wastebasket"]]], ["lock", [[["U+1F512"], "🔒", "locked"], [["U+1F513"], "🔓", "unlocked"], [["U+1F50F"], "🔏", "locked with pen"], [["U+1F510"], "🔐", "locked with key"], [["U+1F511"], "🔑", "key"], [["U+1F5DD"], "🗝", "old key"]]], ["tool", [[["U+1F528"], "🔨", "hammer"], [["U+1FA93"], "🪓", "axe"], [["U+26CF"], "⛏", "pick"], [["U+2692"], "⚒", "hammer and pick"], [["U+1F6E0"], "🛠", "hammer and wrench"], [["U+1F5E1"], "🗡", "dagger"], [["U+2694"], "⚔", "crossed swords"], [["U+1F52B"], "🔫", "pistol"], [["U+1FA83"], "🪃", "⊛ boomerang"], [["U+1F3F9"], "🏹", "bow and arrow"], [["U+1F6E1"], "🛡", "shield"], [["U+1F527"], "🔧", "wrench"], [["U+1FA9B"], "🪛", "⊛ screwdriver"], [["U+1F529"], "🔩", "nut and bolt"], [["U+2699"], "⚙", "gear"], [["U+1F5DC"], "🗜", "clamp"], [["U+2696"], "⚖", "balance scale"], [["U+1F9AF"], "🦯", "white cane"], [["U+1F517"], "🔗", "link"], [["U+26D3"], "⛓", "chains"], [["U+1FA9D"], "🪝", "⊛ hook"], [["U+1F9F0"], "🧰", "toolbox"], [["U+1F9F2"], "🧲", "magnet"], [["U+1FA9C"], "🪜", "⊛ ladder"]]], ["science", [[["U+2697"], "⚗", "alembic"], [["U+1F9EA"], "🧪", "test tube"], [["U+1F9EB"], "🧫", "petri dish"], [["U+1F9EC"], "🧬", "dna"], [["U+1F52C"], "🔬", "microscope"], [["U+1F52D"], "🔭", "telescope"], [["U+1F4E1"], "📡", "satellite antenna"]]], ["medical", [[["U+1F489"], "💉", "syringe"], [["U+1FA78"], "🩸", "drop of blood"], [["U+1F48A"], "💊", "pill"], [["U+1FA79"], "🩹", "adhesive bandage"], [["U+1FA7A"], "🩺", "stethoscope"]]], ["household", [[["U+1F6AA"], "🚪", "door"], [["U+1F6D7"], "🛗", "⊛ elevator"], [["U+1F6CF"], "🛏", "bed"], [["U+1F6CB"], "🛋", "couch and lamp"], [["U+1FA91"], "🪑", "chair"], [["U+1F6BD"], "🚽", "toilet"], [["U+1FAA0"], "🪠", "⊛ plunger"], [["U+1F6BF"], "🚿", "shower"], [["U+1F6C1"], "🛁", "bathtub"], [["U+1FA92"], "🪒", "razor"], [["U+1F9F4"], "🧴", "lotion bottle"], [["U+1F9F7"], "🧷", "safety pin"], [["U+1F9F9"], "🧹", "broom"], [["U+1F9FA"], "🧺", "basket"], [["U+1F9FB"], "🧻", "roll of paper"], [["U+1FAA3"], "🪣", "⊛ bucket"], [["U+1F9FC"], "🧼", "soap"], [["U+1FAA5"], "🪥", "⊛ toothbrush"], [["U+1F9FD"], "🧽", "sponge"], [["U+1F9EF"], "🧯", "fire extinguisher"], [["U+1F6D2"], "🛒", "shopping cart"]]], ["other-object", [[["U+1F6AC"], "🚬", "cigarette"], [["U+26B0"], "⚰", "coffin"], [["U+26B1"], "⚱", "funeral urn"], [["U+1F5FF"], "🗿", "moai"], [["U+1FAA7"], "🪧", "⊛ placard"]]]]], ["Symbols", [["transport-sign", [[["U+1F3E7"], "🏧", "ATM sign"], [["U+1F6AE"], "🚮", "litter in bin sign"], [["U+1F6B0"], "🚰", "potable water"], [["U+267F"], "♿", "wheelchair symbol"], [["U+1F6B9"], "🚹", "men’s room"], [["U+1F6BA"], "🚺", "women’s room"], [["U+1F6BB"], "🚻", "restroom"], [["U+1F6BC"], "🚼", "baby symbol"], [["U+1F6BE"], "🚾", "water closet"], [["U+1F6C2"], "🛂", "passport control"], [["U+1F6C3"], "🛃", "customs"], [["U+1F6C4"], "🛄", "baggage claim"], [["U+1F6C5"], "🛅", "left luggage"]]], ["warning", [[["U+26A0"], "⚠", "warning"], [["U+1F6B8"], "🚸", "children crossing"], [["U+26D4"], "⛔", "no entry"], [["U+1F6AB"], "🚫", "prohibited"], [["U+1F6B3"], "🚳", "no bicycles"], [["U+1F6AD"], "🚭", "no smoking"], [["U+1F6AF"], "🚯", "no littering"], [["U+1F6B1"], "🚱", "non-potable water"], [["U+1F6B7"], "🚷", "no pedestrians"], [["U+1F4F5"], "📵", "no mobile phones"], [["U+1F51E"], "🔞", "no one under eighteen"], [["U+2622"], "☢", "radioactive"], [["U+2623"], "☣", "biohazard"]]], ["arrow", [[["U+2B06"], "⬆", "up arrow"], [["U+2197"], "↗", "up-right arrow"], [["U+27A1"], "➡", "right arrow"], [["U+2198"], "↘", "down-right arrow"], [["U+2B07"], "⬇", "down arrow"], [["U+2199"], "↙", "down-left arrow"], [["U+2B05"], "⬅", "left arrow"], [["U+2196"], "↖", "up-left arrow"], [["U+2195"], "↕", "up-down arrow"], [["U+2194"], "↔", "left-right arrow"], [["U+21A9"], "↩", "right arrow curving left"], [["U+21AA"], "↪", "left arrow curving right"], [["U+2934"], "⤴", "right arrow curving up"], [["U+2935"], "⤵", "right arrow curving down"], [["U+1F503"], "🔃", "clockwise vertical arrows"], [["U+1F504"], "🔄", "counterclockwise arrows button"], [["U+1F519"], "🔙", "BACK arrow"], [["U+1F51A"], "🔚", "END arrow"], [["U+1F51B"], "🔛", "ON! arrow"], [["U+1F51C"], "🔜", "SOON arrow"], [["U+1F51D"], "🔝", "TOP arrow"]]], ["religion", [[["U+1F6D0"], "🛐", "place of worship"], [["U+269B"], "⚛", "atom symbol"], [["U+1F549"], "🕉", "om"], [["U+2721"], "✡", "star of David"], [["U+2638"], "☸", "wheel of dharma"], [["U+262F"], "☯", "yin yang"], [["U+271D"], "✝", "latin cross"], [["U+2626"], "☦", "orthodox cross"], [["U+262A"], "☪", "star and crescent"], [["U+262E"], "☮", "peace symbol"], [["U+1F54E"], "🕎", "menorah"], [["U+1F52F"], "🔯", "dotted six-pointed star"]]], ["zodiac", [[["U+2648"], "♈", "Aries"], [["U+2649"], "♉", "Taurus"], [["U+264A"], "♊", "Gemini"], [["U+264B"], "♋", "Cancer"], [["U+264C"], "♌", "Leo"], [["U+264D"], "♍", "Virgo"], [["U+264E"], "♎", "Libra"], [["U+264F"], "♏", "Scorpio"], [["U+2650"], "♐", "Sagittarius"], [["U+2651"], "♑", "Capricorn"], [["U+2652"], "♒", "Aquarius"], [["U+2653"], "♓", "Pisces"], [["U+26CE"], "⛎", "Ophiuchus"]]], ["av-symbol", [[["U+1F500"], "🔀", "shuffle tracks button"], [["U+1F501"], "🔁", "repeat button"], [["U+1F502"], "🔂", "repeat single button"], [["U+25B6"], "▶", "play button"], [["U+23E9"], "⏩", "fast-forward button"], [["U+23ED"], "⏭", "next track button"], [["U+23EF"], "⏯", "play or pause button"], [["U+25C0"], "◀", "reverse button"], [["U+23EA"], "⏪", "fast reverse button"], [["U+23EE"], "⏮", "last track button"], [["U+1F53C"], "🔼", "upwards button"], [["U+23EB"], "⏫", "fast up button"], [["U+1F53D"], "🔽", "downwards button"], [["U+23EC"], "⏬", "fast down button"], [["U+23F8"], "⏸", "pause button"], [["U+23F9"], "⏹", "stop button"], [["U+23FA"], "⏺", "record button"], [["U+23CF"], "⏏", "eject button"], [["U+1F3A6"], "🎦", "cinema"], [["U+1F505"], "🔅", "dim button"], [["U+1F506"], "🔆", "bright button"], [["U+1F4F6"], "📶", "antenna bars"], [["U+1F4F3"], "📳", "vibration mode"], [["U+1F4F4"], "📴", "mobile phone off"]]], ["gender", [[["U+2640"], "♀", "female sign"], [["U+2642"], "♂", "male sign"], [["U+26A7"], "⚧", "⊛ transgender symbol"]]], ["math", [[["U+2716"], "✖", "multiply"], [["U+2795"], "➕", "plus"], [["U+2796"], "➖", "minus"], [["U+2797"], "➗", "divide"], [["U+267E"], "♾", "infinity"]]], ["punctuation", [[["U+203C"], "‼", "double exclamation mark"], [["U+2049"], "⁉", "exclamation question mark"], [["U+2753"], "❓", "question mark"], [["U+2754"], "❔", "white question mark"], [["U+2755"], "❕", "white exclamation mark"], [["U+2757"], "❗", "exclamation mark"], [["U+3030"], "〰", "wavy dash"]]], ["currency", [[["U+1F4B1"], "💱", "currency exchange"], [["U+1F4B2"], "💲", "heavy dollar sign"]]], ["other-symbol", [[["U+2695"], "⚕", "medical symbol"], [["U+267B"], "♻", "recycling symbol"], [["U+269C"], "⚜", "fleur-de-lis"], [["U+1F531"], "🔱", "trident emblem"], [["U+1F4DB"], "📛", "name badge"], [["U+1F530"], "🔰", "Japanese symbol for beginner"], [["U+2B55"], "⭕", "hollow red circle"], [["U+2705"], "✅", "check mark button"], [["U+2611"], "☑", "check box with check"], [["U+2714"], "✔", "check mark"], [["U+274C"], "❌", "cross mark"], [["U+274E"], "❎", "cross mark button"], [["U+27B0"], "➰", "curly loop"], [["U+27BF"], "➿", "double curly loop"], [["U+303D"], "〽", "part alternation mark"], [["U+2733"], "✳", "eight-spoked asterisk"], [["U+2734"], "✴", "eight-pointed star"], [["U+2747"], "❇", "sparkle"], [["U+00A9"], "©", "copyright"], [["U+00AE"], "®", "registered"], [["U+2122"], "™", "trade mark"]]], ["keycap", [[["U+0023", "U+FE0F", "U+20E3"], "#️⃣", "keycap: #"], [["U+002A", "U+FE0F", "U+20E3"], "*️⃣", "keycap: *"], [["U+0030", "U+FE0F", "U+20E3"], "0️⃣", "keycap: 0"], [["U+0031", "U+FE0F", "U+20E3"], "1️⃣", "keycap: 1"], [["U+0032", "U+FE0F", "U+20E3"], "2️⃣", "keycap: 2"], [["U+0033", "U+FE0F", "U+20E3"], "3️⃣", "keycap: 3"], [["U+0034", "U+FE0F", "U+20E3"], "4️⃣", "keycap: 4"], [["U+0035", "U+FE0F", "U+20E3"], "5️⃣", "keycap: 5"], [["U+0036", "U+FE0F", "U+20E3"], "6️⃣", "keycap: 6"], [["U+0037", "U+FE0F", "U+20E3"], "7️⃣", "keycap: 7"], [["U+0038", "U+FE0F", "U+20E3"], "8️⃣", "keycap: 8"], [["U+0039", "U+FE0F", "U+20E3"], "9️⃣", "keycap: 9"], [["U+1F51F"], "🔟", "keycap: 10"]]], ["alphanum", [[["U+1F520"], "🔠", "input latin uppercase"], [["U+1F521"], "🔡", "input latin lowercase"], [["U+1F522"], "🔢", "input numbers"], [["U+1F523"], "🔣", "input symbols"], [["U+1F524"], "🔤", "input latin letters"], [["U+1F170"], "🅰", "A button (blood type)"], [["U+1F18E"], "🆎", "AB button (blood type)"], [["U+1F171"], "🅱", "B button (blood type)"], [["U+1F191"], "🆑", "CL button"], [["U+1F192"], "🆒", "COOL button"], [["U+1F193"], "🆓", "FREE button"], [["U+2139"], "ℹ", "information"], [["U+1F194"], "🆔", "ID button"], [["U+24C2"], "Ⓜ", "circled M"], [["U+1F195"], "🆕", "NEW button"], [["U+1F196"], "🆖", "NG button"], [["U+1F17E"], "🅾", "O button (blood type)"], [["U+1F197"], "🆗", "OK button"], [["U+1F17F"], "🅿", "P button"], [["U+1F198"], "🆘", "SOS button"], [["U+1F199"], "🆙", "UP! button"], [["U+1F19A"], "🆚", "VS button"], [["U+1F201"], "🈁", "Japanese “here” button"], [["U+1F202"], "🈂", "Japanese “service charge” button"], [["U+1F237"], "🈷", "Japanese “monthly amount” button"], [["U+1F236"], "🈶", "Japanese “not free of charge” button"], [["U+1F22F"], "🈯", "Japanese “reserved” button"], [["U+1F250"], "🉐", "Japanese “bargain” button"], [["U+1F239"], "🈹", "Japanese “discount” button"], [["U+1F21A"], "🈚", "Japanese “free of charge” button"], [["U+1F232"], "🈲", "Japanese “prohibited” button"], [["U+1F251"], "🉑", "Japanese “acceptable” button"], [["U+1F238"], "🈸", "Japanese “application” button"], [["U+1F234"], "🈴", "Japanese “passing grade” button"], [["U+1F233"], "🈳", "Japanese “vacancy” button"], [["U+3297"], "㊗", "Japanese “congratulations” button"], [["U+3299"], "㊙", "Japanese “secret” button"], [["U+1F23A"], "🈺", "Japanese “open for business” button"], [["U+1F235"], "🈵", "Japanese “no vacancy” button"]]], ["geometric", [[["U+1F534"], "🔴", "red circle"], [["U+1F7E0"], "🟠", "orange circle"], [["U+1F7E1"], "🟡", "yellow circle"], [["U+1F7E2"], "🟢", "green circle"], [["U+1F535"], "🔵", "blue circle"], [["U+1F7E3"], "🟣", "purple circle"], [["U+1F7E4"], "🟤", "brown circle"], [["U+26AB"], "⚫", "black circle"], [["U+26AA"], "⚪", "white circle"], [["U+1F7E5"], "🟥", "red square"], [["U+1F7E7"], "🟧", "orange square"], [["U+1F7E8"], "🟨", "yellow square"], [["U+1F7E9"], "🟩", "green square"], [["U+1F7E6"], "🟦", "blue square"], [["U+1F7EA"], "🟪", "purple square"], [["U+1F7EB"], "🟫", "brown square"], [["U+2B1B"], "⬛", "black large square"], [["U+2B1C"], "⬜", "white large square"], [["U+25FC"], "◼", "black medium square"], [["U+25FB"], "◻", "white medium square"], [["U+25FE"], "◾", "black medium-small square"], [["U+25FD"], "◽", "white medium-small square"], [["U+25AA"], "▪", "black small square"], [["U+25AB"], "▫", "white small square"], [["U+1F536"], "🔶", "large orange diamond"], [["U+1F537"], "🔷", "large blue diamond"], [["U+1F538"], "🔸", "small orange diamond"], [["U+1F539"], "🔹", "small blue diamond"], [["U+1F53A"], "🔺", "red triangle pointed up"], [["U+1F53B"], "🔻", "red triangle pointed down"], [["U+1F4A0"], "💠", "diamond with a dot"], [["U+1F518"], "🔘", "radio button"], [["U+1F533"], "🔳", "white square button"], [["U+1F532"], "🔲", "black square button"]]]]], ["Flags", [["flag", [[["U+1F3C1"], "🏁", "chequered flag"], [["U+1F6A9"], "🚩", "triangular flag"], [["U+1F38C"], "🎌", "crossed flags"], [["U+1F3F4"], "🏴", "black flag"], [["U+1F3F3"], "🏳", "white flag"], [["U+1F3F3", "U+FE0F", "U+200D", "U+1F308"], "🏳️‍🌈", "rainbow flag"], [["U+1F3F3", "U+FE0F", "U+200D", "U+26A7", "U+FE0F"], "🏳️‍⚧️", "⊛ transgender flag"], [["U+1F3F4", "U+200D", "U+2620", "U+FE0F"], "🏴‍☠️", "pirate flag"]]], ["country-flag", [[["U+1F1E6", "U+1F1E8"], "🇦🇨", "flag: Ascension Island"], [["U+1F1E6", "U+1F1E9"], "🇦🇩", "flag: Andorra"], [["U+1F1E6", "U+1F1EA"], "🇦🇪", "flag: United Arab Emirates"], [["U+1F1E6", "U+1F1EB"], "🇦🇫", "flag: Afghanistan"], [["U+1F1E6", "U+1F1EC"], "🇦🇬", "flag: Antigua & Barbuda"], [["U+1F1E6", "U+1F1EE"], "🇦🇮", "flag: Anguilla"], [["U+1F1E6", "U+1F1F1"], "🇦🇱", "flag: Albania"], [["U+1F1E6", "U+1F1F2"], "🇦🇲", "flag: Armenia"], [["U+1F1E6", "U+1F1F4"], "🇦🇴", "flag: Angola"], [["U+1F1E6", "U+1F1F6"], "🇦🇶", "flag: Antarctica"], [["U+1F1E6", "U+1F1F7"], "🇦🇷", "flag: Argentina"], [["U+1F1E6", "U+1F1F8"], "🇦🇸", "flag: American Samoa"], [["U+1F1E6", "U+1F1F9"], "🇦🇹", "flag: Austria"], [["U+1F1E6", "U+1F1FA"], "🇦🇺", "flag: Australia"], [["U+1F1E6", "U+1F1FC"], "🇦🇼", "flag: Aruba"], [["U+1F1E6", "U+1F1FD"], "🇦🇽", "flag: Åland Islands"], [["U+1F1E6", "U+1F1FF"], "🇦🇿", "flag: Azerbaijan"], [["U+1F1E7", "U+1F1E6"], "🇧🇦", "flag: Bosnia & Herzegovina"], [["U+1F1E7", "U+1F1E7"], "🇧🇧", "flag: Barbados"], [["U+1F1E7", "U+1F1E9"], "🇧🇩", "flag: Bangladesh"], [["U+1F1E7", "U+1F1EA"], "🇧🇪", "flag: Belgium"], [["U+1F1E7", "U+1F1EB"], "🇧🇫", "flag: Burkina Faso"], [["U+1F1E7", "U+1F1EC"], "🇧🇬", "flag: Bulgaria"], [["U+1F1E7", "U+1F1ED"], "🇧🇭", "flag: Bahrain"], [["U+1F1E7", "U+1F1EE"], "🇧🇮", "flag: Burundi"], [["U+1F1E7", "U+1F1EF"], "🇧🇯", "flag: Benin"], [["U+1F1E7", "U+1F1F1"], "🇧🇱", "flag: St. Barthélemy"], [["U+1F1E7", "U+1F1F2"], "🇧🇲", "flag: Bermuda"], [["U+1F1E7", "U+1F1F3"], "🇧🇳", "flag: Brunei"], [["U+1F1E7", "U+1F1F4"], "🇧🇴", "flag: Bolivia"], [["U+1F1E7", "U+1F1F6"], "🇧🇶", "flag: Caribbean Netherlands"], [["U+1F1E7", "U+1F1F7"], "🇧🇷", "flag: Brazil"], [["U+1F1E7", "U+1F1F8"], "🇧🇸", "flag: Bahamas"], [["U+1F1E7", "U+1F1F9"], "🇧🇹", "flag: Bhutan"], [["U+1F1E7", "U+1F1FB"], "🇧🇻", "flag: Bouvet Island"], [["U+1F1E7", "U+1F1FC"], "🇧🇼", "flag: Botswana"], [["U+1F1E7", "U+1F1FE"], "🇧🇾", "flag: Belarus"], [["U+1F1E7", "U+1F1FF"], "🇧🇿", "flag: Belize"], [["U+1F1E8", "U+1F1E6"], "🇨🇦", "flag: Canada"], [["U+1F1E8", "U+1F1E8"], "🇨🇨", "flag: Cocos (Keeling) Islands"], [["U+1F1E8", "U+1F1E9"], "🇨🇩", "flag: Congo - Kinshasa"], [["U+1F1E8", "U+1F1EB"], "🇨🇫", "flag: Central African Republic"], [["U+1F1E8", "U+1F1EC"], "🇨🇬", "flag: Congo - Brazzaville"], [["U+1F1E8", "U+1F1ED"], "🇨🇭", "flag: Switzerland"], [["U+1F1E8", "U+1F1EE"], "🇨🇮", "flag: Côte d’Ivoire"], [["U+1F1E8", "U+1F1F0"], "🇨🇰", "flag: Cook Islands"], [["U+1F1E8", "U+1F1F1"], "🇨🇱", "flag: Chile"], [["U+1F1E8", "U+1F1F2"], "🇨🇲", "flag: Cameroon"], [["U+1F1E8", "U+1F1F3"], "🇨🇳", "flag: China"], [["U+1F1E8", "U+1F1F4"], "🇨🇴", "flag: Colombia"], [["U+1F1E8", "U+1F1F5"], "🇨🇵", "flag: Clipperton Island"], [["U+1F1E8", "U+1F1F7"], "🇨🇷", "flag: Costa Rica"], [["U+1F1E8", "U+1F1FA"], "🇨🇺", "flag: Cuba"], [["U+1F1E8", "U+1F1FB"], "🇨🇻", "flag: Cape Verde"], [["U+1F1E8", "U+1F1FC"], "🇨🇼", "flag: Curaçao"], [["U+1F1E8", "U+1F1FD"], "🇨🇽", "flag: Christmas Island"], [["U+1F1E8", "U+1F1FE"], "🇨🇾", "flag: Cyprus"], [["U+1F1E8", "U+1F1FF"], "🇨🇿", "flag: Czechia"], [["U+1F1E9", "U+1F1EA"], "🇩🇪", "flag: Germany"], [["U+1F1E9", "U+1F1EC"], "🇩🇬", "flag: Diego Garcia"], [["U+1F1E9", "U+1F1EF"], "🇩🇯", "flag: Djibouti"], [["U+1F1E9", "U+1F1F0"], "🇩🇰", "flag: Denmark"], [["U+1F1E9", "U+1F1F2"], "🇩🇲", "flag: Dominica"], [["U+1F1E9", "U+1F1F4"], "🇩🇴", "flag: Dominican Republic"], [["U+1F1E9", "U+1F1FF"], "🇩🇿", "flag: Algeria"], [["U+1F1EA", "U+1F1E6"], "🇪🇦", "flag: Ceuta & Melilla"], [["U+1F1EA", "U+1F1E8"], "🇪🇨", "flag: Ecuador"], [["U+1F1EA", "U+1F1EA"], "🇪🇪", "flag: Estonia"], [["U+1F1EA", "U+1F1EC"], "🇪🇬", "flag: Egypt"], [["U+1F1EA", "U+1F1ED"], "🇪🇭", "flag: Western Sahara"], [["U+1F1EA", "U+1F1F7"], "🇪🇷", "flag: Eritrea"], [["U+1F1EA", "U+1F1F8"], "🇪🇸", "flag: Spain"], [["U+1F1EA", "U+1F1F9"], "🇪🇹", "flag: Ethiopia"], [["U+1F1EA", "U+1F1FA"], "🇪🇺", "flag: European Union"], [["U+1F1EB", "U+1F1EE"], "🇫🇮", "flag: Finland"], [["U+1F1EB", "U+1F1EF"], "🇫🇯", "flag: Fiji"], [["U+1F1EB", "U+1F1F0"], "🇫🇰", "flag: Falkland Islands"], [["U+1F1EB", "U+1F1F2"], "🇫🇲", "flag: Micronesia"], [["U+1F1EB", "U+1F1F4"], "🇫🇴", "flag: Faroe Islands"], [["U+1F1EB", "U+1F1F7"], "🇫🇷", "flag: France"], [["U+1F1EC", "U+1F1E6"], "🇬🇦", "flag: Gabon"], [["U+1F1EC", "U+1F1E7"], "🇬🇧", "flag: United Kingdom"], [["U+1F1EC", "U+1F1E9"], "🇬🇩", "flag: Grenada"], [["U+1F1EC", "U+1F1EA"], "🇬🇪", "flag: Georgia"], [["U+1F1EC", "U+1F1EB"], "🇬🇫", "flag: French Guiana"], [["U+1F1EC", "U+1F1EC"], "🇬🇬", "flag: Guernsey"], [["U+1F1EC", "U+1F1ED"], "🇬🇭", "flag: Ghana"], [["U+1F1EC", "U+1F1EE"], "🇬🇮", "flag: Gibraltar"], [["U+1F1EC", "U+1F1F1"], "🇬🇱", "flag: Greenland"], [["U+1F1EC", "U+1F1F2"], "🇬🇲", "flag: Gambia"], [["U+1F1EC", "U+1F1F3"], "🇬🇳", "flag: Guinea"], [["U+1F1EC", "U+1F1F5"], "🇬🇵", "flag: Guadeloupe"], [["U+1F1EC", "U+1F1F6"], "🇬🇶", "flag: Equatorial Guinea"], [["U+1F1EC", "U+1F1F7"], "🇬🇷", "flag: Greece"], [["U+1F1EC", "U+1F1F8"], "🇬🇸", "flag: South Georgia & South Sandwich Islands"], [["U+1F1EC", "U+1F1F9"], "🇬🇹", "flag: Guatemala"], [["U+1F1EC", "U+1F1FA"], "🇬🇺", "flag: Guam"], [["U+1F1EC", "U+1F1FC"], "🇬🇼", "flag: Guinea-Bissau"], [["U+1F1EC", "U+1F1FE"], "🇬🇾", "flag: Guyana"], [["U+1F1ED", "U+1F1F0"], "🇭🇰", "flag: Hong Kong SAR China"], [["U+1F1ED", "U+1F1F2"], "🇭🇲", "flag: Heard & McDonald Islands"], [["U+1F1ED", "U+1F1F3"], "🇭🇳", "flag: Honduras"], [["U+1F1ED", "U+1F1F7"], "🇭🇷", "flag: Croatia"], [["U+1F1ED", "U+1F1F9"], "🇭🇹", "flag: Haiti"], [["U+1F1ED", "U+1F1FA"], "🇭🇺", "flag: Hungary"], [["U+1F1EE", "U+1F1E8"], "🇮🇨", "flag: Canary Islands"], [["U+1F1EE", "U+1F1E9"], "🇮🇩", "flag: Indonesia"], [["U+1F1EE", "U+1F1EA"], "🇮🇪", "flag: Ireland"], [["U+1F1EE", "U+1F1F1"], "🇮🇱", "flag: Israel"], [["U+1F1EE", "U+1F1F2"], "🇮🇲", "flag: Isle of Man"], [["U+1F1EE", "U+1F1F3"], "🇮🇳", "flag: India"], [["U+1F1EE", "U+1F1F4"], "🇮🇴", "flag: British Indian Ocean Territory"], [["U+1F1EE", "U+1F1F6"], "🇮🇶", "flag: Iraq"], [["U+1F1EE", "U+1F1F7"], "🇮🇷", "flag: Iran"], [["U+1F1EE", "U+1F1F8"], "🇮🇸", "flag: Iceland"], [["U+1F1EE", "U+1F1F9"], "🇮🇹", "flag: Italy"], [["U+1F1EF", "U+1F1EA"], "🇯🇪", "flag: Jersey"], [["U+1F1EF", "U+1F1F2"], "🇯🇲", "flag: Jamaica"], [["U+1F1EF", "U+1F1F4"], "🇯🇴", "flag: Jordan"], [["U+1F1EF", "U+1F1F5"], "🇯🇵", "flag: Japan"], [["U+1F1F0", "U+1F1EA"], "🇰🇪", "flag: Kenya"], [["U+1F1F0", "U+1F1EC"], "🇰🇬", "flag: Kyrgyzstan"], [["U+1F1F0", "U+1F1ED"], "🇰🇭", "flag: Cambodia"], [["U+1F1F0", "U+1F1EE"], "🇰🇮", "flag: Kiribati"], [["U+1F1F0", "U+1F1F2"], "🇰🇲", "flag: Comoros"], [["U+1F1F0", "U+1F1F3"], "🇰🇳", "flag: St. Kitts & Nevis"], [["U+1F1F0", "U+1F1F5"], "🇰🇵", "flag: North Korea"], [["U+1F1F0", "U+1F1F7"], "🇰🇷", "flag: South Korea"], [["U+1F1F0", "U+1F1FC"], "🇰🇼", "flag: Kuwait"], [["U+1F1F0", "U+1F1FE"], "🇰🇾", "flag: Cayman Islands"], [["U+1F1F0", "U+1F1FF"], "🇰🇿", "flag: Kazakhstan"], [["U+1F1F1", "U+1F1E6"], "🇱🇦", "flag: Laos"], [["U+1F1F1", "U+1F1E7"], "🇱🇧", "flag: Lebanon"], [["U+1F1F1", "U+1F1E8"], "🇱🇨", "flag: St. Lucia"], [["U+1F1F1", "U+1F1EE"], "🇱🇮", "flag: Liechtenstein"], [["U+1F1F1", "U+1F1F0"], "🇱🇰", "flag: Sri Lanka"], [["U+1F1F1", "U+1F1F7"], "🇱🇷", "flag: Liberia"], [["U+1F1F1", "U+1F1F8"], "🇱🇸", "flag: Lesotho"], [["U+1F1F1", "U+1F1F9"], "🇱🇹", "flag: Lithuania"], [["U+1F1F1", "U+1F1FA"], "🇱🇺", "flag: Luxembourg"], [["U+1F1F1", "U+1F1FB"], "🇱🇻", "flag: Latvia"], [["U+1F1F1", "U+1F1FE"], "🇱🇾", "flag: Libya"], [["U+1F1F2", "U+1F1E6"], "🇲🇦", "flag: Morocco"], [["U+1F1F2", "U+1F1E8"], "🇲🇨", "flag: Monaco"], [["U+1F1F2", "U+1F1E9"], "🇲🇩", "flag: Moldova"], [["U+1F1F2", "U+1F1EA"], "🇲🇪", "flag: Montenegro"], [["U+1F1F2", "U+1F1EB"], "🇲🇫", "flag: St. Martin"], [["U+1F1F2", "U+1F1EC"], "🇲🇬", "flag: Madagascar"], [["U+1F1F2", "U+1F1ED"], "🇲🇭", "flag: Marshall Islands"], [["U+1F1F2", "U+1F1F0"], "🇲🇰", "flag: North Macedonia"], [["U+1F1F2", "U+1F1F1"], "🇲🇱", "flag: Mali"], [["U+1F1F2", "U+1F1F2"], "🇲🇲", "flag: Myanmar (Burma)"], [["U+1F1F2", "U+1F1F3"], "🇲🇳", "flag: Mongolia"], [["U+1F1F2", "U+1F1F4"], "🇲🇴", "flag: Macao SAR China"], [["U+1F1F2", "U+1F1F5"], "🇲🇵", "flag: Northern Mariana Islands"], [["U+1F1F2", "U+1F1F6"], "🇲🇶", "flag: Martinique"], [["U+1F1F2", "U+1F1F7"], "🇲🇷", "flag: Mauritania"], [["U+1F1F2", "U+1F1F8"], "🇲🇸", "flag: Montserrat"], [["U+1F1F2", "U+1F1F9"], "🇲🇹", "flag: Malta"], [["U+1F1F2", "U+1F1FA"], "🇲🇺", "flag: Mauritius"], [["U+1F1F2", "U+1F1FB"], "🇲🇻", "flag: Maldives"], [["U+1F1F2", "U+1F1FC"], "🇲🇼", "flag: Malawi"], [["U+1F1F2", "U+1F1FD"], "🇲🇽", "flag: Mexico"], [["U+1F1F2", "U+1F1FE"], "🇲🇾", "flag: Malaysia"], [["U+1F1F2", "U+1F1FF"], "🇲🇿", "flag: Mozambique"], [["U+1F1F3", "U+1F1E6"], "🇳🇦", "flag: Namibia"], [["U+1F1F3", "U+1F1E8"], "🇳🇨", "flag: New Caledonia"], [["U+1F1F3", "U+1F1EA"], "🇳🇪", "flag: Niger"], [["U+1F1F3", "U+1F1EB"], "🇳🇫", "flag: Norfolk Island"], [["U+1F1F3", "U+1F1EC"], "🇳🇬", "flag: Nigeria"], [["U+1F1F3", "U+1F1EE"], "🇳🇮", "flag: Nicaragua"], [["U+1F1F3", "U+1F1F1"], "🇳🇱", "flag: Netherlands"], [["U+1F1F3", "U+1F1F4"], "🇳🇴", "flag: Norway"], [["U+1F1F3", "U+1F1F5"], "🇳🇵", "flag: Nepal"], [["U+1F1F3", "U+1F1F7"], "🇳🇷", "flag: Nauru"], [["U+1F1F3", "U+1F1FA"], "🇳🇺", "flag: Niue"], [["U+1F1F3", "U+1F1FF"], "🇳🇿", "flag: New Zealand"], [["U+1F1F4", "U+1F1F2"], "🇴🇲", "flag: Oman"], [["U+1F1F5", "U+1F1E6"], "🇵🇦", "flag: Panama"], [["U+1F1F5", "U+1F1EA"], "🇵🇪", "flag: Peru"], [["U+1F1F5", "U+1F1EB"], "🇵🇫", "flag: French Polynesia"], [["U+1F1F5", "U+1F1EC"], "🇵🇬", "flag: Papua New Guinea"], [["U+1F1F5", "U+1F1ED"], "🇵🇭", "flag: Philippines"], [["U+1F1F5", "U+1F1F0"], "🇵🇰", "flag: Pakistan"], [["U+1F1F5", "U+1F1F1"], "🇵🇱", "flag: Poland"], [["U+1F1F5", "U+1F1F2"], "🇵🇲", "flag: St. Pierre & Miquelon"], [["U+1F1F5", "U+1F1F3"], "🇵🇳", "flag: Pitcairn Islands"], [["U+1F1F5", "U+1F1F7"], "🇵🇷", "flag: Puerto Rico"], [["U+1F1F5", "U+1F1F8"], "🇵🇸", "flag: Palestinian Territories"], [["U+1F1F5", "U+1F1F9"], "🇵🇹", "flag: Portugal"], [["U+1F1F5", "U+1F1FC"], "🇵🇼", "flag: Palau"], [["U+1F1F5", "U+1F1FE"], "🇵🇾", "flag: Paraguay"], [["U+1F1F6", "U+1F1E6"], "🇶🇦", "flag: Qatar"], [["U+1F1F7", "U+1F1EA"], "🇷🇪", "flag: Réunion"], [["U+1F1F7", "U+1F1F4"], "🇷🇴", "flag: Romania"], [["U+1F1F7", "U+1F1F8"], "🇷🇸", "flag: Serbia"], [["U+1F1F7", "U+1F1FA"], "🇷🇺", "flag: Russia"], [["U+1F1F7", "U+1F1FC"], "🇷🇼", "flag: Rwanda"], [["U+1F1F8", "U+1F1E6"], "🇸🇦", "flag: Saudi Arabia"], [["U+1F1F8", "U+1F1E7"], "🇸🇧", "flag: Solomon Islands"], [["U+1F1F8", "U+1F1E8"], "🇸🇨", "flag: Seychelles"], [["U+1F1F8", "U+1F1E9"], "🇸🇩", "flag: Sudan"], [["U+1F1F8", "U+1F1EA"], "🇸🇪", "flag: Sweden"], [["U+1F1F8", "U+1F1EC"], "🇸🇬", "flag: Singapore"], [["U+1F1F8", "U+1F1ED"], "🇸🇭", "flag: St. Helena"], [["U+1F1F8", "U+1F1EE"], "🇸🇮", "flag: Slovenia"], [["U+1F1F8", "U+1F1EF"], "🇸🇯", "flag: Svalbard & Jan Mayen"], [["U+1F1F8", "U+1F1F0"], "🇸🇰", "flag: Slovakia"], [["U+1F1F8", "U+1F1F1"], "🇸🇱", "flag: Sierra Leone"], [["U+1F1F8", "U+1F1F2"], "🇸🇲", "flag: San Marino"], [["U+1F1F8", "U+1F1F3"], "🇸🇳", "flag: Senegal"], [["U+1F1F8", "U+1F1F4"], "🇸🇴", "flag: Somalia"], [["U+1F1F8", "U+1F1F7"], "🇸🇷", "flag: Suriname"], [["U+1F1F8", "U+1F1F8"], "🇸🇸", "flag: South Sudan"], [["U+1F1F8", "U+1F1F9"], "🇸🇹", "flag: São Tomé & Príncipe"], [["U+1F1F8", "U+1F1FB"], "🇸🇻", "flag: El Salvador"], [["U+1F1F8", "U+1F1FD"], "🇸🇽", "flag: Sint Maarten"], [["U+1F1F8", "U+1F1FE"], "🇸🇾", "flag: Syria"], [["U+1F1F8", "U+1F1FF"], "🇸🇿", "flag: Eswatini"], [["U+1F1F9", "U+1F1E6"], "🇹🇦", "flag: Tristan da Cunha"], [["U+1F1F9", "U+1F1E8"], "🇹🇨", "flag: Turks & Caicos Islands"], [["U+1F1F9", "U+1F1E9"], "🇹🇩", "flag: Chad"], [["U+1F1F9", "U+1F1EB"], "🇹🇫", "flag: French Southern Territories"], [["U+1F1F9", "U+1F1EC"], "🇹🇬", "flag: Togo"], [["U+1F1F9", "U+1F1ED"], "🇹🇭", "flag: Thailand"], [["U+1F1F9", "U+1F1EF"], "🇹🇯", "flag: Tajikistan"], [["U+1F1F9", "U+1F1F0"], "🇹🇰", "flag: Tokelau"], [["U+1F1F9", "U+1F1F1"], "🇹🇱", "flag: Timor-Leste"], [["U+1F1F9", "U+1F1F2"], "🇹🇲", "flag: Turkmenistan"], [["U+1F1F9", "U+1F1F3"], "🇹🇳", "flag: Tunisia"], [["U+1F1F9", "U+1F1F4"], "🇹🇴", "flag: Tonga"], [["U+1F1F9", "U+1F1F7"], "🇹🇷", "flag: Turkey"], [["U+1F1F9", "U+1F1F9"], "🇹🇹", "flag: Trinidad & Tobago"], [["U+1F1F9", "U+1F1FB"], "🇹🇻", "flag: Tuvalu"], [["U+1F1F9", "U+1F1FC"], "🇹🇼", "flag: Taiwan"], [["U+1F1F9", "U+1F1FF"], "🇹🇿", "flag: Tanzania"], [["U+1F1FA", "U+1F1E6"], "🇺🇦", "flag: Ukraine"], [["U+1F1FA", "U+1F1EC"], "🇺🇬", "flag: Uganda"], [["U+1F1FA", "U+1F1F2"], "🇺🇲", "flag: U.S. Outlying Islands"], [["U+1F1FA", "U+1F1F3"], "🇺🇳", "flag: United Nations"], [["U+1F1FA", "U+1F1F8"], "🇺🇸", "flag: United States"], [["U+1F1FA", "U+1F1FE"], "🇺🇾", "flag: Uruguay"], [["U+1F1FA", "U+1F1FF"], "🇺🇿", "flag: Uzbekistan"], [["U+1F1FB", "U+1F1E6"], "🇻🇦", "flag: Vatican City"], [["U+1F1FB", "U+1F1E8"], "🇻🇨", "flag: St. Vincent & Grenadines"], [["U+1F1FB", "U+1F1EA"], "🇻🇪", "flag: Venezuela"], [["U+1F1FB", "U+1F1EC"], "🇻🇬", "flag: British Virgin Islands"], [["U+1F1FB", "U+1F1EE"], "🇻🇮", "flag: U.S. Virgin Islands"], [["U+1F1FB", "U+1F1F3"], "🇻🇳", "flag: Vietnam"], [["U+1F1FB", "U+1F1FA"], "🇻🇺", "flag: Vanuatu"], [["U+1F1FC", "U+1F1EB"], "🇼🇫", "flag: Wallis & Futuna"], [["U+1F1FC", "U+1F1F8"], "🇼🇸", "flag: Samoa"], [["U+1F1FD", "U+1F1F0"], "🇽🇰", "flag: Kosovo"], [["U+1F1FE", "U+1F1EA"], "🇾🇪", "flag: Yemen"], [["U+1F1FE", "U+1F1F9"], "🇾🇹", "flag: Mayotte"], [["U+1F1FF", "U+1F1E6"], "🇿🇦", "flag: South Africa"], [["U+1F1FF", "U+1F1F2"], "🇿🇲", "flag: Zambia"], [["U+1F1FF", "U+1F1FC"], "🇿🇼", "flag: Zimbabwe"]]], ["subdivision-flag", [[["U+1F3F4", "U+E0067", "U+E0062", "U+E0065", "U+E006E", "U+E0067", "U+E007F"], "🏴󠁧󠁢󠁥󠁮󠁧󠁿", "flag: England"], [["U+1F3F4", "U+E0067", "U+E0062", "U+E0073", "U+E0063", "U+E0074", "U+E007F"], "🏴󠁧󠁢󠁳󠁣󠁴󠁿", "flag: Scotland"], [["U+1F3F4", "U+E0067", "U+E0062", "U+E0077", "U+E006C", "U+E0073", "U+E007F"], "🏴󠁧󠁢󠁷󠁬󠁳󠁿", "flag: Wales"]]]]]];
/* harmony default export */ __webpack_exports__["a"] = (EmojiChars); 

/***/ }),
/* 80 */
/***/ (function(module, exports, __webpack_require__) {

/**
 * Copyright (c) 2014-present, Facebook, Inc.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */

var runtime = (function (exports) {
  "use strict";

  var Op = Object.prototype;
  var hasOwn = Op.hasOwnProperty;
  var undefined; // More compressible than void 0.
  var $Symbol = typeof Symbol === "function" ? Symbol : {};
  var iteratorSymbol = $Symbol.iterator || "@@iterator";
  var asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator";
  var toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag";

  function define(obj, key, value) {
    Object.defineProperty(obj, key, {
      value: value,
      enumerable: true,
      configurable: true,
      writable: true
    });
    return obj[key];
  }
  try {
    // IE 8 has a broken Object.defineProperty that only works on DOM objects.
    define({}, "");
  } catch (err) {
    define = function(obj, key, value) {
      return obj[key] = value;
    };
  }

  function wrap(innerFn, outerFn, self, tryLocsList) {
    // If outerFn provided and outerFn.prototype is a Generator, then outerFn.prototype instanceof Generator.
    var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator;
    var generator = Object.create(protoGenerator.prototype);
    var context = new Context(tryLocsList || []);

    // The ._invoke method unifies the implementations of the .next,
    // .throw, and .return methods.
    generator._invoke = makeInvokeMethod(innerFn, self, context);

    return generator;
  }
  exports.wrap = wrap;

  // Try/catch helper to minimize deoptimizations. Returns a completion
  // record like context.tryEntries[i].completion. This interface could
  // have been (and was previously) designed to take a closure to be
  // invoked without arguments, but in all the cases we care about we
  // already have an existing method we want to call, so there's no need
  // to create a new function object. We can even get away with assuming
  // the method takes exactly one argument, since that happens to be true
  // in every case, so we don't have to touch the arguments object. The
  // only additional allocation required is the completion record, which
  // has a stable shape and so hopefully should be cheap to allocate.
  function tryCatch(fn, obj, arg) {
    try {
      return { type: "normal", arg: fn.call(obj, arg) };
    } catch (err) {
      return { type: "throw", arg: err };
    }
  }

  var GenStateSuspendedStart = "suspendedStart";
  var GenStateSuspendedYield = "suspendedYield";
  var GenStateExecuting = "executing";
  var GenStateCompleted = "completed";

  // Returning this object from the innerFn has the same effect as
  // breaking out of the dispatch switch statement.
  var ContinueSentinel = {};

  // Dummy constructor functions that we use as the .constructor and
  // .constructor.prototype properties for functions that return Generator
  // objects. For full spec compliance, you may wish to configure your
  // minifier not to mangle the names of these two functions.
  function Generator() {}
  function GeneratorFunction() {}
  function GeneratorFunctionPrototype() {}

  // This is a polyfill for %IteratorPrototype% for environments that
  // don't natively support it.
  var IteratorPrototype = {};
  define(IteratorPrototype, iteratorSymbol, function () {
    return this;
  });

  var getProto = Object.getPrototypeOf;
  var NativeIteratorPrototype = getProto && getProto(getProto(values([])));
  if (NativeIteratorPrototype &&
      NativeIteratorPrototype !== Op &&
      hasOwn.call(NativeIteratorPrototype, iteratorSymbol)) {
    // This environment has a native %IteratorPrototype%; use it instead
    // of the polyfill.
    IteratorPrototype = NativeIteratorPrototype;
  }

  var Gp = GeneratorFunctionPrototype.prototype =
    Generator.prototype = Object.create(IteratorPrototype);
  GeneratorFunction.prototype = GeneratorFunctionPrototype;
  define(Gp, "constructor", GeneratorFunctionPrototype);
  define(GeneratorFunctionPrototype, "constructor", GeneratorFunction);
  GeneratorFunction.displayName = define(
    GeneratorFunctionPrototype,
    toStringTagSymbol,
    "GeneratorFunction"
  );

  // Helper for defining the .next, .throw, and .return methods of the
  // Iterator interface in terms of a single ._invoke method.
  function defineIteratorMethods(prototype) {
    ["next", "throw", "return"].forEach(function(method) {
      define(prototype, method, function(arg) {
        return this._invoke(method, arg);
      });
    });
  }

  exports.isGeneratorFunction = function(genFun) {
    var ctor = typeof genFun === "function" && genFun.constructor;
    return ctor
      ? ctor === GeneratorFunction ||
        // For the native GeneratorFunction constructor, the best we can
        // do is to check its .name property.
        (ctor.displayName || ctor.name) === "GeneratorFunction"
      : false;
  };

  exports.mark = function(genFun) {
    if (Object.setPrototypeOf) {
      Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);
    } else {
      genFun.__proto__ = GeneratorFunctionPrototype;
      define(genFun, toStringTagSymbol, "GeneratorFunction");
    }
    genFun.prototype = Object.create(Gp);
    return genFun;
  };

  // Within the body of any async function, `await x` is transformed to
  // `yield regeneratorRuntime.awrap(x)`, so that the runtime can test
  // `hasOwn.call(value, "__await")` to determine if the yielded value is
  // meant to be awaited.
  exports.awrap = function(arg) {
    return { __await: arg };
  };

  function AsyncIterator(generator, PromiseImpl) {
    function invoke(method, arg, resolve, reject) {
      var record = tryCatch(generator[method], generator, arg);
      if (record.type === "throw") {
        reject(record.arg);
      } else {
        var result = record.arg;
        var value = result.value;
        if (value &&
            typeof value === "object" &&
            hasOwn.call(value, "__await")) {
          return PromiseImpl.resolve(value.__await).then(function(value) {
            invoke("next", value, resolve, reject);
          }, function(err) {
            invoke("throw", err, resolve, reject);
          });
        }

        return PromiseImpl.resolve(value).then(function(unwrapped) {
          // When a yielded Promise is resolved, its final value becomes
          // the .value of the Promise<{value,done}> result for the
          // current iteration.
          result.value = unwrapped;
          resolve(result);
        }, function(error) {
          // If a rejected Promise was yielded, throw the rejection back
          // into the async generator function so it can be handled there.
          return invoke("throw", error, resolve, reject);
        });
      }
    }

    var previousPromise;

    function enqueue(method, arg) {
      function callInvokeWithMethodAndArg() {
        return new PromiseImpl(function(resolve, reject) {
          invoke(method, arg, resolve, reject);
        });
      }

      return previousPromise =
        // If enqueue has been called before, then we want to wait until
        // all previous Promises have been resolved before calling invoke,
        // so that results are always delivered in the correct order. If
        // enqueue has not been called before, then it is important to
        // call invoke immediately, without waiting on a callback to fire,
        // so that the async generator function has the opportunity to do
        // any necessary setup in a predictable way. This predictability
        // is why the Promise constructor synchronously invokes its
        // executor callback, and why async functions synchronously
        // execute code before the first await. Since we implement simple
        // async functions in terms of async generators, it is especially
        // important to get this right, even though it requires care.
        previousPromise ? previousPromise.then(
          callInvokeWithMethodAndArg,
          // Avoid propagating failures to Promises returned by later
          // invocations of the iterator.
          callInvokeWithMethodAndArg
        ) : callInvokeWithMethodAndArg();
    }

    // Define the unified helper method that is used to implement .next,
    // .throw, and .return (see defineIteratorMethods).
    this._invoke = enqueue;
  }

  defineIteratorMethods(AsyncIterator.prototype);
  define(AsyncIterator.prototype, asyncIteratorSymbol, function () {
    return this;
  });
  exports.AsyncIterator = AsyncIterator;

  // Note that simple async functions are implemented on top of
  // AsyncIterator objects; they just return a Promise for the value of
  // the final result produced by the iterator.
  exports.async = function(innerFn, outerFn, self, tryLocsList, PromiseImpl) {
    if (PromiseImpl === void 0) PromiseImpl = Promise;

    var iter = new AsyncIterator(
      wrap(innerFn, outerFn, self, tryLocsList),
      PromiseImpl
    );

    return exports.isGeneratorFunction(outerFn)
      ? iter // If outerFn is a generator, return the full iterator.
      : iter.next().then(function(result) {
          return result.done ? result.value : iter.next();
        });
  };

  function makeInvokeMethod(innerFn, self, context) {
    var state = GenStateSuspendedStart;

    return function invoke(method, arg) {
      if (state === GenStateExecuting) {
        throw new Error("Generator is already running");
      }

      if (state === GenStateCompleted) {
        if (method === "throw") {
          throw arg;
        }

        // Be forgiving, per 25.3.3.3.3 of the spec:
        // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume
        return doneResult();
      }

      context.method = method;
      context.arg = arg;

      while (true) {
        var delegate = context.delegate;
        if (delegate) {
          var delegateResult = maybeInvokeDelegate(delegate, context);
          if (delegateResult) {
            if (delegateResult === ContinueSentinel) continue;
            return delegateResult;
          }
        }

        if (context.method === "next") {
          // Setting context._sent for legacy support of Babel's
          // function.sent implementation.
          context.sent = context._sent = context.arg;

        } else if (context.method === "throw") {
          if (state === GenStateSuspendedStart) {
            state = GenStateCompleted;
            throw context.arg;
          }

          context.dispatchException(context.arg);

        } else if (context.method === "return") {
          context.abrupt("return", context.arg);
        }

        state = GenStateExecuting;

        var record = tryCatch(innerFn, self, context);
        if (record.type === "normal") {
          // If an exception is thrown from innerFn, we leave state ===
          // GenStateExecuting and loop back for another invocation.
          state = context.done
            ? GenStateCompleted
            : GenStateSuspendedYield;

          if (record.arg === ContinueSentinel) {
            continue;
          }

          return {
            value: record.arg,
            done: context.done
          };

        } else if (record.type === "throw") {
          state = GenStateCompleted;
          // Dispatch the exception by looping back around to the
          // context.dispatchException(context.arg) call above.
          context.method = "throw";
          context.arg = record.arg;
        }
      }
    };
  }

  // Call delegate.iterator[context.method](context.arg) and handle the
  // result, either by returning a { value, done } result from the
  // delegate iterator, or by modifying context.method and context.arg,
  // setting context.delegate to null, and returning the ContinueSentinel.
  function maybeInvokeDelegate(delegate, context) {
    var method = delegate.iterator[context.method];
    if (method === undefined) {
      // A .throw or .return when the delegate iterator has no .throw
      // method always terminates the yield* loop.
      context.delegate = null;

      if (context.method === "throw") {
        // Note: ["return"] must be used for ES3 parsing compatibility.
        if (delegate.iterator["return"]) {
          // If the delegate iterator has a return method, give it a
          // chance to clean up.
          context.method = "return";
          context.arg = undefined;
          maybeInvokeDelegate(delegate, context);

          if (context.method === "throw") {
            // If maybeInvokeDelegate(context) changed context.method from
            // "return" to "throw", let that override the TypeError below.
            return ContinueSentinel;
          }
        }

        context.method = "throw";
        context.arg = new TypeError(
          "The iterator does not provide a 'throw' method");
      }

      return ContinueSentinel;
    }

    var record = tryCatch(method, delegate.iterator, context.arg);

    if (record.type === "throw") {
      context.method = "throw";
      context.arg = record.arg;
      context.delegate = null;
      return ContinueSentinel;
    }

    var info = record.arg;

    if (! info) {
      context.method = "throw";
      context.arg = new TypeError("iterator result is not an object");
      context.delegate = null;
      return ContinueSentinel;
    }

    if (info.done) {
      // Assign the result of the finished delegate to the temporary
      // variable specified by delegate.resultName (see delegateYield).
      context[delegate.resultName] = info.value;

      // Resume execution at the desired location (see delegateYield).
      context.next = delegate.nextLoc;

      // If context.method was "throw" but the delegate handled the
      // exception, let the outer generator proceed normally. If
      // context.method was "next", forget context.arg since it has been
      // "consumed" by the delegate iterator. If context.method was
      // "return", allow the original .return call to continue in the
      // outer generator.
      if (context.method !== "return") {
        context.method = "next";
        context.arg = undefined;
      }

    } else {
      // Re-yield the result returned by the delegate method.
      return info;
    }

    // The delegate iterator is finished, so forget it and continue with
    // the outer generator.
    context.delegate = null;
    return ContinueSentinel;
  }

  // Define Generator.prototype.{next,throw,return} in terms of the
  // unified ._invoke helper method.
  defineIteratorMethods(Gp);

  define(Gp, toStringTagSymbol, "Generator");

  // A Generator should always return itself as the iterator object when the
  // @@iterator function is called on it. Some browsers' implementations of the
  // iterator prototype chain incorrectly implement this, causing the Generator
  // object to not be returned from this call. This ensures that doesn't happen.
  // See https://github.com/facebook/regenerator/issues/274 for more details.
  define(Gp, iteratorSymbol, function() {
    return this;
  });

  define(Gp, "toString", function() {
    return "[object Generator]";
  });

  function pushTryEntry(locs) {
    var entry = { tryLoc: locs[0] };

    if (1 in locs) {
      entry.catchLoc = locs[1];
    }

    if (2 in locs) {
      entry.finallyLoc = locs[2];
      entry.afterLoc = locs[3];
    }

    this.tryEntries.push(entry);
  }

  function resetTryEntry(entry) {
    var record = entry.completion || {};
    record.type = "normal";
    delete record.arg;
    entry.completion = record;
  }

  function Context(tryLocsList) {
    // The root entry object (effectively a try statement without a catch
    // or a finally block) gives us a place to store values thrown from
    // locations where there is no enclosing try statement.
    this.tryEntries = [{ tryLoc: "root" }];
    tryLocsList.forEach(pushTryEntry, this);
    this.reset(true);
  }

  exports.keys = function(object) {
    var keys = [];
    for (var key in object) {
      keys.push(key);
    }
    keys.reverse();

    // Rather than returning an object with a next method, we keep
    // things simple and return the next function itself.
    return function next() {
      while (keys.length) {
        var key = keys.pop();
        if (key in object) {
          next.value = key;
          next.done = false;
          return next;
        }
      }

      // To avoid creating an additional object, we just hang the .value
      // and .done properties off the next function object itself. This
      // also ensures that the minifier will not anonymize the function.
      next.done = true;
      return next;
    };
  };

  function values(iterable) {
    if (iterable) {
      var iteratorMethod = iterable[iteratorSymbol];
      if (iteratorMethod) {
        return iteratorMethod.call(iterable);
      }

      if (typeof iterable.next === "function") {
        return iterable;
      }

      if (!isNaN(iterable.length)) {
        var i = -1, next = function next() {
          while (++i < iterable.length) {
            if (hasOwn.call(iterable, i)) {
              next.value = iterable[i];
              next.done = false;
              return next;
            }
          }

          next.value = undefined;
          next.done = true;

          return next;
        };

        return next.next = next;
      }
    }

    // Return an iterator with no values.
    return { next: doneResult };
  }
  exports.values = values;

  function doneResult() {
    return { value: undefined, done: true };
  }

  Context.prototype = {
    constructor: Context,

    reset: function(skipTempReset) {
      this.prev = 0;
      this.next = 0;
      // Resetting context._sent for legacy support of Babel's
      // function.sent implementation.
      this.sent = this._sent = undefined;
      this.done = false;
      this.delegate = null;

      this.method = "next";
      this.arg = undefined;

      this.tryEntries.forEach(resetTryEntry);

      if (!skipTempReset) {
        for (var name in this) {
          // Not sure about the optimal order of these conditions:
          if (name.charAt(0) === "t" &&
              hasOwn.call(this, name) &&
              !isNaN(+name.slice(1))) {
            this[name] = undefined;
          }
        }
      }
    },

    stop: function() {
      this.done = true;

      var rootEntry = this.tryEntries[0];
      var rootRecord = rootEntry.completion;
      if (rootRecord.type === "throw") {
        throw rootRecord.arg;
      }

      return this.rval;
    },

    dispatchException: function(exception) {
      if (this.done) {
        throw exception;
      }

      var context = this;
      function handle(loc, caught) {
        record.type = "throw";
        record.arg = exception;
        context.next = loc;

        if (caught) {
          // If the dispatched exception was caught by a catch block,
          // then let that catch block handle the exception normally.
          context.method = "next";
          context.arg = undefined;
        }

        return !! caught;
      }

      for (var i = this.tryEntries.length - 1; i >= 0; --i) {
        var entry = this.tryEntries[i];
        var record = entry.completion;

        if (entry.tryLoc === "root") {
          // Exception thrown outside of any try block that could handle
          // it, so set the completion value of the entire function to
          // throw the exception.
          return handle("end");
        }

        if (entry.tryLoc <= this.prev) {
          var hasCatch = hasOwn.call(entry, "catchLoc");
          var hasFinally = hasOwn.call(entry, "finallyLoc");

          if (hasCatch && hasFinally) {
            if (this.prev < entry.catchLoc) {
              return handle(entry.catchLoc, true);
            } else if (this.prev < entry.finallyLoc) {
              return handle(entry.finallyLoc);
            }

          } else if (hasCatch) {
            if (this.prev < entry.catchLoc) {
              return handle(entry.catchLoc, true);
            }

          } else if (hasFinally) {
            if (this.prev < entry.finallyLoc) {
              return handle(entry.finallyLoc);
            }

          } else {
            throw new Error("try statement without catch or finally");
          }
        }
      }
    },

    abrupt: function(type, arg) {
      for (var i = this.tryEntries.length - 1; i >= 0; --i) {
        var entry = this.tryEntries[i];
        if (entry.tryLoc <= this.prev &&
            hasOwn.call(entry, "finallyLoc") &&
            this.prev < entry.finallyLoc) {
          var finallyEntry = entry;
          break;
        }
      }

      if (finallyEntry &&
          (type === "break" ||
           type === "continue") &&
          finallyEntry.tryLoc <= arg &&
          arg <= finallyEntry.finallyLoc) {
        // Ignore the finally entry if control is not jumping to a
        // location outside the try/catch block.
        finallyEntry = null;
      }

      var record = finallyEntry ? finallyEntry.completion : {};
      record.type = type;
      record.arg = arg;

      if (finallyEntry) {
        this.method = "next";
        this.next = finallyEntry.finallyLoc;
        return ContinueSentinel;
      }

      return this.complete(record);
    },

    complete: function(record, afterLoc) {
      if (record.type === "throw") {
        throw record.arg;
      }

      if (record.type === "break" ||
          record.type === "continue") {
        this.next = record.arg;
      } else if (record.type === "return") {
        this.rval = this.arg = record.arg;
        this.method = "return";
        this.next = "end";
      } else if (record.type === "normal" && afterLoc) {
        this.next = afterLoc;
      }

      return ContinueSentinel;
    },

    finish: function(finallyLoc) {
      for (var i = this.tryEntries.length - 1; i >= 0; --i) {
        var entry = this.tryEntries[i];
        if (entry.finallyLoc === finallyLoc) {
          this.complete(entry.completion, entry.afterLoc);
          resetTryEntry(entry);
          return ContinueSentinel;
        }
      }
    },

    "catch": function(tryLoc) {
      for (var i = this.tryEntries.length - 1; i >= 0; --i) {
        var entry = this.tryEntries[i];
        if (entry.tryLoc === tryLoc) {
          var record = entry.completion;
          if (record.type === "throw") {
            var thrown = record.arg;
            resetTryEntry(entry);
          }
          return thrown;
        }
      }

      // The context.catch method must only be called with a location
      // argument that corresponds to a known catch block.
      throw new Error("illegal catch attempt");
    },

    delegateYield: function(iterable, resultName, nextLoc) {
      this.delegate = {
        iterator: values(iterable),
        resultName: resultName,
        nextLoc: nextLoc
      };

      if (this.method === "next") {
        // Deliberately forget the last sent value so that we don't
        // accidentally pass it on to the delegate.
        this.arg = undefined;
      }

      return ContinueSentinel;
    }
  };

  // Regardless of whether this script is executing as a CommonJS module
  // or not, return the runtime object so that we can declare the variable
  // regeneratorRuntime in the outer scope, which allows this module to be
  // injected easily by `bin/regenerator --include-runtime script.js`.
  return exports;

}(
  // If this script is executing as a CommonJS module, use module.exports
  // as the regeneratorRuntime namespace. Otherwise create a new empty
  // object. Either way, the resulting object will be used to initialize
  // the regeneratorRuntime variable at the top of this file.
   true ? module.exports : undefined
));

try {
  regeneratorRuntime = runtime;
} catch (accidentalStrictMode) {
  // This module should not be running in strict mode, so the above
  // assignment should always work unless something is misconfigured. Just
  // in case runtime.js accidentally runs in strict mode, in modern engines
  // we can explicitly access globalThis. In older engines we can escape
  // strict mode using a global Function call. This could conceivably fail
  // if a Content Security Policy forbids using Function, but in that case
  // the proper solution is to fix the accidental strict mode problem. If
  // you've misconfigured your bundler to force strict mode and applied a
  // CSP to forbid Function, and you're not willing to fix either of those
  // problems, please detail your unique predicament in a GitHub issue.
  if (typeof globalThis === "object") {
    globalThis.regeneratorRuntime = runtime;
  } else {
    Function("r", "regeneratorRuntime = r")(runtime);
  }
}


/***/ }),
/* 81 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";

// EXTERNAL MODULE: ./node_modules/absol-brace/BraceExternal/ace.css
var ace = __webpack_require__(333);

// CONCATENATED MODULE: ./node_modules/absol-brace/BraceExternal/FBraceEditor.js
function FBraceEditor() {
    // this.on('change', function(){
    //     console.log(new Error())
    // });
    // console.log(this)
}

FBraceEditor.prototype.$onLineCountChange = function () {
    // console.log(this);
};


FBraceEditor.prototype.getLineCount = function () {
    var session = this.getSession();
    return session.$rowLengthCache.length;
};

/* harmony default export */ var BraceExternal_FBraceEditor = (FBraceEditor);
// CONCATENATED MODULE: ./node_modules/absol-brace/BraceExternal/FEditSession.js
function FEditSession() {

}


FEditSession.prototype.gutterRenderer = {
    getWidth: function (session, lastLineNumber, config) {
       
        return session.getLineCount().toString().length * config.characterWidth;
    },
    getText: function (session, row) {
        return row + 1;
    }
};


FEditSession.prototype.getLineCount = function(){
    return this.$rowLengthCache.length;
};


/* harmony default export */ var BraceExternal_FEditSession = (FEditSession);
// CONCATENATED MODULE: ./node_modules/absol-brace/BraceExternal/FBrace.js



var FBrace_ace = window.ace ||{};

var aceEdit = FBrace_ace && FBrace_ace.edit;

FBrace_ace.edit = function(){
    var editor = aceEdit.apply(this, arguments);
    Object.defineProperties(editor, Object.getOwnPropertyDescriptors(BraceExternal_FBraceEditor.prototype));
    BraceExternal_FBraceEditor.call(editor);
    return editor;
};

Object.defineProperties(FBrace_ace.EditSession.prototype, Object.getOwnPropertyDescriptors(BraceExternal_FEditSession.prototype));

/* harmony default export */ var FBrace = (FBrace_ace);
// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/Dom.js + 1 modules
var Dom = __webpack_require__(1);

// EXTERNAL MODULE: ./node_modules/absol-acomp/AComp.js
var AComp = __webpack_require__(78);

// CONCATENATED MODULE: ./node_modules/absol-brace/components/BCore.js



var BCore = new Dom["b" /* default */]();
BCore.install(AComp["a" /* default */].core);
/* harmony default export */ var components_BCore = (BCore);
// EXTERNAL MODULE: ./node_modules/absol/src/String/stringGenerate.js + 1 modules
var stringGenerate = __webpack_require__(12);

// EXTERNAL MODULE: ./node_modules/absol-brace/BraceDiff/diff.css
var diff = __webpack_require__(335);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/Svg.js
var Svg = __webpack_require__(16);

// CONCATENATED MODULE: ./node_modules/absol-brace/components/Shape.js



function Shape() {
    var res = Svg["a" /* default */].ShareInstance._('path');
    return res;
};

Shape.prototype.begin = function () {
    this.buildingPath = '';
    return this;
};

Shape.prototype.end = function () {
    this.attr('d', this.buildingPath);
    return this;
};


Shape.prototype.moveTo = function (x, y) {
    this.buildingPath += 'M' + x + ' ' + y;
    return this;
};

Shape.prototype.closePath = function () {
    this.buildingPath += 'z';
    return this;
}

Shape.prototype.lineTo = function (x, y) {
    this.buildingPath += 'L' + x + ' ' + y;
    return this;
};


Shape.prototype.arcTo = function (x, y, rx, ry, lf, sf, xRotate) {
    ry = ry || rx;
    lf = lf || 0;
    sf = sf || 0;
    xRotate = xRotate || 0;
    this.buildingPath += 'A' + [rx, ry, xRotate, lf, sf, x, y].join(' ');
    return this;
};

Shape.prototype.curveTo = function (x, y, x0, y0, x1, y1) {
    this.buildingPath += 'C' + [x0, y0, x1, y1, x, y].join(' ');
    return this;
};

components_BCore.install('shape', Shape);
// CONCATENATED MODULE: ./node_modules/absol-brace/components/Icons.js


var _ = components_BCore._;

function MdArrawLeftBold() {
    return _(
    `<svg width="24" height="24" viewBox="0 0 24 24">
        <path d="M20,9V15H12V19.84L4.16,12L12,4.16V9H20Z" />
    </svg>`
    );
}

components_BCore.install('md-arraw-left-bold', MdArrawLeftBold);


function MdArrawRighttBold() {
    return _(
    `<svg width="24" height="24" viewBox="0 0 24 24">
        <path d="M4,15V9H12V4.16L19.84,12L12,19.84V15H4Z" />
    </svg>`
    );
}

components_BCore.install('md-arraw-right-bold', MdArrawRighttBold);


// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/EventEmitter.js
var EventEmitter = __webpack_require__(3);

// CONCATENATED MODULE: ./node_modules/absol-diff/struct/Segment.js
/**
 * 
 * @param {Number} start 
 * @param {Number} end 
 */
function Segment(start, end) {
    if (!(this instanceof Segment)) return new Segment(start, end);
    if (!(start <= end)) throw new Error("Invalid range [" + start + ', ' + end + ']');
    this.start = start;
    this.end = end;
}

/**
 * @param {Segment} other
 * @returns {Boolean}
 */
Segment.prototype.isOverlap = function (other) {
    if (this.start > other.end) return false;
    if (this.end < other.start) return false;
    return true;
};

/**
 * @returns {Number}
 */
Segment.prototype.length = function () {
    return this.end - this.start;
};



/**
 * @param {Segment} other
 * @returns {Segment}
 */
Segment.prototype.merge = function (other) {
    return new Segment(Math.min(this.start, other.start), Math.max(this.end, other.end));
};

/**
 * @param {Segment} other
 * @returns {Segment}
 */

Segment.prototype.betweenSegment = function (other) {
    if (this.start >= other.end) return new Segment(other.end, this.start);
    if (this.end <= other.start) return new Segment(this.end, other.start);
    return null;
};



/**
 * @returns {Segment}
 */
Segment.prototype.clone = function () {
    return new Segment(this.start, this.end);
};

/* harmony default export */ var struct_Segment = (Segment);
// CONCATENATED MODULE: ./node_modules/absol-diff/struct/Trapezium.js


/**
 * 
 * @param {Segment} left 
 * @param {Segment} right 
 */
function Trapezium(left, right, color) {
    if (!(this instanceof Trapezium)) return new Trapezium(left, right, color);
    this.left = left;
    this.right = right;
    this.color = color;
}

/**
 *  @param {Trapezium} other
 * @returns {Trapezium} 
 */
Trapezium.prototype.merge = function (other) {
    return new Trapezium(this.left.merge(other.left), this.right.merge(other.right), this.color)
};

/**
 *  @param {Trapezium} other
 * @returns {Boolean} 
 */
Trapezium.prototype.isOverlap = function (other) {
    return this.right.isOverlap(other.right) && this.left.isOverlap(other.left);
};

/**
 * @returns {Number}
 */
Trapezium.prototype.square = function () {
    return (this.right.length() + this.left.length()) / 2;
};

Trapezium.prototype.clone - function(){
    return new Trapezium(this.left.clone(), this.right.clone(), this.color);
};

/* harmony default export */ var struct_Trapezium = (Trapezium);
// EXTERNAL MODULE: ./node_modules/absol/src/Network/IFrameBridge.js
var IFrameBridge = __webpack_require__(52);

// CONCATENATED MODULE: ./node_modules/absol-brace/BraceDiff/diffworker.js.txt
/* harmony default export */ var diffworker_js = ("!function(t){function e(r){if(n[r])return n[r].exports;var i=n[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,e),i.l=!0,i.exports}var n={};e.m=t,e.c=n,e.d=function(t,n,r){e.o(t,n)||Object.defineProperty(t,n,{enumerable:!0,get:r})},e.r=function(t){\"undefined\"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:\"Module\"}),Object.defineProperty(t,\"__esModule\",{value:!0})},e.t=function(t,n){if(1&n&&(t=e(t)),8&n)return t;if(4&n&&\"object\"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(e.r(r),Object.defineProperty(r,\"default\",{enumerable:!0,value:t}),2&n&&\"string\"!=typeof t)for(var i in t)e.d(r,i,function(e){return t[e]}.bind(null,i));return r},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,\"a\",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p=\"\",e(e.s=0)}([function(t,e,n){t.exports=n(1)},function(t,e,n){\"use strict\";function r(t){return(r=\"function\"==typeof Symbol&&\"symbol\"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&\"function\"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?\"symbol\":typeof t})(t)}function i(){this._azar_extendEvents=this._azar_extendEvents||{supported:{},prioritize:{},nonprioritize:{}},this.__azar_force=\"object\"===(\"undefined\"==typeof Node?\"undefined\":r(Node))?!(this instanceof Node):!(this&&\"object\"===r(this)&&\"number\"==typeof this.nodeType&&\"string\"==typeof this.nodeName)}function o(t){f.call(this),this.detach(),t&&this.attach(t),this.__azarResolveCallbacks={}}function a(t,e){if(!(this instanceof a))return new a(t,e);if(!(t<=e))throw new Error(\"Invalid range [\"+t+\", \"+e+\"]\");this.start=t,this.end=e}function s(t){var e,n=new RegExp([\"(\",v.source,\"+)|(\",y.source,\")|(\",\".\",\")\"].join(\"\"),\"g\"),r=[];do{if(e=n.exec(t)){var i=0;e[1]&&(i=m),e[2]&&(i=_),e[3]&&(i=b),r.push({range:g(e.index,n.lastIndex),value:e[0],score:i+i*e[0].length/1e6})}}while(e);return r}function l(t){var e,n=0;if(0===t.length)return n;for(e=0;e<t.length;e++)n=(n<<5)-n+t.charCodeAt(e),n|=0;return n}function h(t,e){for(var n=Array(t.length+1).fill(null).map(function(){return Array(e.length+1).fill(0)}),r=0;r<t.length;++r)for(var i=0;i<e.length;++i)n[r+1][i+1]=c(n[r][i+1],n[r+1][i]),t[r].value==e[i].value&&(n[r+1][i+1]=c(n[r+1][i+1],n[r][i]+e[i].score));for(var o=[],a=(r=t.length,i=e.length,0);0<r&&0<i&&0!=n[r][i];){for(;n[r][i]==n[r][i-1];)--i;for(;n[r][i]==n[r-1][i];)--r;a+=t[r-1].score,o.push({lToken:t[r-1],rToken:e[i-1]}),--i,--r}return{subExtraMatched:o=o.reverse(),isExtraMatched:o.length==t.length&&o.length==e.length,score:a}}function u(t,e,n){return this instanceof u?(this.left=t,this.right=e,void(this.color=n)):new u(t,e,n)}var c=Math.max,p=(Math.ceil,Math.min);n.r(e),i.prototype.defineEvent=function(t){if(t instanceof Array)for(var e=0;e<t.length;++e)this._azar_extendEvents.supported[t[e]]=!0;else this._azar_extendEvents.supported[t]=!0;return this},i.prototype.isSupportedEvent=function(t){return this.__azar_force||!!this._azar_extendEvents.supported[t]},i.prototype.emit=function(){this.fire.apply(this,arguments)},i.prototype.fire=function(t,e){var n=Array.prototype.slice.call(arguments,1);if(this.isSupportedEvent(t)){var r;if(this._azar_extendEvents.prioritize[t]){r=this._azar_extendEvents.prioritize[t].slice();for(var i=0;i<r.length;++i)try{r[i].wrappedCallback.apply(this,n)}catch(t){console.error(t)}}if(this._azar_extendEvents.nonprioritize[t]){r=this._azar_extendEvents.nonprioritize[t].slice();for(i=0;i<r.length;++i)try{r[i].wrappedCallback.apply(this,n)}catch(t){console.error(t)}}}else{if(!this.dispatchEvent)throw new Error(\"Not support event \"+t);var o=new Event(t);e&&Object.assign(o,e),this.dispatchEvent(o)}return this},i.prototype.eventEmittorOnWithTime=function(t,e,n,i){if(\"object\"==r(e)){for(var o in e)this.eventEmittorOnWithTime(t,o,e[o]);return this}if(\"object\"==r(n))return this.eventEmittorOnWithTime(t,e,n.callback,n.cap);for(var a=this._azar_extendEvents[i?\"prioritize\":\"nonprioritize\"][e]||[],s=-1,l=0;l<a.length;++l)if(a[l].wrappedCallback==n){s=l;break}if(0>s){var h={isOnce:t,eventName:e,callback:n,cap:!!i};h.wrappedCallback=t?function(t){h.callback.call(this,t),this.off(h.eventName,h.wrappedCallback,h.cap)}:h.callback,this.isSupportedEvent(e)||(this.addEventListener?this.addEventListener(e,h.wrappedCallback,!!i):this.attachEvent(\"on\"+e,n,!!i)),a.push(h),this._azar_extendEvents[i?\"prioritize\":\"nonprioritize\"][e]=a}else console.warn(\"dupplicate event\");return this},i.prototype.on=function(t,e,n){return this.eventEmittorOnWithTime(!1,t,e,n),this},i.prototype.once=function(t,e,n){return this.eventEmittorOnWithTime(!0,t,e,n),this},i.prototype.off=function(t,e,n){if(\"object\"==r(t)){for(var i in t)this.off(i,t[i]);return this}if(\"object\"==r(e))return this.off(t,e.callback,e.cap);for(var o,a=this._azar_extendEvents[n?\"prioritize\":\"nonprioritize\"][t]||[],s=[],l=0;l<a.length;++l)(o=a[l]).wrappedCallback==e?this.isSupportedEvent(t)||(this.removeEventListener?this.removeEventListener(o.eventName,o.wrappedCallback,!!o.call):this.detachEvent(\"on\"+o.eventName,o.wrappedCallback,!!o.call)):s.push(o);return this._azar_extendEvents[n?\"prioritize\":\"nonprioritize\"][t]=s,this},i.isMouseRight=function(t){var e=!1;return\"which\"in t?e=3==t.which:\"button\"in t&&(e=2==t.button),e},i.hitElement=function(t,e){for(var n=e.target;n;){if(n==t)return!0;n=n.parentElement}return!1},i.copyEvent=function(t,e){var n={};for(var r in Object.assign(n,t),n)\"function\"==typeof n[r]&&(n[r]=n[r].bind(t));return e&&Object.assign(n,e),n},i.eventProperties=[\"altKey\",\"bubbles\",\"button\",\"buttons\",\"cancelBubble\",\"cancelable\",\"clientX\",\"clientY\",\"composed\",\"ctrlKey\",\"currentTarget\",\"defaultPrevented\",\"deltaMode\",\"deltaX\",\"deltaY\",\"deltaZ\",\"detail\",\"eventPhase\",\"explicitOriginalTarget\",\"isTrusted\",\"layerX\",\"layerY\",\"metaKey\",\"movementX\",\"movementY\",\"mozInputSource\",\"mozPressure\",\"offsetX\",\"offsetY\",\"originalTarget\",\"pageX\",\"pageY\",\"rangeOffset\",\"rangeParent\",\"region\",\"relatedTarget\",\"returnValue\",\"screenX\",\"screenY\",\"shiftKey\",\"srcElement\",\"target\",\"timeStamp\",\"type\",\"deltaMode\",\"deltaX\",\"deltaY\",\"deltaZ\"];var f=i,d=function(){var t=\"qwertyuiopasdfghjklzxcvbnm\";return((t+=t.toUpperCase())+\"_0123456789\").split(\"\")}();o.prototype.attach=function(t){this.host=t,this.host.addEventListener?this.host.addEventListener(\"message\",this.__azarMessageListener.bind(this),!1):this.host.attachEvent?this.host.attachEvent(\"onmessage\",this.__azarMessageListener.bind(this)):this.host.onmessage=this.__azarMessageListener.bind(this),this.__IFrameBridge_resolve()},o.prototype.detach=function(){this.sync=new Promise(function(t){this.__IFrameBridge_resolve=t}.bind(this))},o.fromIFrame=function(t){var e=t.contentWindow||t.contentDocument;if(e)return new o(e);var n=new o,r=function(){var e=t.contentWindow||t.contentDocument;n.attach(e)};return t.addEventListener?t.addEventListener(\"load\",r):t.attachEvent(\"onload\",r),n},o.getInstance=function(){return o.shareInstance||(o.shareInstance=new o(self)),o.shareInstance},Object.defineProperties(o.prototype,Object.getOwnPropertyDescriptors(f.prototype)),o.prototype.constructor=o,o.isInIFrame=function(){return top!==self},o.prototype.__azarMessageListener=function(t){this.__azarHandleData(t.data)},o.prototype.__azarHandleData=function(t){if(t.type)if(\"INVOKE\"==t.type){var e=this.__azarRelfInvoke(t.name,t.params);e&&\"function\"==typeof e.then?e.then(function(e){this.__azarResolve(t.taskId,e)}.bind(this)):this.__azarResolve(t.taskId,e)}else\"INVOKE_RESULT\"==t.type?this.__azarResolveCallbacks[t.taskId]&&(this.__azarResolveCallbacks[t.taskId](t.result),delete this.__azarResolveCallbacks[t.taskId]):\"EMIT\"==t.type?this.fire.apply(this,t.params):this.fire(\"message\",t,this)},o.prototype.__azarResolve=function(t,e){this.host.postMessage({type:\"INVOKE_RESULT\",taskId:t,result:e})},o.prototype.__azarRelfInvoke=function(t,e){return\"function\"==typeof this[t]?this[t].apply(this,e):this[t]},o.prototype.emit=function(){var t=[];return t.push.apply(t,arguments),this.sync.then(function(){this.host.postMessage({type:\"EMIT\",params:t})}.bind(this)),this},o.prototype.invoke=function(t){var e=[];return e.push.apply(e,arguments),e.shift(),this.sync.then(function(){var n=function(t){0<t||(t=4);var e=d;return[e[Math.random()*(e.length-10)>>0]].concat(Array(t-1).fill(\"\").map(function(){return e[Math.random()*e.length>>0]})).join(\"\")}(32);return this.host.postMessage({type:\"INVOKE\",params:e,taskId:n,name:t}),new Promise(function(t){this.__azarResolveCallbacks[n]=t}.bind(this))}.bind(this))},a.prototype.isOverlap=function(t){return!(this.start>t.end||this.end<t.start)},a.prototype.length=function(){return this.end-this.start},a.prototype.merge=function(t){return new a(p(this.start,t.start),c(this.end,t.end))},a.prototype.betweenSegment=function(t){return this.start>=t.end?new a(t.end,this.start):this.end<=t.start?new a(this.end,t.start):null},a.prototype.clone=function(){return new a(this.start,this.end)};var g=a,v=/[\\_a-zA-Z0-9àáạảãâầấậẩẫăằắặẳẵÀÁẠẢÃÂẦẤẬẨẪĂẰẮẶẲẴèéẹẻẽêềếệểễÈÉẸẺẼÊỀẾỆỂỄìíịỉĩÌÍỊỈĨòóọỏõôồốộổỗơờớợởỡÒÓỌỎÕÔỒỐỘỔỖƠỜỚỢỞỠùúụủũưừứựửữÙÚỤỦŨƯỪỨỰỬỮỳýỵỷỹỲÝỴỶỸđĐ\\u0300\\u0301\\u0303\\u0309\\u0323\\u02C6\\u0306\\u031B]/,y=/\\s+/,m=1,b=.99,_=.01;u.prototype.merge=function(t){return new u(this.left.merge(t.left),this.right.merge(t.right),this.color)},u.prototype.isOverlap=function(t){return this.right.isOverlap(t.right)&&this.left.isOverlap(t.left)},u.prototype.square=function(){return(this.right.length()+this.left.length())/2},u.prototype.clone;var E=u,z=1,w=-1,k=o.getInstance();k.diffByLine=function(t,e){return function(t,e){function n(t,e){for(var n=0,r=0;r<t.length;++r)0<t[r].trim().length&&++n;return{index:e,text:t,value:l(t),score:0==n?.01:1+n/1e6}}var r=t.split(/\\r?\\n/),i=e.split(/\\r?\\n/),o={lLines:r,rLines:i},a=r.map(n),s=i.map(n),u=h(a,s).subExtraMatched.reduce(function(t,e){var n=t[t.length-1],r=E(g(e.lToken.index,e.lToken.index+1),g(e.rToken.index,e.rToken.index+1),z);if(n.isOverlap(r))n=n.merge(r),t[t.length-1]=n;else{var i=r.left.betweenSegment(n.left),o=r.right.betweenSegment(n.right);0<(n=E(i,o,w)).square()&&t.push(n),t.push(r)}return t},[E(g(0,0),g(0,0),z)]),c=u[u.length-1];return(c.left.end<a.length||c.right.end<s.length)&&u.push(E(g(c.left.end,a.length),g(c.right.end,s.length),w)),u=u.filter(function(t){return 0<t.square()}),o.trapeziumes=u,o}(t,e)},k.diffByWord=function(t,e){return function(t,e){if(t==e)return[E(g(0,t.length),g(0,e.length),z)];var n=h(s(t),s(e)).subExtraMatched.reduce(function(t,e){var n=t.last,r=n.left.betweenSegment(e.lToken.range),i=n.right.betweenSegment(e.rToken.range),o=new E(r,i);return 0<o.square()&&(o.color=w,t.result.push(o)),(o=new E(e.lToken.range,e.rToken.range)).color=z,t.result.push(o),t.last=o,t},{result:[],last:E(g(0,0),g(0,0))}),r=g(n.last.left.end,t.length),i=g(n.last.right.end,e.length),o=new E(r,i);return o.color=w,n.result.push(o),n.result.filter(function(t){return 0<t.square()}).reduce(function(n,r){if(r.color==z)n.push(r);else{var i,o=t.substring(r.left.start,r.left.end),a=e.substring(r.right.start,r.right.end),s=function(t,e){for(var n=0,r=0,i=0;r<t.length&&i<e.length&&t[r]==e[i];)++n,++r,++i;return n}(o,a),l=function(t,e){for(var n=0,r=t.length,i=e.length;0<r&&0<i&&(--i,t[--r]==e[i]);)++n;return n}(o,a);s+l<p(o.length,a.length)?(0<s&&((i=E(g(r.left.start,r.left.start+s),g(r.right.start,r.right.start+s))).color=z,n.push(i)),(i=E(g(r.left.start+s,r.left.end-l),g(r.right.start+s,r.right.end-l))).color=w,n.push(i),0<l&&((i=E(g(r.left.end-l,r.left.end),g(r.right.end-l,r.right.end))).color=z,n.push(i))):l>s?((i=E(g(r.left.start,r.left.end-l),g(r.right.start,r.right.end-l))).color=w,n.push(i),(i=E(g(r.left.end-l,r.left.end),g(r.right.end-l,r.right.end))).color=z,n.push(i)):(0<s&&((i=E(g(r.left.start,r.left.start+s),g(r.right.start,r.right.start+s))).color=z,n.push(i)),(i=E(g(r.left.start+s,r.left.end),g(r.right.start+s,r.right.end))).color=w,n.push(i))}return n},[]).reduce(function(t,e){if(0==t.length)return t.push(e),t;var n=t[t.length-1];if(n.color==e.color){var r=n.merge(e);r.color=n.color,t[t.length-1]=r}else t.push(e);return t},[])}(t,e)}}]);");
// CONCATENATED MODULE: ./node_modules/absol-brace/BraceDiff/BraceDiff.js

















const Range = FBrace && FBrace.acequire('ace/range').Range;

var $ = components_BCore.$;
var BraceDiff_ = components_BCore._;

/**
 * @typedef {Object} BraceDiffOption
 * @property {String} element selector query | HTML element
 * @property {BraceDiffOptionLeft} left
 * @property {BraceDiffOptionLeft} right
 * @property {IFrameBridge} diffWorker
 *  
 * 
 *  
 * @param {BraceDiffOption} props 
 */

function BraceDiff(props) {
    if (!(this instanceof BraceDiff)) return new BraceDiff(props);
    EventEmitter["b" /* default */].call(this);
    this.ready = false;
    this.props = props;
    this.props.left = this.props.left || {};
    this.props.right = this.props.right || {};

    this.editorLeft = null;
    this.editorRight = null;
    this.$element = null;
    this.diffWorker = props.diffWorker;
    if (!this.diffWorker) {
        var workerUrl = (URL || webkitURL).createObjectURL(new Blob([diffworker_js], { type: 'application/javascript' }));
        this.diffWorker = new IFrameBridge["a" /* default */](new Worker(workerUrl));
    }
    this.lastFocusEditor = null;
    this._changeTimeOut = false;
    this._attachedTo(props.element);

}

Object.defineProperties(BraceDiff.prototype, Object.getOwnPropertyDescriptors(EventEmitter["b" /* default */].prototype));
BraceDiff.prototype.constructor = BraceDiff;


BraceDiff.prototype._attachedTo = function (elt) {
    var _this = this;
    if (typeof elt == 'string') {
        elt = $(elt);
        if (elt) {
            this.edit(elt);
        }
        else {
            throw new Error('Can not find ' + elt);
        }

    }
    else if (Dom["b" /* default */].isDomNode(elt)) {
        if ($(elt).isDescendantOf(document.body)) {
            this.edit(elt);
        }
        else {
            BraceDiff_('attachhook').on('error', function (event) {
                this.remove();
                _this.edit(elt);
            }).addTo(elt);
        }
    }
    else
        throw new Error('Invalid element');
};

/**
 * @param {Element} element
 */
BraceDiff.prototype.edit = function (element) {
    this.$element = element.addClass('brace-diff');
    this.$element.updateSize = function () {
        this.updateForegroundSize();
        this.updateGap(this);
    }.bind(this);
    Dom["b" /* default */].addToResizeSystem(this.$element);
    this.$leftPreCtn = BraceDiff_('.brace-diff-left-container').addTo(this.$element);
    this.$rightPreCtn = BraceDiff_('.brace-diff-right-container').addTo(this.$element);
    this.$middleToolCtn = BraceDiff_('.brace-diff-middle-tool-container').addTo(this.$element);
    this.$middleTool = BraceDiff_('.brace-diff-middle-tool').addTo(this.$middleToolCtn);
    this._leftPreId = Object(stringGenerate["randomIdent"])(20);
    this._rightPreId = Object(stringGenerate["randomIdent"])(20);
    this.$leftPre = BraceDiff_('pre.brace-diff-left#' + this._leftPreId).addTo(this.$leftPreCtn);
    this.$rightPre = BraceDiff_('pre.brace-diff-left#' + this._rightPreId).addTo(this.$rightPreCtn);
    this.editorLeft = FBrace.edit(this._leftPreId);
    this.editorRight = FBrace.edit(this._rightPreId);
    this.$foreGround = BraceDiff_('.brace-diff-foreground').addTo(this.$element);

    this.$canvas = BraceDiff_('svg').addTo(this.$foreGround);
    this.$poolGap = [];
    this.$activeGaps = [];


    this.$poolLeftArrowBtn = [];
    this.$poolRightArrowBtn = [];
    this.$activePickLeftBtn = [];
    this.$activePickRightBtn = [];
    this.updateForegroundSize();

    this._setupEditors();
    this.ready = true;
    this.emit('ready', { target: this }, this);
    return this;
};

BraceDiff.prototype._setupEditors = function () {
    var self = this;
    this.editorLeft.setOptions(Object.assign({}, this.props.option, this.props.left.option));
    this.editorRight.setOptions(Object.assign({}, this.props.option, this.props.right.option));
    this.editorLeft.$blockScrolling = Infinity;
    this.editorRight.$blockScrolling = Infinity;
    this.editorLeft.on('change', this.handleChange.bind(this));
    this.editorRight.on('change', this.handleChange.bind(this));

    if (this.props.left.value) {
        this.editorLeft.setValue(this.props.left.value);
    }
    if (this.props.right.value) {
        this.editorRight.setValue(this.props.right.value);
    }

    this.editorLeft.getSession().on('changeScrollTop', function (scroll) {
        self.updateGap();
    });
    this.editorRight.getSession().on('changeScrollTop', function (scroll) {
        self.updateGap();
    });

    this.editorLeft.on('focus', function (data) {
        self.lastFocusEditor = self.editorLeft;
    });

    this.editorRight.on('focus', function (data) {
        self.lastFocusEditor = self.editorRight;
    });
    if (this.props.right.focus)
        this.editorRight.focus();
    else
        this.editorLeft.focus();
};



BraceDiff.prototype.updateForegroundSize = function () {
    var bound = this.$foreGround.getBoundingClientRect();
    this.$canvas.attr({
        width: bound.width + 'px',
        height: bound.height + 'px'
    });
};


/**
 * @param {Trapeziume} trapeziume
 */
BraceDiff.prototype.pickLeft = function (trapeziume) {
    if (!this.diffData) return;
    //todo
    var newTextLines = this.diffData.lLines.slice(trapeziume.left.start, trapeziume.left.end);

    if (newTextLines.length == 0) {
        var removeRange;
        if (trapeziume.right.end >= this.diffData.rLines.length) {
            //remove to end
            removeRange = new Range(trapeziume.right.start - 1, Number.MAX_VALUE, trapeziume.right.end, 0);
        }
        else {
            removeRange = new Range(trapeziume.right.start, 0, trapeziume.right.end, 0);
        }
        this.editorRight.getSession().remove(removeRange);
    }
    else {
        var newText = newTextLines.join('\n');
        var replaceRange = new Range(trapeziume.right.start, 0, trapeziume.right.end - 1, Number.MAX_VALUE);
        if (trapeziume.right.start >= this.diffData.rLines.length) {
            newText = '\n' + newText;//newLine
        }
        else if (newText.length == 0 && trapeziume.right.start == trapeziume.right.end) {
            replaceRange = new Range(trapeziume.right.start, 0, trapeziume.right.end, 0);
            newText = '\n'

        }
        this.editorRight.getSession().replace(replaceRange, newText);
    }
};

/**
 * @param {Trapeziume} trapeziume
 */
BraceDiff.prototype.pickRight = function (trapeziume) {
    if (!this.diffData) return;
    //todo
    var newTextLines = this.diffData.rLines.slice(trapeziume.right.start, trapeziume.right.end);

    if (newTextLines.length == 0) {
        var removeRange;
        if (trapeziume.left.end >= this.diffData.lLines.length) {
            //remove to end
            removeRange = new Range(trapeziume.left.start - 1, Number.MAX_VALUE, trapeziume.left.end, 0);
        }
        else {
            removeRange = new Range(trapeziume.left.start, 0, trapeziume.left.end, 0);
        }
        this.editorLeft.getSession().remove(removeRange);
    }
    else {
        var replaceRange = new Range(trapeziume.left.start, 0, trapeziume.left.end - 1, Number.MAX_VALUE);
        var newText = newTextLines.join('\n');
        if (trapeziume.left.start >= this.diffData.lLines.length) {
            newText = '\n' + newText;//newLine
        }
        else if (newText.length == 0 && trapeziume.left.start == trapeziume.left.end) {
            replaceRange = new Range(trapeziume.left.start, 0, trapeziume.left.end, 0);
            newText = '\n';
        }
        this.editorLeft.getSession().replace(replaceRange, newText);
    }
};

BraceDiff.prototype.updateDiffLine = function (diffData) {
    this.diffData = diffData;

    this.iniGap();
    this.updateGap();
};

BraceDiff.prototype.getCurrentTrapeziume = function () {
    if (!this.diffData) return
    var cursorLeftPos = this.editorLeft.getCursorPosition();
    var cursorRightPos = this.editorRight.getCursorPosition();
    var trapeziumes = this.diffData.trapeziumes;
    var trapeziume = null;
    // if (this.lastFocusEditor == this.editorRight) {
    //     for (var i = 0; i < trapeziumes.length; ++i) {
    //         if (trapeziume.right.start >= ){

    //         }
    //     }
    // }
    // else {

    // }

    return trapeziume;
};

BraceDiff.prototype._createLeftArrowBtn = function () {
    return BraceDiff_({
        tag: 'button',
        class: ['brace-diff-arrow', 'pick-right'],
        child: 'md-arraw-left-bold'
    });
};

BraceDiff.prototype._createRightArrowBtn = function () {
    return BraceDiff_({
        tag: 'button',
        class: ['brace-diff-arrow', 'pick-left'],
        child: 'md-arraw-right-bold'
    });
};

BraceDiff.prototype.iniGap = function () {
    if (!this.diffData) return;
    var diffData = this.diffData;
    var self = this;
    this.$activeGaps.forEach(function (elt) { elt.remove(); self.$poolGap.push(elt) });
    this.$activePickLeftBtn.forEach(function (elt) { elt.remove(); self.$poolLeftArrowBtn.push(elt) });
    this.$activePickRightBtn.forEach(function (elt) { elt.remove(); self.$poolRightArrowBtn.push(elt) });
    this.$activeGaps = [];
    this.$activePickLeftBtn = [];
    this.$activePickRightBtn = [];


    diffData.trapeziumes.forEach(function (trp, i, trapeziumes) {
        if (trp.color == -1) {
            var $gap;
            if (self.$poolGap.length > 0) {
                $gap = self.$poolGap.pop();
            }
            else {
                $gap = BraceDiff_('shape.brace-diff-gap');
            }
            $gap.addTo(self.$canvas);
            self.$activeGaps.push($gap);
            trp.$gap = $gap;

            //left
            var $pickLeftBtn;
            var $pickRightBtn;
            if (self.$poolLeftArrowBtn.length > 0) {
                $pickLeftBtn = self.$poolLeftArrowBtn.pop();
            }
            else {
                $pickLeftBtn = self._createRightArrowBtn();
            }

            $pickLeftBtn.addTo(self.$middleTool);
            self.$activePickLeftBtn.push($pickLeftBtn);
            trp.$pickLeftBtn = $pickLeftBtn;
            $pickLeftBtn.onclick = function () {
                self.pickLeft(trp);
                $gap.remove();
                $pickLeftBtn.remove();
                $pickRightBtn.remove();
            }

            //right
            if (self.$poolRightArrowBtn.length > 0) {
                $pickRightBtn = self.$poolRightArrowBtn.pop();
            }
            else {
                $pickRightBtn = self._createLeftArrowBtn();
            }

            $pickRightBtn.addTo(self.$middleTool);
            self.$activePickRightBtn.push($pickRightBtn);
            trp.$pickRightBtn = $pickRightBtn;
            $pickRightBtn.onclick = function () {
                self.pickRight(trp);
                $gap.remove();
                $pickLeftBtn.remove();
                $pickRightBtn.remove();
            }
        }
    });

};

BraceDiff.prototype.updateGap = function () {
    //donothing
    if (!this.diffData) return;
    var diffData = this.diffData;
    var self = this;
    var leftScrollTop = self.editorLeft.renderer.scrollTop;
    var rightScrollTop = self.editorRight.renderer.scrollTop;
    var lineHeight = this.editorLeft.renderer.lineHeight;
    var bound = this.$foreGround.getBoundingClientRect();
    var diffWidth = bound.width;
    var editorWidth = this.$leftPre.getBoundingClientRect().width;
    var editorDist = diffWidth - 2 * editorWidth;

    diffData.trapeziumes.forEach(function (trp) {
        if (trp.$gap) {
            trp.$gap.begin()
                .moveTo(0, - leftScrollTop + trp.left.start * lineHeight)
                .lineTo(editorWidth, - leftScrollTop + trp.left.start * lineHeight)
                .curveTo(diffWidth - editorWidth, - rightScrollTop + trp.right.start * lineHeight,
                    editorWidth + editorDist / 2, - leftScrollTop + trp.left.start * lineHeight,
                    diffWidth - editorWidth - editorDist / 2,
                    - rightScrollTop + trp.right.start * lineHeight
                )
                .lineTo(diffWidth, - rightScrollTop + trp.right.start * lineHeight)
                .lineTo(diffWidth, - rightScrollTop + trp.right.end * lineHeight)
                .lineTo(diffWidth - editorWidth, - rightScrollTop + trp.right.end * lineHeight)

                .curveTo(editorWidth, - leftScrollTop + trp.left.end * lineHeight,
                    diffWidth - editorWidth - editorDist / 2, - rightScrollTop + trp.right.end * lineHeight,
                    editorWidth + editorDist / 2, - leftScrollTop + trp.left.end * lineHeight
                )

                .lineTo(0, - leftScrollTop + trp.left.end * lineHeight)
                .closePath()
                .end();
            trp.$pickLeftBtn.addStyle('top', ((- leftScrollTop + trp.left.start * lineHeight) + (- leftScrollTop + trp.left.end * lineHeight)) / 2 - 7 + 'px');
            trp.$pickRightBtn.addStyle('top', ((- rightScrollTop + trp.right.start * lineHeight) + (- rightScrollTop + trp.right.end * lineHeight)) / 2 - 7 + 'px');
        }
    });
};



BraceDiff.prototype.handleChange = function () {
    if (this._changeTimeOut) {
        clearTimeout(this._changeTimeOut);
    }
    var self = this;
    this._changeTimeOut = setTimeout(function () {
        var currentSession = Math.random();
        self._workSession = currentSession;
        if (self._inWorking) return;
        self._inWorking = true;
        self._changeTimeOut = false;
        var leftData = self.editorLeft.getValue();
        var rightData = self.editorRight.getValue();
        self.diffWorker.invoke('diffByLine', leftData, rightData).then(function(result){
            self.updateDiffLine(result);
            self._inWorking = false;
            if (currentSession != self._workSession) self.handleChange();
        });
    }, 5);
};



BraceDiff.prototype.getEditors = function () {
    return [this.editorLeft, this.editorRight];
};

BraceDiff.prototype.destroy = function(){
    this.editorLeft.destroy();
    this.editorRight.destroy();
    this.destroyed = true;
};

/* harmony default export */ var BraceDiff_BraceDiff = (BraceDiff);
// CONCATENATED MODULE: ./node_modules/absol-brace/index.js





var AbsolBrace = {
    core: components_BCore,
    ace: FBrace,
    BraceDiff: BraceDiff_BraceDiff
};


/* harmony default export */ var absol_brace = __webpack_exports__["a"] = (AbsolBrace);



/***/ }),
/* 82 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/tabview.css
var tabview = __webpack_require__(83);

// EXTERNAL MODULE: ./node_modules/absol-acomp/ACore.js
var ACore = __webpack_require__(0);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/OOP.js
var OOP = __webpack_require__(2);

// EXTERNAL MODULE: ./node_modules/absol/src/String/stringGenerate.js + 1 modules
var stringGenerate = __webpack_require__(12);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/Dom.js + 1 modules
var Dom = __webpack_require__(1);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TabButton.js





var _ = ACore["d" /* default */]._;
var $ = ACore["d" /* default */].$;

/***
 * @extends AElement
 * @constructor
 */
function TabButton() {
    var thisTB = this;
    this._icon = null;
    this.$extIconCtn = $('.as-tab-bar-button-ext-icon-ctn', this);
    this.$close = $('.absol-tabbar-button-close', this)
    this.$iconCtn = $('.absol-tabbar-button-icon-container', this).on('click', function (event) {
        event.tabButtonEventName = 'delete';
        thisTB.emit('close', event);
    });
    this.$modifiedFlag = $('.absol-tabbar-button-modified-flag', this)
        .on('click', function (event) {
            event.tabButtonEventName = 'delete';
            thisTB.emit('close', event);
        });

    this.$textView = $('.absol-tabbar-button-text', this);
    this.on({
        click: function (event) {
            if (event.tabButtonEventName) return;
            event.tabButtonEventName = 'active';
            thisTB.emit('active', event);
        }
    });
}


TabButton.tag = 'TabButton'.toLowerCase();

TabButton.render = function () {
    return _({
        tag: 'button',
        class: 'absol-tabbar-button',
        extendEvent: ['close', 'active'],
        id: Object(stringGenerate["randomIdent"])(20),
        child: [
            {
                class: 'as-tab-bar-button-ext-icon-ctn'
            },
            {
                class: 'absol-tabbar-button-text',
            },
            {
                class: 'absol-tabbar-button-icon-container',
                child: [
                    {
                        tag: 'span',
                        class: ['absol-tabbar-button-close', 'mdi-close', 'mdi'],
                        attr: { title: 'Close' }
                    },
                    {
                        tag: 'span',
                        class: ['absol-tabbar-button-close-circle', 'mdi-close-circle', 'mdi'],
                        attr: { title: 'Close' }
                    },
                    {
                        tag: 'span',
                        class: ['absol-tabbar-button-modified-flag', 'mdi', 'mdi-checkbox-blank-circle']
                    }
                ]
            }
        ]
    });
};


TabButton.property = {};
TabButton.property.active = {
    set: function (value) {
        this._active = value;
        if (value)
            this.addClass('absol-tabbar-button-active');
        else
            this.removeClass('absol-tabbar-button-active');
    },
    get: function () {
        return this._active;
    }
};


TabButton.property.name = {
    set: function (value) {
        this._name = value || '';
        this.$textView.innerHTML = this._name;

    },
    get: function () {
        return this._name;
    }
};


TabButton.property.desc = {
    set: function (value) {
        this.attr('title', value);
    },
    get: function () {
        return this.attr('title');
    }
};

TabButton.property.icon = {
    set: function (value) {
        value = value || null;
        this._icon = value;
        this.$extIconCtn.clearChild();
        if (this._icon) {
            this.$extIconCtn.addChild(_(value));
        }
    },
    get: function () {
        return this._icon;
    }
}


TabButton.property.modified = {
    set: function (value) {
        if (value) {
            this.addClass('absol-tabbar-button-modified');
        }
        else {
            this.removeClass('absol-tabbar-button-modified');
        }
    },
    get: function () {
        return this.containsClass('absol-tabbar-button-modified');
    }
};

ACore["d" /* default */].install(TabButton);

/* harmony default export */ var js_TabButton = (TabButton);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TabBar.js




var TabBar_ = ACore["d" /* default */]._;
var TabBar_$ = ACore["d" /* default */].$;


function TabBar() {
    this.defineEvent(['active', 'close']);
    this.on('wheel', function (event) {
        var lastLeft = this.$viewport.scrollLeft;
        if (event.deltaY > 1) {
            this.$viewport.scrollLeft += 50;
        }
        else if (event.deltaY < -1) {
            this.$viewport.scrollLeft -= 50;
        }
        if (lastLeft != this.$viewport.scrollLeft)
            event.preventDefault();
    });
    this._tabs = [];
}

TabBar.tag = 'tabbar';

TabBar.render = function () {
    return TabBar_('hscroller.absol-tabbar');
};

TabBar.prototype.getAllTabButtons = function () {
    var buttons = [];
    TabBar_$('tabbutton', this, function (e) {
        buttons.push(e);
    });
    return buttons;
};

/***
 *
 * @param {string} ident
 * @return {TabButton}
 */
TabBar.prototype.getButtonByIdent = function (ident) {
    return TabBar_$('tabbutton#tabbuton-' + ident, this);
};


TabBar.property = {};

TabBar.property.tabs = {
    set: function (value) {
        this.clearChild();
        this._tabs = [];
        (value || []).forEach(this.addTab.bind(this));
    },
    get: function () {
        //each hold item data
        return this._tabs || [];
    }
};


/***
 *
 * @param {{text}}
 * @return {tabbar}
 */
TabBar.prototype.addTab = function (value) {
    var self = this;
    var props = {};
    if (typeof value == "string") {
        props.name = value;
    }
    else {
        if (value.name) {
            props.name = value.name;
        }
        else {
            throw new Error('Tab must has name attribute');
        }
        if (value.desc)
            props.desc = value.desc;
        if (value.tabIcon) {
            props.icon = value.tabIcon;
        }
    }


    var tabButton = TabBar_({
        tag: 'tabbutton',
        props: props,
        on: {
            active: function (event, sender) {
                var prevented = false;
                self.emit('active', {
                    target: this,
                    value: value,
                    preventDefault: function () {
                        prevented = true;
                    }
                }, self);
                if (!prevented) {
                    self.getAllTabButtons().forEach(function (e) {
                        e.active = false;
                    });
                    this.active = true;
                }
            },
            close: function (event, sender) {
                var prevented = false;
                self.emit('close', {
                    target: this, value: value,
                    preventDefault: function () {
                        prevented = true;
                    }
                }, self);
                if (!prevented) {
                    //todo:active other
                    this.remove();
                }
            }
        }
    }).addTo(this);
    if (value.id) tabButton.attr('id', 'tabbuton-' + value.id);
    this._tabs.push(tabButton);
    this.requestUpdateSize();
    return tabButton;
};


TabBar.prototype.removeTab = function (id) {
    this._tabs = this._tabs.filter(function (value) {
        return value == id;
    });
    TabBar_$('#tabbuton-' + id, this).remove();
    this.requestUpdateSize();
};


TabBar.prototype.activeTab = function (id) {
    var self = this;
    var activedbtn = TabBar_$('.absol-tabbar-button-active', this);
    if (activedbtn && activedbtn.attr('id') != id) {
        activedbtn.active = false;
    }
    var mButton = TabBar_$('#tabbuton-' + id, this);
    if (mButton) {
        mButton.active = true;
        setTimeout(function () {
            self.scrollInto(mButton);
        }, 30)
    }

};

TabBar.prototype.setModified = function (ident, flag) {
    var bt = this.getButtonByIdent(ident);
    if (bt) {
        bt.modified = flag;
    }
};


ACore["d" /* default */].install(TabBar);

/* harmony default export */ var js_TabBar = (TabBar);
// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TabView.js





var TabView_ = ACore["d" /* default */]._;
var TabView_$ = ACore["d" /* default */].$;


function TabView() {
    var thisTV = this;
    /***
     *
     * @type {TabBar}
     */
    this.$tabbar = TabView_$('tabbar', this);
    this.$tabbar.on({
        close: TabView.eventHandler.closeTab.bind(thisTV),
        active: TabView.eventHandler.activeTab.bind(thisTV)
    });
    this._frameHolders = [];
    this._history = [];
}

TabView.tag = 'TabView'.toLowerCase();

TabView.render = function () {
    return TabView_({
        class: 'absol-tabview',
        extendEvent: ['activetab', 'deactivetab', 'removetab', 'requestremovetab'],
        child: [
            'tabbar'
        ]
    });
};


TabView.eventHandler = {};

TabView.eventHandler.closeTab = function (event) {
    event.preventDefault();
    var id = event.value.id;
    this.removeTab(id, true);
};

TabView.eventHandler.activeTab = function (event) {
    event.preventDefault();
    var id = event.value.id;
    this.activeTab(id, true);
};

TabView.prototype.activeTab = function (id, userActive) {
    var self = this;
    var resPromise = [];
    var needDeactiveHolder = [];
    var needActiveHolder = [];
    this._frameHolders.forEach(function (holder) {
        if (holder.containerElt.containsClass('absol-tabview-container-hidden')) {
            if (holder.id == id) {
                needActiveHolder.push(holder);
            }
        }
        else {
            if (holder.id != id) {
                needDeactiveHolder.push(holder);
            }
        }
    });

    needDeactiveHolder.forEach(function (holder) {
        holder.containerElt.addClass('absol-tabview-container-hidden');
        holder.tabFrame.emit('deactive', {
            type: 'deactive',
            target: holder.tabFrame,
            id: holder.id,
            userActive: !!userActive,
            tabButton: holder.tabButton,
            holder: holder
        }, holder.tabFrame);
    });

    needActiveHolder.forEach(function (holder) {
        self._history.push(holder.id);
        holder.containerElt.removeClass('absol-tabview-container-hidden');
        self.$tabbar.activeTab(holder.id);
        holder.tabFrame.emit('active', {
            type: 'active',
            target: holder.tabFrame,
            id: holder.id,
            userActive: !!userActive,
            tabButton: holder.tabButton,
            holder: holder
        }, holder.tabFrame);
        self.emit('activetab', {
            type: 'activetab',
            target: self,
            id: holder.id,
            userActive: !!userActive,
            tabButton: holder.tabButton,
            holder: holder
        }, self);
    });
};

TabView.prototype.removeTab = function (id, userActive) {
    var self = this;
    var resPromise = [];
    this._frameHolders.forEach(function (holder) {
        if (holder.id == id) {
            var eventData = {
                type: 'requestremove',
                id: id,
                userActive: !!userActive,
                target: holder.tabFrame,
                tabFrame: holder.tabFrame,
                tabButton: holder.tabButton,
                holder: holder,
                __promise__: Promise.resolve(),
                waitFor: function (promise) {
                    this.__promise__ = promise;
                }
            };
            holder.tabFrame.emit('requestremove', eventData, holder.tabFrame);
            eventData.type = 'requestremovetab';
            eventData.target = self;
            self.emit('requestremovetab', eventData, self);
            resPromise.push(
                eventData.__promise__.then(function () {
                    //if ok
                    var eventData2 = {
                        type: 'deactive',
                        target: holder.tabFrame,
                        id: holder.id,
                        userActive: !!userActive,
                        tabButton: holder.tabButton,
                        holder: holder
                    };
                    if (!holder.containerElt.containsClass('absol-tabview-container-hidden'))
                        holder.tabFrame.emit('deactive', eventData2, holder.tabFrame);
                    eventData2.type = 'deactivetab';
                    eventData2.target = self;
                    if (!holder.containerElt.containsClass('absol-tabview-container-hidden'))
                        self.emit('deactivetab', eventData2, self);
                    self._frameHolders = self._frameHolders.filter(function (x) {
                        return x.id != id;
                    });
                    holder.tabFrame.notifyDetached();
                    self.$tabbar.removeTab(holder.id);
                    holder.containerElt.remove();

                    eventData2.type = 'remove';
                    eventData2.target = holder.tabFrame;
                    holder.tabFrame.emit('remove', eventData2, holder.tabFrame);
                    eventData2.type = 'removetab';
                    eventData2.target = self;
                    self.emit('removetab', eventData2, self);
                    self.activeLastTab();
                }, function () {
                    //if reject
                })
            );
        }
    });
    return Promise.all(resPromise);

};


TabView.prototype.notifyUpdateDesc = function (elt) {
    var holder = this.findHolder(elt);
    if (holder) {
        holder.tabButton.desc = elt.desc;
    }
};

TabView.prototype.notifyUpdateName = function (elt) {
    var holder = this.findHolder(elt);
    if (holder) {
        holder.tabButton.name = elt.name;
    }
};

TabView.prototype.notifyUpdateModified = function (elt) {
    var holder = this.findHolder(elt);
    if (holder) {
        holder.tabButton.modified = elt.modified;
    }
};

TabView.prototype.findHolder = function (elt) {
    for (var i = 0; i < this._frameHolders.length; ++i) {
        var holder = this._frameHolders[i];
        if (holder.tabFrame == elt) {
            return holder;
        }
    }
};

TabView.prototype.addChild = function () {
    var self = this;
    Array.prototype.forEach.call(arguments, function (elt) {
        if (!elt.notifyAttached || !elt.notifyDetached) {
            throw new Error('element is not a tabframe');
        }
        var containerElt = TabView_('.absol-tabview-container.absol-tabview-container-hidden');
        self.appendChild(containerElt);//origin function
        elt.selfRemove();
        var id = elt.attr('id');
        var desc = elt.attr('desc') || undefined;
        var name = elt.attr('name') || 'NoName';
        var tabIcon = elt.tabIcon;
        var modified = elt.modified;

        var tabButton = self.$tabbar.addTab({ name: name, id: id, desc: desc, modified: modified, tabIcon: tabIcon });
        containerElt.addChild(elt);
        elt.notifyAttached(self);
        var holder = {};
        OOP["a" /* default */].drillProperty(holder, elt, 'id');
        OOP["a" /* default */].drillProperty(holder, elt, 'desc');
        OOP["a" /* default */].drillProperty(holder, elt, 'name');
        Object.defineProperties(holder, {
            tabButton: {
                value: tabButton,
                writable: false
            },
            tabFrame: {
                value: elt,
                writable: false
            },
            containerElt: {
                value: containerElt,
                writable: false
            }
        });
        self._frameHolders.push(holder);
        self.activeTab(id);
    });
};

TabView.prototype.activeLastTab = function () {
    var dict = this._frameHolders.reduce(function (ac, holder) {
        ac[holder.id] = true;
        return ac;
    }, {});

    while (this._history.length > 0) {
        var id = this._history[this._history.length - 1];
        if (dict[id]) {
            this.activeTab(id);
            break;
        }
        else {
            this._history.pop();
        }
    }
};

TabView.prototype.getChildAt = function (index) {
    return this._frameHolders[index].tabFrame;
};

TabView.prototype.getAllChild = function () {
    return this._frameHolders.map(function (holder) {
        return holder.tabFrame;
    });
};

TabView.prototype.getActiveTabHolder = function () {
    var holder = null;
    for (var i = 0; i < this._frameHolders.length; ++i) {
        holder = this._frameHolders[i];
        if (!holder.containerElt.containsClass('absol-tabview-container-hidden')) {
            return holder;
        }
    }
    return null;
};

TabView.prototype.getActiveTab = function () {
    var holder = this.getActiveTabHolder();
    return holder && holder.tabFrame;
};

TabView.prototype.getActiveTabId = function () {
    var holder = this.getActiveTabHolder();
    return holder && holder.id;
};

TabView.prototype.getTabById = function (id) {
    var holder = this.getTabHolderById(id);
    return holder && holder.tabFrame;
};

TabView.prototype.getTabHolderById = function (id) {
    var holder = null;
    for (var i = 0; i < this._frameHolders.length; ++i) {
        holder = this._frameHolders[i];
        if (holder.id === id) {
            return holder;
        }
    }
    return null;
}


TabView.prototype.activeFrame = function (elt) {
    if (typeof elt == "string") {
        return this.activeTab(elt);
    }
    else if (elt && elt.attr) {
        return this.activeTab(elt.attr('id'));
    }
    else {
        throw new Error("Invalid param, must be id or elt!");
    }
};


TabView.property = {};

TabView.property.historyOfTab = {
    get: function () {
        return this._history.slice();
    }
};

ACore["d" /* default */].install('tabview', TabView);

/* harmony default export */ var js_TabView = __webpack_exports__["a"] = (TabView);

/***/ }),
/* 83 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(164);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 84 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global) {/*!
 * The buffer module from node.js, for the browser.
 *
 * @author   Feross Aboukhadijeh <http://feross.org>
 * @license  MIT
 */
/* eslint-disable no-proto */



var base64 = __webpack_require__(321)
var ieee754 = __webpack_require__(322)
var isArray = __webpack_require__(323)

exports.Buffer = Buffer
exports.SlowBuffer = SlowBuffer
exports.INSPECT_MAX_BYTES = 50

/**
 * If `Buffer.TYPED_ARRAY_SUPPORT`:
 *   === true    Use Uint8Array implementation (fastest)
 *   === false   Use Object implementation (most compatible, even IE6)
 *
 * Browsers that support typed arrays are IE 10+, Firefox 4+, Chrome 7+, Safari 5.1+,
 * Opera 11.6+, iOS 4.2+.
 *
 * Due to various browser bugs, sometimes the Object implementation will be used even
 * when the browser supports typed arrays.
 *
 * Note:
 *
 *   - Firefox 4-29 lacks support for adding new properties to `Uint8Array` instances,
 *     See: https://bugzilla.mozilla.org/show_bug.cgi?id=695438.
 *
 *   - Chrome 9-10 is missing the `TypedArray.prototype.subarray` function.
 *
 *   - IE10 has a broken `TypedArray.prototype.subarray` function which returns arrays of
 *     incorrect length in some situations.

 * We detect these buggy browsers and set `Buffer.TYPED_ARRAY_SUPPORT` to `false` so they
 * get the Object implementation, which is slower but behaves correctly.
 */
Buffer.TYPED_ARRAY_SUPPORT = global.TYPED_ARRAY_SUPPORT !== undefined
  ? global.TYPED_ARRAY_SUPPORT
  : typedArraySupport()

/*
 * Export kMaxLength after typed array support is determined.
 */
exports.kMaxLength = kMaxLength()

function typedArraySupport () {
  try {
    var arr = new Uint8Array(1)
    arr.__proto__ = {__proto__: Uint8Array.prototype, foo: function () { return 42 }}
    return arr.foo() === 42 && // typed array instances can be augmented
        typeof arr.subarray === 'function' && // chrome 9-10 lack `subarray`
        arr.subarray(1, 1).byteLength === 0 // ie10 has broken `subarray`
  } catch (e) {
    return false
  }
}

function kMaxLength () {
  return Buffer.TYPED_ARRAY_SUPPORT
    ? 0x7fffffff
    : 0x3fffffff
}

function createBuffer (that, length) {
  if (kMaxLength() < length) {
    throw new RangeError('Invalid typed array length')
  }
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    // Return an augmented `Uint8Array` instance, for best performance
    that = new Uint8Array(length)
    that.__proto__ = Buffer.prototype
  } else {
    // Fallback: Return an object instance of the Buffer class
    if (that === null) {
      that = new Buffer(length)
    }
    that.length = length
  }

  return that
}

/**
 * The Buffer constructor returns instances of `Uint8Array` that have their
 * prototype changed to `Buffer.prototype`. Furthermore, `Buffer` is a subclass of
 * `Uint8Array`, so the returned instances will have all the node `Buffer` methods
 * and the `Uint8Array` methods. Square bracket notation works as expected -- it
 * returns a single octet.
 *
 * The `Uint8Array` prototype remains unmodified.
 */

function Buffer (arg, encodingOrOffset, length) {
  if (!Buffer.TYPED_ARRAY_SUPPORT && !(this instanceof Buffer)) {
    return new Buffer(arg, encodingOrOffset, length)
  }

  // Common case.
  if (typeof arg === 'number') {
    if (typeof encodingOrOffset === 'string') {
      throw new Error(
        'If encoding is specified then the first argument must be a string'
      )
    }
    return allocUnsafe(this, arg)
  }
  return from(this, arg, encodingOrOffset, length)
}

Buffer.poolSize = 8192 // not used by this implementation

// TODO: Legacy, not needed anymore. Remove in next major version.
Buffer._augment = function (arr) {
  arr.__proto__ = Buffer.prototype
  return arr
}

function from (that, value, encodingOrOffset, length) {
  if (typeof value === 'number') {
    throw new TypeError('"value" argument must not be a number')
  }

  if (typeof ArrayBuffer !== 'undefined' && value instanceof ArrayBuffer) {
    return fromArrayBuffer(that, value, encodingOrOffset, length)
  }

  if (typeof value === 'string') {
    return fromString(that, value, encodingOrOffset)
  }

  return fromObject(that, value)
}

/**
 * Functionally equivalent to Buffer(arg, encoding) but throws a TypeError
 * if value is a number.
 * Buffer.from(str[, encoding])
 * Buffer.from(array)
 * Buffer.from(buffer)
 * Buffer.from(arrayBuffer[, byteOffset[, length]])
 **/
Buffer.from = function (value, encodingOrOffset, length) {
  return from(null, value, encodingOrOffset, length)
}

if (Buffer.TYPED_ARRAY_SUPPORT) {
  Buffer.prototype.__proto__ = Uint8Array.prototype
  Buffer.__proto__ = Uint8Array
  if (typeof Symbol !== 'undefined' && Symbol.species &&
      Buffer[Symbol.species] === Buffer) {
    // Fix subarray() in ES2016. See: https://github.com/feross/buffer/pull/97
    Object.defineProperty(Buffer, Symbol.species, {
      value: null,
      configurable: true
    })
  }
}

function assertSize (size) {
  if (typeof size !== 'number') {
    throw new TypeError('"size" argument must be a number')
  } else if (size < 0) {
    throw new RangeError('"size" argument must not be negative')
  }
}

function alloc (that, size, fill, encoding) {
  assertSize(size)
  if (size <= 0) {
    return createBuffer(that, size)
  }
  if (fill !== undefined) {
    // Only pay attention to encoding if it's a string. This
    // prevents accidentally sending in a number that would
    // be interpretted as a start offset.
    return typeof encoding === 'string'
      ? createBuffer(that, size).fill(fill, encoding)
      : createBuffer(that, size).fill(fill)
  }
  return createBuffer(that, size)
}

/**
 * Creates a new filled Buffer instance.
 * alloc(size[, fill[, encoding]])
 **/
Buffer.alloc = function (size, fill, encoding) {
  return alloc(null, size, fill, encoding)
}

function allocUnsafe (that, size) {
  assertSize(size)
  that = createBuffer(that, size < 0 ? 0 : checked(size) | 0)
  if (!Buffer.TYPED_ARRAY_SUPPORT) {
    for (var i = 0; i < size; ++i) {
      that[i] = 0
    }
  }
  return that
}

/**
 * Equivalent to Buffer(num), by default creates a non-zero-filled Buffer instance.
 * */
Buffer.allocUnsafe = function (size) {
  return allocUnsafe(null, size)
}
/**
 * Equivalent to SlowBuffer(num), by default creates a non-zero-filled Buffer instance.
 */
Buffer.allocUnsafeSlow = function (size) {
  return allocUnsafe(null, size)
}

function fromString (that, string, encoding) {
  if (typeof encoding !== 'string' || encoding === '') {
    encoding = 'utf8'
  }

  if (!Buffer.isEncoding(encoding)) {
    throw new TypeError('"encoding" must be a valid string encoding')
  }

  var length = byteLength(string, encoding) | 0
  that = createBuffer(that, length)

  var actual = that.write(string, encoding)

  if (actual !== length) {
    // Writing a hex string, for example, that contains invalid characters will
    // cause everything after the first invalid character to be ignored. (e.g.
    // 'abxxcd' will be treated as 'ab')
    that = that.slice(0, actual)
  }

  return that
}

function fromArrayLike (that, array) {
  var length = array.length < 0 ? 0 : checked(array.length) | 0
  that = createBuffer(that, length)
  for (var i = 0; i < length; i += 1) {
    that[i] = array[i] & 255
  }
  return that
}

function fromArrayBuffer (that, array, byteOffset, length) {
  array.byteLength // this throws if `array` is not a valid ArrayBuffer

  if (byteOffset < 0 || array.byteLength < byteOffset) {
    throw new RangeError('\'offset\' is out of bounds')
  }

  if (array.byteLength < byteOffset + (length || 0)) {
    throw new RangeError('\'length\' is out of bounds')
  }

  if (byteOffset === undefined && length === undefined) {
    array = new Uint8Array(array)
  } else if (length === undefined) {
    array = new Uint8Array(array, byteOffset)
  } else {
    array = new Uint8Array(array, byteOffset, length)
  }

  if (Buffer.TYPED_ARRAY_SUPPORT) {
    // Return an augmented `Uint8Array` instance, for best performance
    that = array
    that.__proto__ = Buffer.prototype
  } else {
    // Fallback: Return an object instance of the Buffer class
    that = fromArrayLike(that, array)
  }
  return that
}

function fromObject (that, obj) {
  if (Buffer.isBuffer(obj)) {
    var len = checked(obj.length) | 0
    that = createBuffer(that, len)

    if (that.length === 0) {
      return that
    }

    obj.copy(that, 0, 0, len)
    return that
  }

  if (obj) {
    if ((typeof ArrayBuffer !== 'undefined' &&
        obj.buffer instanceof ArrayBuffer) || 'length' in obj) {
      if (typeof obj.length !== 'number' || isnan(obj.length)) {
        return createBuffer(that, 0)
      }
      return fromArrayLike(that, obj)
    }

    if (obj.type === 'Buffer' && isArray(obj.data)) {
      return fromArrayLike(that, obj.data)
    }
  }

  throw new TypeError('First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.')
}

function checked (length) {
  // Note: cannot use `length < kMaxLength()` here because that fails when
  // length is NaN (which is otherwise coerced to zero.)
  if (length >= kMaxLength()) {
    throw new RangeError('Attempt to allocate Buffer larger than maximum ' +
                         'size: 0x' + kMaxLength().toString(16) + ' bytes')
  }
  return length | 0
}

function SlowBuffer (length) {
  if (+length != length) { // eslint-disable-line eqeqeq
    length = 0
  }
  return Buffer.alloc(+length)
}

Buffer.isBuffer = function isBuffer (b) {
  return !!(b != null && b._isBuffer)
}

Buffer.compare = function compare (a, b) {
  if (!Buffer.isBuffer(a) || !Buffer.isBuffer(b)) {
    throw new TypeError('Arguments must be Buffers')
  }

  if (a === b) return 0

  var x = a.length
  var y = b.length

  for (var i = 0, len = Math.min(x, y); i < len; ++i) {
    if (a[i] !== b[i]) {
      x = a[i]
      y = b[i]
      break
    }
  }

  if (x < y) return -1
  if (y < x) return 1
  return 0
}

Buffer.isEncoding = function isEncoding (encoding) {
  switch (String(encoding).toLowerCase()) {
    case 'hex':
    case 'utf8':
    case 'utf-8':
    case 'ascii':
    case 'latin1':
    case 'binary':
    case 'base64':
    case 'ucs2':
    case 'ucs-2':
    case 'utf16le':
    case 'utf-16le':
      return true
    default:
      return false
  }
}

Buffer.concat = function concat (list, length) {
  if (!isArray(list)) {
    throw new TypeError('"list" argument must be an Array of Buffers')
  }

  if (list.length === 0) {
    return Buffer.alloc(0)
  }

  var i
  if (length === undefined) {
    length = 0
    for (i = 0; i < list.length; ++i) {
      length += list[i].length
    }
  }

  var buffer = Buffer.allocUnsafe(length)
  var pos = 0
  for (i = 0; i < list.length; ++i) {
    var buf = list[i]
    if (!Buffer.isBuffer(buf)) {
      throw new TypeError('"list" argument must be an Array of Buffers')
    }
    buf.copy(buffer, pos)
    pos += buf.length
  }
  return buffer
}

function byteLength (string, encoding) {
  if (Buffer.isBuffer(string)) {
    return string.length
  }
  if (typeof ArrayBuffer !== 'undefined' && typeof ArrayBuffer.isView === 'function' &&
      (ArrayBuffer.isView(string) || string instanceof ArrayBuffer)) {
    return string.byteLength
  }
  if (typeof string !== 'string') {
    string = '' + string
  }

  var len = string.length
  if (len === 0) return 0

  // Use a for loop to avoid recursion
  var loweredCase = false
  for (;;) {
    switch (encoding) {
      case 'ascii':
      case 'latin1':
      case 'binary':
        return len
      case 'utf8':
      case 'utf-8':
      case undefined:
        return utf8ToBytes(string).length
      case 'ucs2':
      case 'ucs-2':
      case 'utf16le':
      case 'utf-16le':
        return len * 2
      case 'hex':
        return len >>> 1
      case 'base64':
        return base64ToBytes(string).length
      default:
        if (loweredCase) return utf8ToBytes(string).length // assume utf8
        encoding = ('' + encoding).toLowerCase()
        loweredCase = true
    }
  }
}
Buffer.byteLength = byteLength

function slowToString (encoding, start, end) {
  var loweredCase = false

  // No need to verify that "this.length <= MAX_UINT32" since it's a read-only
  // property of a typed array.

  // This behaves neither like String nor Uint8Array in that we set start/end
  // to their upper/lower bounds if the value passed is out of range.
  // undefined is handled specially as per ECMA-262 6th Edition,
  // Section 13.3.3.7 Runtime Semantics: KeyedBindingInitialization.
  if (start === undefined || start < 0) {
    start = 0
  }
  // Return early if start > this.length. Done here to prevent potential uint32
  // coercion fail below.
  if (start > this.length) {
    return ''
  }

  if (end === undefined || end > this.length) {
    end = this.length
  }

  if (end <= 0) {
    return ''
  }

  // Force coersion to uint32. This will also coerce falsey/NaN values to 0.
  end >>>= 0
  start >>>= 0

  if (end <= start) {
    return ''
  }

  if (!encoding) encoding = 'utf8'

  while (true) {
    switch (encoding) {
      case 'hex':
        return hexSlice(this, start, end)

      case 'utf8':
      case 'utf-8':
        return utf8Slice(this, start, end)

      case 'ascii':
        return asciiSlice(this, start, end)

      case 'latin1':
      case 'binary':
        return latin1Slice(this, start, end)

      case 'base64':
        return base64Slice(this, start, end)

      case 'ucs2':
      case 'ucs-2':
      case 'utf16le':
      case 'utf-16le':
        return utf16leSlice(this, start, end)

      default:
        if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding)
        encoding = (encoding + '').toLowerCase()
        loweredCase = true
    }
  }
}

// The property is used by `Buffer.isBuffer` and `is-buffer` (in Safari 5-7) to detect
// Buffer instances.
Buffer.prototype._isBuffer = true

function swap (b, n, m) {
  var i = b[n]
  b[n] = b[m]
  b[m] = i
}

Buffer.prototype.swap16 = function swap16 () {
  var len = this.length
  if (len % 2 !== 0) {
    throw new RangeError('Buffer size must be a multiple of 16-bits')
  }
  for (var i = 0; i < len; i += 2) {
    swap(this, i, i + 1)
  }
  return this
}

Buffer.prototype.swap32 = function swap32 () {
  var len = this.length
  if (len % 4 !== 0) {
    throw new RangeError('Buffer size must be a multiple of 32-bits')
  }
  for (var i = 0; i < len; i += 4) {
    swap(this, i, i + 3)
    swap(this, i + 1, i + 2)
  }
  return this
}

Buffer.prototype.swap64 = function swap64 () {
  var len = this.length
  if (len % 8 !== 0) {
    throw new RangeError('Buffer size must be a multiple of 64-bits')
  }
  for (var i = 0; i < len; i += 8) {
    swap(this, i, i + 7)
    swap(this, i + 1, i + 6)
    swap(this, i + 2, i + 5)
    swap(this, i + 3, i + 4)
  }
  return this
}

Buffer.prototype.toString = function toString () {
  var length = this.length | 0
  if (length === 0) return ''
  if (arguments.length === 0) return utf8Slice(this, 0, length)
  return slowToString.apply(this, arguments)
}

Buffer.prototype.equals = function equals (b) {
  if (!Buffer.isBuffer(b)) throw new TypeError('Argument must be a Buffer')
  if (this === b) return true
  return Buffer.compare(this, b) === 0
}

Buffer.prototype.inspect = function inspect () {
  var str = ''
  var max = exports.INSPECT_MAX_BYTES
  if (this.length > 0) {
    str = this.toString('hex', 0, max).match(/.{2}/g).join(' ')
    if (this.length > max) str += ' ... '
  }
  return '<Buffer ' + str + '>'
}

Buffer.prototype.compare = function compare (target, start, end, thisStart, thisEnd) {
  if (!Buffer.isBuffer(target)) {
    throw new TypeError('Argument must be a Buffer')
  }

  if (start === undefined) {
    start = 0
  }
  if (end === undefined) {
    end = target ? target.length : 0
  }
  if (thisStart === undefined) {
    thisStart = 0
  }
  if (thisEnd === undefined) {
    thisEnd = this.length
  }

  if (start < 0 || end > target.length || thisStart < 0 || thisEnd > this.length) {
    throw new RangeError('out of range index')
  }

  if (thisStart >= thisEnd && start >= end) {
    return 0
  }
  if (thisStart >= thisEnd) {
    return -1
  }
  if (start >= end) {
    return 1
  }

  start >>>= 0
  end >>>= 0
  thisStart >>>= 0
  thisEnd >>>= 0

  if (this === target) return 0

  var x = thisEnd - thisStart
  var y = end - start
  var len = Math.min(x, y)

  var thisCopy = this.slice(thisStart, thisEnd)
  var targetCopy = target.slice(start, end)

  for (var i = 0; i < len; ++i) {
    if (thisCopy[i] !== targetCopy[i]) {
      x = thisCopy[i]
      y = targetCopy[i]
      break
    }
  }

  if (x < y) return -1
  if (y < x) return 1
  return 0
}

// Finds either the first index of `val` in `buffer` at offset >= `byteOffset`,
// OR the last index of `val` in `buffer` at offset <= `byteOffset`.
//
// Arguments:
// - buffer - a Buffer to search
// - val - a string, Buffer, or number
// - byteOffset - an index into `buffer`; will be clamped to an int32
// - encoding - an optional encoding, relevant is val is a string
// - dir - true for indexOf, false for lastIndexOf
function bidirectionalIndexOf (buffer, val, byteOffset, encoding, dir) {
  // Empty buffer means no match
  if (buffer.length === 0) return -1

  // Normalize byteOffset
  if (typeof byteOffset === 'string') {
    encoding = byteOffset
    byteOffset = 0
  } else if (byteOffset > 0x7fffffff) {
    byteOffset = 0x7fffffff
  } else if (byteOffset < -0x80000000) {
    byteOffset = -0x80000000
  }
  byteOffset = +byteOffset  // Coerce to Number.
  if (isNaN(byteOffset)) {
    // byteOffset: it it's undefined, null, NaN, "foo", etc, search whole buffer
    byteOffset = dir ? 0 : (buffer.length - 1)
  }

  // Normalize byteOffset: negative offsets start from the end of the buffer
  if (byteOffset < 0) byteOffset = buffer.length + byteOffset
  if (byteOffset >= buffer.length) {
    if (dir) return -1
    else byteOffset = buffer.length - 1
  } else if (byteOffset < 0) {
    if (dir) byteOffset = 0
    else return -1
  }

  // Normalize val
  if (typeof val === 'string') {
    val = Buffer.from(val, encoding)
  }

  // Finally, search either indexOf (if dir is true) or lastIndexOf
  if (Buffer.isBuffer(val)) {
    // Special case: looking for empty string/buffer always fails
    if (val.length === 0) {
      return -1
    }
    return arrayIndexOf(buffer, val, byteOffset, encoding, dir)
  } else if (typeof val === 'number') {
    val = val & 0xFF // Search for a byte value [0-255]
    if (Buffer.TYPED_ARRAY_SUPPORT &&
        typeof Uint8Array.prototype.indexOf === 'function') {
      if (dir) {
        return Uint8Array.prototype.indexOf.call(buffer, val, byteOffset)
      } else {
        return Uint8Array.prototype.lastIndexOf.call(buffer, val, byteOffset)
      }
    }
    return arrayIndexOf(buffer, [ val ], byteOffset, encoding, dir)
  }

  throw new TypeError('val must be string, number or Buffer')
}

function arrayIndexOf (arr, val, byteOffset, encoding, dir) {
  var indexSize = 1
  var arrLength = arr.length
  var valLength = val.length

  if (encoding !== undefined) {
    encoding = String(encoding).toLowerCase()
    if (encoding === 'ucs2' || encoding === 'ucs-2' ||
        encoding === 'utf16le' || encoding === 'utf-16le') {
      if (arr.length < 2 || val.length < 2) {
        return -1
      }
      indexSize = 2
      arrLength /= 2
      valLength /= 2
      byteOffset /= 2
    }
  }

  function read (buf, i) {
    if (indexSize === 1) {
      return buf[i]
    } else {
      return buf.readUInt16BE(i * indexSize)
    }
  }

  var i
  if (dir) {
    var foundIndex = -1
    for (i = byteOffset; i < arrLength; i++) {
      if (read(arr, i) === read(val, foundIndex === -1 ? 0 : i - foundIndex)) {
        if (foundIndex === -1) foundIndex = i
        if (i - foundIndex + 1 === valLength) return foundIndex * indexSize
      } else {
        if (foundIndex !== -1) i -= i - foundIndex
        foundIndex = -1
      }
    }
  } else {
    if (byteOffset + valLength > arrLength) byteOffset = arrLength - valLength
    for (i = byteOffset; i >= 0; i--) {
      var found = true
      for (var j = 0; j < valLength; j++) {
        if (read(arr, i + j) !== read(val, j)) {
          found = false
          break
        }
      }
      if (found) return i
    }
  }

  return -1
}

Buffer.prototype.includes = function includes (val, byteOffset, encoding) {
  return this.indexOf(val, byteOffset, encoding) !== -1
}

Buffer.prototype.indexOf = function indexOf (val, byteOffset, encoding) {
  return bidirectionalIndexOf(this, val, byteOffset, encoding, true)
}

Buffer.prototype.lastIndexOf = function lastIndexOf (val, byteOffset, encoding) {
  return bidirectionalIndexOf(this, val, byteOffset, encoding, false)
}

function hexWrite (buf, string, offset, length) {
  offset = Number(offset) || 0
  var remaining = buf.length - offset
  if (!length) {
    length = remaining
  } else {
    length = Number(length)
    if (length > remaining) {
      length = remaining
    }
  }

  // must be an even number of digits
  var strLen = string.length
  if (strLen % 2 !== 0) throw new TypeError('Invalid hex string')

  if (length > strLen / 2) {
    length = strLen / 2
  }
  for (var i = 0; i < length; ++i) {
    var parsed = parseInt(string.substr(i * 2, 2), 16)
    if (isNaN(parsed)) return i
    buf[offset + i] = parsed
  }
  return i
}

function utf8Write (buf, string, offset, length) {
  return blitBuffer(utf8ToBytes(string, buf.length - offset), buf, offset, length)
}

function asciiWrite (buf, string, offset, length) {
  return blitBuffer(asciiToBytes(string), buf, offset, length)
}

function latin1Write (buf, string, offset, length) {
  return asciiWrite(buf, string, offset, length)
}

function base64Write (buf, string, offset, length) {
  return blitBuffer(base64ToBytes(string), buf, offset, length)
}

function ucs2Write (buf, string, offset, length) {
  return blitBuffer(utf16leToBytes(string, buf.length - offset), buf, offset, length)
}

Buffer.prototype.write = function write (string, offset, length, encoding) {
  // Buffer#write(string)
  if (offset === undefined) {
    encoding = 'utf8'
    length = this.length
    offset = 0
  // Buffer#write(string, encoding)
  } else if (length === undefined && typeof offset === 'string') {
    encoding = offset
    length = this.length
    offset = 0
  // Buffer#write(string, offset[, length][, encoding])
  } else if (isFinite(offset)) {
    offset = offset | 0
    if (isFinite(length)) {
      length = length | 0
      if (encoding === undefined) encoding = 'utf8'
    } else {
      encoding = length
      length = undefined
    }
  // legacy write(string, encoding, offset, length) - remove in v0.13
  } else {
    throw new Error(
      'Buffer.write(string, encoding, offset[, length]) is no longer supported'
    )
  }

  var remaining = this.length - offset
  if (length === undefined || length > remaining) length = remaining

  if ((string.length > 0 && (length < 0 || offset < 0)) || offset > this.length) {
    throw new RangeError('Attempt to write outside buffer bounds')
  }

  if (!encoding) encoding = 'utf8'

  var loweredCase = false
  for (;;) {
    switch (encoding) {
      case 'hex':
        return hexWrite(this, string, offset, length)

      case 'utf8':
      case 'utf-8':
        return utf8Write(this, string, offset, length)

      case 'ascii':
        return asciiWrite(this, string, offset, length)

      case 'latin1':
      case 'binary':
        return latin1Write(this, string, offset, length)

      case 'base64':
        // Warning: maxLength not taken into account in base64Write
        return base64Write(this, string, offset, length)

      case 'ucs2':
      case 'ucs-2':
      case 'utf16le':
      case 'utf-16le':
        return ucs2Write(this, string, offset, length)

      default:
        if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding)
        encoding = ('' + encoding).toLowerCase()
        loweredCase = true
    }
  }
}

Buffer.prototype.toJSON = function toJSON () {
  return {
    type: 'Buffer',
    data: Array.prototype.slice.call(this._arr || this, 0)
  }
}

function base64Slice (buf, start, end) {
  if (start === 0 && end === buf.length) {
    return base64.fromByteArray(buf)
  } else {
    return base64.fromByteArray(buf.slice(start, end))
  }
}

function utf8Slice (buf, start, end) {
  end = Math.min(buf.length, end)
  var res = []

  var i = start
  while (i < end) {
    var firstByte = buf[i]
    var codePoint = null
    var bytesPerSequence = (firstByte > 0xEF) ? 4
      : (firstByte > 0xDF) ? 3
      : (firstByte > 0xBF) ? 2
      : 1

    if (i + bytesPerSequence <= end) {
      var secondByte, thirdByte, fourthByte, tempCodePoint

      switch (bytesPerSequence) {
        case 1:
          if (firstByte < 0x80) {
            codePoint = firstByte
          }
          break
        case 2:
          secondByte = buf[i + 1]
          if ((secondByte & 0xC0) === 0x80) {
            tempCodePoint = (firstByte & 0x1F) << 0x6 | (secondByte & 0x3F)
            if (tempCodePoint > 0x7F) {
              codePoint = tempCodePoint
            }
          }
          break
        case 3:
          secondByte = buf[i + 1]
          thirdByte = buf[i + 2]
          if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80) {
            tempCodePoint = (firstByte & 0xF) << 0xC | (secondByte & 0x3F) << 0x6 | (thirdByte & 0x3F)
            if (tempCodePoint > 0x7FF && (tempCodePoint < 0xD800 || tempCodePoint > 0xDFFF)) {
              codePoint = tempCodePoint
            }
          }
          break
        case 4:
          secondByte = buf[i + 1]
          thirdByte = buf[i + 2]
          fourthByte = buf[i + 3]
          if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80 && (fourthByte & 0xC0) === 0x80) {
            tempCodePoint = (firstByte & 0xF) << 0x12 | (secondByte & 0x3F) << 0xC | (thirdByte & 0x3F) << 0x6 | (fourthByte & 0x3F)
            if (tempCodePoint > 0xFFFF && tempCodePoint < 0x110000) {
              codePoint = tempCodePoint
            }
          }
      }
    }

    if (codePoint === null) {
      // we did not generate a valid codePoint so insert a
      // replacement char (U+FFFD) and advance only 1 byte
      codePoint = 0xFFFD
      bytesPerSequence = 1
    } else if (codePoint > 0xFFFF) {
      // encode to utf16 (surrogate pair dance)
      codePoint -= 0x10000
      res.push(codePoint >>> 10 & 0x3FF | 0xD800)
      codePoint = 0xDC00 | codePoint & 0x3FF
    }

    res.push(codePoint)
    i += bytesPerSequence
  }

  return decodeCodePointsArray(res)
}

// Based on http://stackoverflow.com/a/22747272/680742, the browser with
// the lowest limit is Chrome, with 0x10000 args.
// We go 1 magnitude less, for safety
var MAX_ARGUMENTS_LENGTH = 0x1000

function decodeCodePointsArray (codePoints) {
  var len = codePoints.length
  if (len <= MAX_ARGUMENTS_LENGTH) {
    return String.fromCharCode.apply(String, codePoints) // avoid extra slice()
  }

  // Decode in chunks to avoid "call stack size exceeded".
  var res = ''
  var i = 0
  while (i < len) {
    res += String.fromCharCode.apply(
      String,
      codePoints.slice(i, i += MAX_ARGUMENTS_LENGTH)
    )
  }
  return res
}

function asciiSlice (buf, start, end) {
  var ret = ''
  end = Math.min(buf.length, end)

  for (var i = start; i < end; ++i) {
    ret += String.fromCharCode(buf[i] & 0x7F)
  }
  return ret
}

function latin1Slice (buf, start, end) {
  var ret = ''
  end = Math.min(buf.length, end)

  for (var i = start; i < end; ++i) {
    ret += String.fromCharCode(buf[i])
  }
  return ret
}

function hexSlice (buf, start, end) {
  var len = buf.length

  if (!start || start < 0) start = 0
  if (!end || end < 0 || end > len) end = len

  var out = ''
  for (var i = start; i < end; ++i) {
    out += toHex(buf[i])
  }
  return out
}

function utf16leSlice (buf, start, end) {
  var bytes = buf.slice(start, end)
  var res = ''
  for (var i = 0; i < bytes.length; i += 2) {
    res += String.fromCharCode(bytes[i] + bytes[i + 1] * 256)
  }
  return res
}

Buffer.prototype.slice = function slice (start, end) {
  var len = this.length
  start = ~~start
  end = end === undefined ? len : ~~end

  if (start < 0) {
    start += len
    if (start < 0) start = 0
  } else if (start > len) {
    start = len
  }

  if (end < 0) {
    end += len
    if (end < 0) end = 0
  } else if (end > len) {
    end = len
  }

  if (end < start) end = start

  var newBuf
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    newBuf = this.subarray(start, end)
    newBuf.__proto__ = Buffer.prototype
  } else {
    var sliceLen = end - start
    newBuf = new Buffer(sliceLen, undefined)
    for (var i = 0; i < sliceLen; ++i) {
      newBuf[i] = this[i + start]
    }
  }

  return newBuf
}

/*
 * Need to make sure that buffer isn't trying to write out of bounds.
 */
function checkOffset (offset, ext, length) {
  if ((offset % 1) !== 0 || offset < 0) throw new RangeError('offset is not uint')
  if (offset + ext > length) throw new RangeError('Trying to access beyond buffer length')
}

Buffer.prototype.readUIntLE = function readUIntLE (offset, byteLength, noAssert) {
  offset = offset | 0
  byteLength = byteLength | 0
  if (!noAssert) checkOffset(offset, byteLength, this.length)

  var val = this[offset]
  var mul = 1
  var i = 0
  while (++i < byteLength && (mul *= 0x100)) {
    val += this[offset + i] * mul
  }

  return val
}

Buffer.prototype.readUIntBE = function readUIntBE (offset, byteLength, noAssert) {
  offset = offset | 0
  byteLength = byteLength | 0
  if (!noAssert) {
    checkOffset(offset, byteLength, this.length)
  }

  var val = this[offset + --byteLength]
  var mul = 1
  while (byteLength > 0 && (mul *= 0x100)) {
    val += this[offset + --byteLength] * mul
  }

  return val
}

Buffer.prototype.readUInt8 = function readUInt8 (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 1, this.length)
  return this[offset]
}

Buffer.prototype.readUInt16LE = function readUInt16LE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 2, this.length)
  return this[offset] | (this[offset + 1] << 8)
}

Buffer.prototype.readUInt16BE = function readUInt16BE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 2, this.length)
  return (this[offset] << 8) | this[offset + 1]
}

Buffer.prototype.readUInt32LE = function readUInt32LE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 4, this.length)

  return ((this[offset]) |
      (this[offset + 1] << 8) |
      (this[offset + 2] << 16)) +
      (this[offset + 3] * 0x1000000)
}

Buffer.prototype.readUInt32BE = function readUInt32BE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 4, this.length)

  return (this[offset] * 0x1000000) +
    ((this[offset + 1] << 16) |
    (this[offset + 2] << 8) |
    this[offset + 3])
}

Buffer.prototype.readIntLE = function readIntLE (offset, byteLength, noAssert) {
  offset = offset | 0
  byteLength = byteLength | 0
  if (!noAssert) checkOffset(offset, byteLength, this.length)

  var val = this[offset]
  var mul = 1
  var i = 0
  while (++i < byteLength && (mul *= 0x100)) {
    val += this[offset + i] * mul
  }
  mul *= 0x80

  if (val >= mul) val -= Math.pow(2, 8 * byteLength)

  return val
}

Buffer.prototype.readIntBE = function readIntBE (offset, byteLength, noAssert) {
  offset = offset | 0
  byteLength = byteLength | 0
  if (!noAssert) checkOffset(offset, byteLength, this.length)

  var i = byteLength
  var mul = 1
  var val = this[offset + --i]
  while (i > 0 && (mul *= 0x100)) {
    val += this[offset + --i] * mul
  }
  mul *= 0x80

  if (val >= mul) val -= Math.pow(2, 8 * byteLength)

  return val
}

Buffer.prototype.readInt8 = function readInt8 (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 1, this.length)
  if (!(this[offset] & 0x80)) return (this[offset])
  return ((0xff - this[offset] + 1) * -1)
}

Buffer.prototype.readInt16LE = function readInt16LE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 2, this.length)
  var val = this[offset] | (this[offset + 1] << 8)
  return (val & 0x8000) ? val | 0xFFFF0000 : val
}

Buffer.prototype.readInt16BE = function readInt16BE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 2, this.length)
  var val = this[offset + 1] | (this[offset] << 8)
  return (val & 0x8000) ? val | 0xFFFF0000 : val
}

Buffer.prototype.readInt32LE = function readInt32LE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 4, this.length)

  return (this[offset]) |
    (this[offset + 1] << 8) |
    (this[offset + 2] << 16) |
    (this[offset + 3] << 24)
}

Buffer.prototype.readInt32BE = function readInt32BE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 4, this.length)

  return (this[offset] << 24) |
    (this[offset + 1] << 16) |
    (this[offset + 2] << 8) |
    (this[offset + 3])
}

Buffer.prototype.readFloatLE = function readFloatLE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 4, this.length)
  return ieee754.read(this, offset, true, 23, 4)
}

Buffer.prototype.readFloatBE = function readFloatBE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 4, this.length)
  return ieee754.read(this, offset, false, 23, 4)
}

Buffer.prototype.readDoubleLE = function readDoubleLE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 8, this.length)
  return ieee754.read(this, offset, true, 52, 8)
}

Buffer.prototype.readDoubleBE = function readDoubleBE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 8, this.length)
  return ieee754.read(this, offset, false, 52, 8)
}

function checkInt (buf, value, offset, ext, max, min) {
  if (!Buffer.isBuffer(buf)) throw new TypeError('"buffer" argument must be a Buffer instance')
  if (value > max || value < min) throw new RangeError('"value" argument is out of bounds')
  if (offset + ext > buf.length) throw new RangeError('Index out of range')
}

Buffer.prototype.writeUIntLE = function writeUIntLE (value, offset, byteLength, noAssert) {
  value = +value
  offset = offset | 0
  byteLength = byteLength | 0
  if (!noAssert) {
    var maxBytes = Math.pow(2, 8 * byteLength) - 1
    checkInt(this, value, offset, byteLength, maxBytes, 0)
  }

  var mul = 1
  var i = 0
  this[offset] = value & 0xFF
  while (++i < byteLength && (mul *= 0x100)) {
    this[offset + i] = (value / mul) & 0xFF
  }

  return offset + byteLength
}

Buffer.prototype.writeUIntBE = function writeUIntBE (value, offset, byteLength, noAssert) {
  value = +value
  offset = offset | 0
  byteLength = byteLength | 0
  if (!noAssert) {
    var maxBytes = Math.pow(2, 8 * byteLength) - 1
    checkInt(this, value, offset, byteLength, maxBytes, 0)
  }

  var i = byteLength - 1
  var mul = 1
  this[offset + i] = value & 0xFF
  while (--i >= 0 && (mul *= 0x100)) {
    this[offset + i] = (value / mul) & 0xFF
  }

  return offset + byteLength
}

Buffer.prototype.writeUInt8 = function writeUInt8 (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 1, 0xff, 0)
  if (!Buffer.TYPED_ARRAY_SUPPORT) value = Math.floor(value)
  this[offset] = (value & 0xff)
  return offset + 1
}

function objectWriteUInt16 (buf, value, offset, littleEndian) {
  if (value < 0) value = 0xffff + value + 1
  for (var i = 0, j = Math.min(buf.length - offset, 2); i < j; ++i) {
    buf[offset + i] = (value & (0xff << (8 * (littleEndian ? i : 1 - i)))) >>>
      (littleEndian ? i : 1 - i) * 8
  }
}

Buffer.prototype.writeUInt16LE = function writeUInt16LE (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0)
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    this[offset] = (value & 0xff)
    this[offset + 1] = (value >>> 8)
  } else {
    objectWriteUInt16(this, value, offset, true)
  }
  return offset + 2
}

Buffer.prototype.writeUInt16BE = function writeUInt16BE (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0)
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    this[offset] = (value >>> 8)
    this[offset + 1] = (value & 0xff)
  } else {
    objectWriteUInt16(this, value, offset, false)
  }
  return offset + 2
}

function objectWriteUInt32 (buf, value, offset, littleEndian) {
  if (value < 0) value = 0xffffffff + value + 1
  for (var i = 0, j = Math.min(buf.length - offset, 4); i < j; ++i) {
    buf[offset + i] = (value >>> (littleEndian ? i : 3 - i) * 8) & 0xff
  }
}

Buffer.prototype.writeUInt32LE = function writeUInt32LE (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0)
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    this[offset + 3] = (value >>> 24)
    this[offset + 2] = (value >>> 16)
    this[offset + 1] = (value >>> 8)
    this[offset] = (value & 0xff)
  } else {
    objectWriteUInt32(this, value, offset, true)
  }
  return offset + 4
}

Buffer.prototype.writeUInt32BE = function writeUInt32BE (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0)
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    this[offset] = (value >>> 24)
    this[offset + 1] = (value >>> 16)
    this[offset + 2] = (value >>> 8)
    this[offset + 3] = (value & 0xff)
  } else {
    objectWriteUInt32(this, value, offset, false)
  }
  return offset + 4
}

Buffer.prototype.writeIntLE = function writeIntLE (value, offset, byteLength, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) {
    var limit = Math.pow(2, 8 * byteLength - 1)

    checkInt(this, value, offset, byteLength, limit - 1, -limit)
  }

  var i = 0
  var mul = 1
  var sub = 0
  this[offset] = value & 0xFF
  while (++i < byteLength && (mul *= 0x100)) {
    if (value < 0 && sub === 0 && this[offset + i - 1] !== 0) {
      sub = 1
    }
    this[offset + i] = ((value / mul) >> 0) - sub & 0xFF
  }

  return offset + byteLength
}

Buffer.prototype.writeIntBE = function writeIntBE (value, offset, byteLength, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) {
    var limit = Math.pow(2, 8 * byteLength - 1)

    checkInt(this, value, offset, byteLength, limit - 1, -limit)
  }

  var i = byteLength - 1
  var mul = 1
  var sub = 0
  this[offset + i] = value & 0xFF
  while (--i >= 0 && (mul *= 0x100)) {
    if (value < 0 && sub === 0 && this[offset + i + 1] !== 0) {
      sub = 1
    }
    this[offset + i] = ((value / mul) >> 0) - sub & 0xFF
  }

  return offset + byteLength
}

Buffer.prototype.writeInt8 = function writeInt8 (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 1, 0x7f, -0x80)
  if (!Buffer.TYPED_ARRAY_SUPPORT) value = Math.floor(value)
  if (value < 0) value = 0xff + value + 1
  this[offset] = (value & 0xff)
  return offset + 1
}

Buffer.prototype.writeInt16LE = function writeInt16LE (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000)
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    this[offset] = (value & 0xff)
    this[offset + 1] = (value >>> 8)
  } else {
    objectWriteUInt16(this, value, offset, true)
  }
  return offset + 2
}

Buffer.prototype.writeInt16BE = function writeInt16BE (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000)
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    this[offset] = (value >>> 8)
    this[offset + 1] = (value & 0xff)
  } else {
    objectWriteUInt16(this, value, offset, false)
  }
  return offset + 2
}

Buffer.prototype.writeInt32LE = function writeInt32LE (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000)
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    this[offset] = (value & 0xff)
    this[offset + 1] = (value >>> 8)
    this[offset + 2] = (value >>> 16)
    this[offset + 3] = (value >>> 24)
  } else {
    objectWriteUInt32(this, value, offset, true)
  }
  return offset + 4
}

Buffer.prototype.writeInt32BE = function writeInt32BE (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000)
  if (value < 0) value = 0xffffffff + value + 1
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    this[offset] = (value >>> 24)
    this[offset + 1] = (value >>> 16)
    this[offset + 2] = (value >>> 8)
    this[offset + 3] = (value & 0xff)
  } else {
    objectWriteUInt32(this, value, offset, false)
  }
  return offset + 4
}

function checkIEEE754 (buf, value, offset, ext, max, min) {
  if (offset + ext > buf.length) throw new RangeError('Index out of range')
  if (offset < 0) throw new RangeError('Index out of range')
}

function writeFloat (buf, value, offset, littleEndian, noAssert) {
  if (!noAssert) {
    checkIEEE754(buf, value, offset, 4, 3.4028234663852886e+38, -3.4028234663852886e+38)
  }
  ieee754.write(buf, value, offset, littleEndian, 23, 4)
  return offset + 4
}

Buffer.prototype.writeFloatLE = function writeFloatLE (value, offset, noAssert) {
  return writeFloat(this, value, offset, true, noAssert)
}

Buffer.prototype.writeFloatBE = function writeFloatBE (value, offset, noAssert) {
  return writeFloat(this, value, offset, false, noAssert)
}

function writeDouble (buf, value, offset, littleEndian, noAssert) {
  if (!noAssert) {
    checkIEEE754(buf, value, offset, 8, 1.7976931348623157E+308, -1.7976931348623157E+308)
  }
  ieee754.write(buf, value, offset, littleEndian, 52, 8)
  return offset + 8
}

Buffer.prototype.writeDoubleLE = function writeDoubleLE (value, offset, noAssert) {
  return writeDouble(this, value, offset, true, noAssert)
}

Buffer.prototype.writeDoubleBE = function writeDoubleBE (value, offset, noAssert) {
  return writeDouble(this, value, offset, false, noAssert)
}

// copy(targetBuffer, targetStart=0, sourceStart=0, sourceEnd=buffer.length)
Buffer.prototype.copy = function copy (target, targetStart, start, end) {
  if (!start) start = 0
  if (!end && end !== 0) end = this.length
  if (targetStart >= target.length) targetStart = target.length
  if (!targetStart) targetStart = 0
  if (end > 0 && end < start) end = start

  // Copy 0 bytes; we're done
  if (end === start) return 0
  if (target.length === 0 || this.length === 0) return 0

  // Fatal error conditions
  if (targetStart < 0) {
    throw new RangeError('targetStart out of bounds')
  }
  if (start < 0 || start >= this.length) throw new RangeError('sourceStart out of bounds')
  if (end < 0) throw new RangeError('sourceEnd out of bounds')

  // Are we oob?
  if (end > this.length) end = this.length
  if (target.length - targetStart < end - start) {
    end = target.length - targetStart + start
  }

  var len = end - start
  var i

  if (this === target && start < targetStart && targetStart < end) {
    // descending copy from end
    for (i = len - 1; i >= 0; --i) {
      target[i + targetStart] = this[i + start]
    }
  } else if (len < 1000 || !Buffer.TYPED_ARRAY_SUPPORT) {
    // ascending copy from start
    for (i = 0; i < len; ++i) {
      target[i + targetStart] = this[i + start]
    }
  } else {
    Uint8Array.prototype.set.call(
      target,
      this.subarray(start, start + len),
      targetStart
    )
  }

  return len
}

// Usage:
//    buffer.fill(number[, offset[, end]])
//    buffer.fill(buffer[, offset[, end]])
//    buffer.fill(string[, offset[, end]][, encoding])
Buffer.prototype.fill = function fill (val, start, end, encoding) {
  // Handle string cases:
  if (typeof val === 'string') {
    if (typeof start === 'string') {
      encoding = start
      start = 0
      end = this.length
    } else if (typeof end === 'string') {
      encoding = end
      end = this.length
    }
    if (val.length === 1) {
      var code = val.charCodeAt(0)
      if (code < 256) {
        val = code
      }
    }
    if (encoding !== undefined && typeof encoding !== 'string') {
      throw new TypeError('encoding must be a string')
    }
    if (typeof encoding === 'string' && !Buffer.isEncoding(encoding)) {
      throw new TypeError('Unknown encoding: ' + encoding)
    }
  } else if (typeof val === 'number') {
    val = val & 255
  }

  // Invalid ranges are not set to a default, so can range check early.
  if (start < 0 || this.length < start || this.length < end) {
    throw new RangeError('Out of range index')
  }

  if (end <= start) {
    return this
  }

  start = start >>> 0
  end = end === undefined ? this.length : end >>> 0

  if (!val) val = 0

  var i
  if (typeof val === 'number') {
    for (i = start; i < end; ++i) {
      this[i] = val
    }
  } else {
    var bytes = Buffer.isBuffer(val)
      ? val
      : utf8ToBytes(new Buffer(val, encoding).toString())
    var len = bytes.length
    for (i = 0; i < end - start; ++i) {
      this[i + start] = bytes[i % len]
    }
  }

  return this
}

// HELPER FUNCTIONS
// ================

var INVALID_BASE64_RE = /[^+\/0-9A-Za-z-_]/g

function base64clean (str) {
  // Node strips out invalid characters like \n and \t from the string, base64-js does not
  str = stringtrim(str).replace(INVALID_BASE64_RE, '')
  // Node converts strings with length < 2 to ''
  if (str.length < 2) return ''
  // Node allows for non-padded base64 strings (missing trailing ===), base64-js does not
  while (str.length % 4 !== 0) {
    str = str + '='
  }
  return str
}

function stringtrim (str) {
  if (str.trim) return str.trim()
  return str.replace(/^\s+|\s+$/g, '')
}

function toHex (n) {
  if (n < 16) return '0' + n.toString(16)
  return n.toString(16)
}

function utf8ToBytes (string, units) {
  units = units || Infinity
  var codePoint
  var length = string.length
  var leadSurrogate = null
  var bytes = []

  for (var i = 0; i < length; ++i) {
    codePoint = string.charCodeAt(i)

    // is surrogate component
    if (codePoint > 0xD7FF && codePoint < 0xE000) {
      // last char was a lead
      if (!leadSurrogate) {
        // no lead yet
        if (codePoint > 0xDBFF) {
          // unexpected trail
          if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD)
          continue
        } else if (i + 1 === length) {
          // unpaired lead
          if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD)
          continue
        }

        // valid lead
        leadSurrogate = codePoint

        continue
      }

      // 2 leads in a row
      if (codePoint < 0xDC00) {
        if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD)
        leadSurrogate = codePoint
        continue
      }

      // valid surrogate pair
      codePoint = (leadSurrogate - 0xD800 << 10 | codePoint - 0xDC00) + 0x10000
    } else if (leadSurrogate) {
      // valid bmp char, but last char was a lead
      if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD)
    }

    leadSurrogate = null

    // encode utf8
    if (codePoint < 0x80) {
      if ((units -= 1) < 0) break
      bytes.push(codePoint)
    } else if (codePoint < 0x800) {
      if ((units -= 2) < 0) break
      bytes.push(
        codePoint >> 0x6 | 0xC0,
        codePoint & 0x3F | 0x80
      )
    } else if (codePoint < 0x10000) {
      if ((units -= 3) < 0) break
      bytes.push(
        codePoint >> 0xC | 0xE0,
        codePoint >> 0x6 & 0x3F | 0x80,
        codePoint & 0x3F | 0x80
      )
    } else if (codePoint < 0x110000) {
      if ((units -= 4) < 0) break
      bytes.push(
        codePoint >> 0x12 | 0xF0,
        codePoint >> 0xC & 0x3F | 0x80,
        codePoint >> 0x6 & 0x3F | 0x80,
        codePoint & 0x3F | 0x80
      )
    } else {
      throw new Error('Invalid code point')
    }
  }

  return bytes
}

function asciiToBytes (str) {
  var byteArray = []
  for (var i = 0; i < str.length; ++i) {
    // Node's code seems to be doing this and not & 0x7F..
    byteArray.push(str.charCodeAt(i) & 0xFF)
  }
  return byteArray
}

function utf16leToBytes (str, units) {
  var c, hi, lo
  var byteArray = []
  for (var i = 0; i < str.length; ++i) {
    if ((units -= 2) < 0) break

    c = str.charCodeAt(i)
    hi = c >> 8
    lo = c % 256
    byteArray.push(lo)
    byteArray.push(hi)
  }

  return byteArray
}

function base64ToBytes (str) {
  return base64.toByteArray(base64clean(str))
}

function blitBuffer (src, dst, offset, length) {
  for (var i = 0; i < length; ++i) {
    if ((i + offset >= dst.length) || (i >= src.length)) break
    dst[i + offset] = src[i]
  }
  return i
}

function isnan (val) {
  return val !== val // eslint-disable-line no-self-compare
}

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(44)))

/***/ }),
/* 85 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _css_boardtable_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(88);
/* harmony import */ var _css_boardtable_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_css_boardtable_css__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_AElement__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(8);




var _ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].$;


/***
 * @extends AElement
 * @constructor
 */
function Board() {
}


Board.tag = "board";
Board.render = function () {
    return _({
        class: 'as-board',
        extendEvent: ['sizechange', 'changeposition']
    });
};


Board.prototype.getParent = function () {
    var parent = this.parentElement;
    while (parent) {
        if (parent.classList.contains('ac-board-table')) return parent;
        parent = parent.parentElement;
    }
    return null;
};


_ACore__WEBPACK_IMPORTED_MODULE_1__[/* default */ "d"].install(Board);

/* harmony default export */ __webpack_exports__["a"] = (Board);

/***/ }),
/* 86 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* unused harmony export NOT_READY */
/* unused harmony export READY */
/* unused harmony export START */
/* unused harmony export RUNNING */
/* unused harmony export PAUSE */
/* unused harmony export STOP */
/* unused harmony export ERROR */
/* unused harmony export STATE_TO_STRING */
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
/* harmony import */ var absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1);
/* harmony import */ var absol_src_HTML5_AElement__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(8);




var _ = _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"]._;
var $ = _ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].$;

var NOT_READY = 0;
var READY = 1;
var START = 2;
var RUNNING = 3;
var PAUSE = 4;
var STOP = 5;
var ERROR = 6;
var STATE_TO_STRING = ['NOT_READY', 'READY', 'START', 'RUNNING', 'PAUSE', 'STOP', 'ERROR'];



/**
 * @augments AElement
 * @augments HTMLCanvasElement
 * @constructor
 */
function Sprite() {
    this.loadTextureTimeout = 5000;
    this._textureLoaded = false;
    this._state = NOT_READY;
    this.defineEvent(['ready', 'srcerror', 'play', 'resume', 'pause', 'stop', 'reset', 'end', 'frame']);
    this._length = 60;
    this._lastDrawFrame = -1;
    this._frameIndex = 0;
    this._timeout = -1;
    this.ctx = this.getContext('2d');
    this._fps = 10;
    this._lastDrawMilis = 0;
    this._overTime = 0;
    this.draw = this.draw.bind(this);
    this.texture = null;
    this._frames = { type: 'grid', col: 1, row: 1 };
    this._loop = false;
}


Sprite.cache = {};


Sprite.prototype.draw = function () {
    //todo
    var now = new Date().getTime();
    var dt = this._overTime + now - this._lastDrawMilis;
    var di = Math.floor(dt / 1000 * this._fps);
    var frameIndex = (this._frameIndex + di);
    if (this._loop) {
        frameIndex = frameIndex % this._length;
    }
    else {
        frameIndex = Math.min(this._length - 1, frameIndex);
    }

    if (!isNaN(this._frameIndex) && frameIndex != this._frameIndex) {
        this.drawFrame(this._frameIndex);
    }

    this._overTime = dt - di * 1000 / this._fps;
    var nextTime = now + 1000 / this._fps - this._overTime - new Date().getTime();
    this._lastDrawMilis = now;
    this._frameIndex = frameIndex;

    this._timeout = -1;
    if (this._loop || frameIndex + 1 < this._length) {
        if (this._state == RUNNING)
            this._timeout = setTimeout(this.draw, nextTime);
    }
    else this.stop();
};

Sprite.prototype.drawFrame = function (index) {
    if (this._lastDrawFrame == index) return;
    this._lastDrawFrame = index;
    this.ctx.clearRect(0, 0, this.width, this.height);
    if (this._frames.type == 'grid') {
        var imgWidth = this.texture.naturalWidth;
        var imgHeight = this.texture.naturalHeight;
        var sHeight = imgHeight / this._frames.row;
        var sWidth = imgWidth / this._frames.col;
        var sx = (index % this._frames.col) * sWidth;
        var sy = Math.floor(index / this._frames.col) * sHeight;
        this.ctx.drawImage(this.texture, sx, sy, sWidth, sHeight, 0, 0, this.width, this.height)
    }
    else {

    }
    this.emit('frame', { name: 'frame', target: this, frameIndex: index }, this);
};

Sprite.prototype.stop = function () {
    this.pause();
    if (this._state != PAUSE) return this;
    this._state = STOP;
    this.emit('stop', { name: 'stop', target: this }, this);
    return this;
};


Sprite.prototype.pause = function () {
    if (this._state != RUNNING) return this;
    this._state = PAUSE;
    if (this._timeout > 0) {
        clearTimeout(this._timeout);
        this._timeout = -1;
    }
    var now = new Date().getTime();
    this._overTime += now - this._lastDrawMilis;
    this.emit('pause', { name: 'pause', target: this }, this);
};

Sprite.prototype.resume = function () {
    if (this._state != START && this._state != PAUSE) return this;
    if (this._state == RUNNING) return this;
    this._state = RUNNING;
    var now = new Date().getTime();
    this._lastDrawMilis = now;
    this.draw();
    this.emit('resume', { name: 'pause', target: this }, this);
};

Sprite.prototype.reset = function () {
    this._frameIndex = 0;
    this._overTime = 0;
}

Sprite.prototype.play = function () {
    if (this._state == ERROR) return this;
    if (this._state == RUNNING) return this;
    if (this._state == READY || this._state == STOP) {
        this.reset();
    }
    this._state = START;
    this.emit('play', { name: 'start', target: this }, this);
    this.resume();
    return this;
};

Sprite.prototype.afterReady = function () {
    var thisSprite = this;
    if (this._state != NOT_READY && this._state != ERROR)
        return Promise.resolve();
    else return new Promise(function (rs, rj) {
        thisSprite.once('ready', rs);
        thisSprite.once('srcerror', rj);
    });
};

Sprite.tag = 'sprite';

Sprite.render = function () {
    return _('canvas.as-sprite');
};


Sprite.property = {};


Sprite.property.frames = {
    set: function (value) {
        this.stop();
        this._lastDrawFrame = -1;
        if (value && value.type == 'grid') {
            this._length = value.col * value.row;
        }
        this._frames = value;
        if (this._textureLoaded && this._frames && this._state == NOT_READY) {//todo: verify frame
            this._state = READY;
            this.emit('ready', { target: this, name: 'ready' }, this);
        }
    },
    get: function () {
        return this._frames;
    }
};

Sprite.property.frameIndex = {
    set: function (value) {
        value = value || 0;
        if (value < 0) value = this._length - 1;
        if (this._loop) {
            this._frameIndex = value % this._length;
            this._overTime = 0;
        }
        else {
            this._frameIndex = Math.max(this._length - 1, value);
            this._overTime = 0;

        }
        this.drawFrame(this._frameIndex);
    },
    get: function () {
        return this._frameIndex;
    }
};


Sprite.property.src = {
    set: function (value) {
        this.stop();
        this._lastDrawFrame = -1;//did not draw any thing 
        value = value || [];
        var lastSrc = this._src;
        this._src = value || null;
        if (lastSrc == this._src) return;
        if (!value) this.texture = null;
        else {
            var cImage;
            if (!Sprite.cache[this._src]) {
                cImage = new Image();
                Sprite.cache[this._src] = cImage;
                cImage.src = this._src;
            }
            else {
                cImage = Sprite.cache[this._src];
            }
            this.texture = cImage;
            this._state = NOT_READY;
            var thisSprite = this;
            this._textureLoaded = false;
            absol_src_HTML5_Dom__WEBPACK_IMPORTED_MODULE_1__[/* default */ "b"].waitImageLoaded(this.texture, this.loadTextureTimeout).then(function (rs) {
                    if (thisSprite.texture == cImage) {
                        thisSprite._textureLoaded = true;
                        if (thisSprite._frames) {
                            thisSprite._lastDrawFrame = -1;
                            thisSprite._state = READY;
                            thisSprite.emit('ready', { target: thisSprite, name: 'ready' }, thisSprite);
                        }
                    }
                },
                function () {
                    if (thisSprite.texture == cImage) {
                        thisSprite._state = ERROR;
                        thisSprite.emit('srcerror', { target: thisSprite, name: 'srcerror' }, thisSprite);
                    }
                });
        }

    },
    get: function () {
        return this._src;
    }
}

Sprite.property.state = {
    get: function () {
        return STATE_TO_STRING[this._state];
    }
};
Sprite.property.length = {
    get: function () {
        return this._length;
    }
};

Sprite.property.fps = {
    set: function (value) {
        value = Math.max(value || 0, 0);
        this._fps = value;
        if (this._state == RUNNING) {
            clearTimeout(this._timeout);
            this._timeout = -1;
            var now = new Date().getTime();
            this._overTime += now - this._lastDrawMilis;
            this._overTime = Math.min(1000 / this._fps, this._overTime);
            this.draw();
        }

    },
    get: function () {
        return this._fps;
    }
};

Sprite.property.loop = {
    set: function (value) {
        value = !!value;
        this._loop = value;
    },
    get: function () {
        return this._loop;
    }
}

_ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].install(Sprite);

/* harmony default export */ __webpack_exports__["a"] = (Sprite);

/***/ }),
/* 87 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony import */ var _ACore__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
/* harmony import */ var _DateInYearPicker__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(77);
/* harmony import */ var _Follower__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(25);
/* harmony import */ var absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(3);
/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(4);
/* harmony import */ var absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5);







/***
 * @extends AElement
 * @constructor
 */
function DateInYearInput() {
    this._format = 'dd/MM';
    this._value = null;
    this.$clearBtn = Object(_ACore__WEBPACK_IMPORTED_MODULE_0__[/* $ */ "a"])('.as-time-input-clear-btn', this)
        .on('click', this.clear.bind(this, true));
    this.$input = Object(_ACore__WEBPACK_IMPORTED_MODULE_0__[/* $ */ "a"])('input', this);
    this.on('click', this.eventHandler.click);
}

DateInYearInput.tag = 'DateInYearInput'.toLowerCase();

DateInYearInput.render = function () {
    return Object(_ACore__WEBPACK_IMPORTED_MODULE_0__[/* _ */ "c"])({
        extendEvent: ['change'],
        class: ['as-date-time-input', 'as-date-in-year-input', 'as-empty'],
        child: [
            {
                tag: 'input',
                class: 'as-date-time-input-text',
                attr: {
                    ondrop: "return false;",
                    readOnly: true
                },
                props: {
                    value: 'dd/MM'
                }
            },
            {
                tag: 'button',
                class: 'as-time-input-clear-btn',
                child: 'span.mdi.mdi-close-circle'
            },
            {
                tag: 'button',
                class: 'as-date-time-input-icon-btn',
                child: 'span.mdi.mdi-calendar-today'
            }
        ]
    });
};

DateInYearInput.prototype.share = {
    $follower: null,
    $picker: null,
    $input: null
};


DateInYearInput.prototype._preparePicker = function () {
    if (this.share.$picker) return;
    this.share.$picker = Object(_ACore__WEBPACK_IMPORTED_MODULE_0__[/* _ */ "c"])({
        tag: _DateInYearPicker__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"].tag,
        class:'as-date-in-year-follower'
    });
    this.share.$follower = Object(_ACore__WEBPACK_IMPORTED_MODULE_0__[/* _ */ "c"])({
        tag: _Follower__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"].tag,
        child: this.share.$picker
    });
};

DateInYearInput.prototype.clear = function (userAction, event) {
    var pValue = this.value;
    this.value = null;
    if (pValue) {
        this.emit('change', {type: 'change', action: 'clear', target: this, originalEvent: event}, this)
    }
};

DateInYearInput.prototype._attachPicker = function () {
    this._preparePicker();
    if (this.share.$input === this) return;
    if (this.share.$input) this.share.$input._releasePicker();
    this.share.$input = this;
    this.share.$follower.addTo(document.body);
    this.share.$follower.followTarget = this;
    this.share.$picker.value = this._value;

    this.share.$picker.on('change', this.eventHandler.pickerChange);
    setTimeout(function () {
        document.addEventListener('click', this.eventHandler.clickOut);
    }.bind(this), 0);
};


DateInYearInput.prototype._releasePicker = function () {
    if (this.share.$input !== this) return;
    var cValue = this._value;
    var value = this.share.$picker.value;
    var nValue = this._normalizeValue(value);
    this.share.$input = null;
    this.share.$picker.followTarget = null;
    this.share.$follower.remove();
    this.share.$picker.off('change', this.eventHandler.pickerChange);
    document.removeEventListener('click', this.eventHandler.clickOut);
    var changed = !cValue !== !nValue;
    if (nValue && !changed) {
        changed = cValue.date === nValue.date && cValue.month === nValue.month;
    }
    if (changed) {
        this._value = value;
        this.emit('change', {type: 'change', value: nValue, target: this}, this);
    }
};


DateInYearInput.prototype._normalizeValue = function (value) {
    if (!value) return null;
    var m = Math.min(11, Math.max(0, Math.floor(value.month)));
    if (isNaN(m)) return null;
    var dim = Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_5__["compareDate"])(Object(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_5__["nextMonth"])(new Date(2000, m, 1)), new Date(2000, m, 1));
    var d = Math.min(dim, Math.max(1, Math.floor(value.date)));
    if (isNaN(d)) return null;
    return {
        date: d,
        month: m
    };
};

DateInYearInput.prototype._updateValueText = function () {
    var value = this._value;
    if (value) {
        this.$input.value = this._format.replace(new RegExp(absol_src_Time_datetime__WEBPACK_IMPORTED_MODULE_5__["DATE_TIME_TOKEN_RGX"].source, 'g'), function (full) {
            switch (full) {
                case 'dd':
                case 'd':
                    if (Object(_utils__WEBPACK_IMPORTED_MODULE_4__["isRealNumber"])(value.date)) {
                        return Object(_utils__WEBPACK_IMPORTED_MODULE_4__["zeroPadding"])(value.date, full.length);
                    }
                    return full;
                case 'M':
                case 'MM':
                    if (Object(_utils__WEBPACK_IMPORTED_MODULE_4__["isRealNumber"])(value.month)) {
                        return Object(_utils__WEBPACK_IMPORTED_MODULE_4__["zeroPadding"])(value.month + 1, full.length);
                    }
                    return full;
                default:
                    return full;
            }
        });
    } else {
        this.$input.value = this._format;
    }
    if (this.$input.value === this._format) {
        this.addClass('as-empty');
    } else {
        this.removeClass('as-empty');
    }
};

DateInYearInput.property = {};

DateInYearInput.property.value = {
    set: function (value) {
        value = this._normalizeValue(value);
        this._value = value;
        this._updateValueText();
    },
    get: function () {
        return this._normalizeValue(this._value);
    }
};

DateInYearInput.property.notNull = {
    set: function (value) {
        if (value) {
            this.addClass('as-must-not-null');
        } else {
            this.removeClass('as-must-not-null');
        }
    },
    get: function () {
        return this.containsClass('as-must-not-null');
    }
};

DateInYearInput.property.disabled = {
    set: function (value) {
        if (value) {
            this.addClass('as-disabled');
            this.$input.disabled = true;
        } else {
            this.removeClass('as-disabled');
            this.$input.disabled = false;
        }
    },
    get: function () {
        return this.containsClass('as-disabled');
    }
};

/***
 * @memberOf DateInYearInput#
 * @type {{}}
 */
DateInYearInput.eventHandler = {};

/***
 * @this DateInYearInput
 * @param event
 */
DateInYearInput.eventHandler.click = function (event) {
    if (Object(absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_3__[/* hitElement */ "d"])(this.$clearBtn, event)) return;
    this._attachPicker();
};

/***
 * @this DateInYearInput
 * @param event
 */
DateInYearInput.eventHandler.clickOut = function (event) {
    if (Object(absol_src_HTML5_EventEmitter__WEBPACK_IMPORTED_MODULE_3__[/* hitElement */ "d"])(this.share.$follower, event)) return;
    this._releasePicker();
};

DateInYearInput.eventHandler.pickerChange = function () {
    this._value = this.share.$picker.value;
    this._updateValueText();
};


_ACore__WEBPACK_IMPORTED_MODULE_0__[/* default */ "d"].install(DateInYearInput);

/* harmony default export */ __webpack_exports__["a"] = (DateInYearInput);

/***/ }),
/* 88 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(119);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 89 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(144);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 90 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(147);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 91 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(148);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 92 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(149);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 93 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(191);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 94 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(206);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 95 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(209);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 96 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(230);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 97 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(259);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 98 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(300);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 99 */
/***/ (function(module, exports) {

// shim for using process in browser
var process = module.exports = {};

// cached from whatever global is present so that test runners that stub it
// don't break things.  But we need to wrap it in a try catch in case it is
// wrapped in strict mode code which doesn't define any globals.  It's inside a
// function because try/catches deoptimize in certain engines.

var cachedSetTimeout;
var cachedClearTimeout;

function defaultSetTimout() {
    throw new Error('setTimeout has not been defined');
}
function defaultClearTimeout () {
    throw new Error('clearTimeout has not been defined');
}
(function () {
    try {
        if (typeof setTimeout === 'function') {
            cachedSetTimeout = setTimeout;
        } else {
            cachedSetTimeout = defaultSetTimout;
        }
    } catch (e) {
        cachedSetTimeout = defaultSetTimout;
    }
    try {
        if (typeof clearTimeout === 'function') {
            cachedClearTimeout = clearTimeout;
        } else {
            cachedClearTimeout = defaultClearTimeout;
        }
    } catch (e) {
        cachedClearTimeout = defaultClearTimeout;
    }
} ())
function runTimeout(fun) {
    if (cachedSetTimeout === setTimeout) {
        //normal enviroments in sane situations
        return setTimeout(fun, 0);
    }
    // if setTimeout wasn't available but was latter defined
    if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) {
        cachedSetTimeout = setTimeout;
        return setTimeout(fun, 0);
    }
    try {
        // when when somebody has screwed with setTimeout but no I.E. maddness
        return cachedSetTimeout(fun, 0);
    } catch(e){
        try {
            // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally
            return cachedSetTimeout.call(null, fun, 0);
        } catch(e){
            // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error
            return cachedSetTimeout.call(this, fun, 0);
        }
    }


}
function runClearTimeout(marker) {
    if (cachedClearTimeout === clearTimeout) {
        //normal enviroments in sane situations
        return clearTimeout(marker);
    }
    // if clearTimeout wasn't available but was latter defined
    if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {
        cachedClearTimeout = clearTimeout;
        return clearTimeout(marker);
    }
    try {
        // when when somebody has screwed with setTimeout but no I.E. maddness
        return cachedClearTimeout(marker);
    } catch (e){
        try {
            // When we are in I.E. but the script has been evaled so I.E. doesn't  trust the global object when called normally
            return cachedClearTimeout.call(null, marker);
        } catch (e){
            // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error.
            // Some versions of I.E. have different rules for clearTimeout vs setTimeout
            return cachedClearTimeout.call(this, marker);
        }
    }



}
var queue = [];
var draining = false;
var currentQueue;
var queueIndex = -1;

function cleanUpNextTick() {
    if (!draining || !currentQueue) {
        return;
    }
    draining = false;
    if (currentQueue.length) {
        queue = currentQueue.concat(queue);
    } else {
        queueIndex = -1;
    }
    if (queue.length) {
        drainQueue();
    }
}

function drainQueue() {
    if (draining) {
        return;
    }
    var timeout = runTimeout(cleanUpNextTick);
    draining = true;

    var len = queue.length;
    while(len) {
        currentQueue = queue;
        queue = [];
        while (++queueIndex < len) {
            if (currentQueue) {
                currentQueue[queueIndex].run();
            }
        }
        queueIndex = -1;
        len = queue.length;
    }
    currentQueue = null;
    draining = false;
    runClearTimeout(timeout);
}

process.nextTick = function (fun) {
    var args = new Array(arguments.length - 1);
    if (arguments.length > 1) {
        for (var i = 1; i < arguments.length; i++) {
            args[i - 1] = arguments[i];
        }
    }
    queue.push(new Item(fun, args));
    if (queue.length === 1 && !draining) {
        runTimeout(drainQueue);
    }
};

// v8 likes predictible objects
function Item(fun, array) {
    this.fun = fun;
    this.array = array;
}
Item.prototype.run = function () {
    this.fun.apply(null, this.array);
};
process.title = 'browser';
process.browser = true;
process.env = {};
process.argv = [];
process.version = ''; // empty string to avoid regexp issues
process.versions = {};

function noop() {}

process.on = noop;
process.addListener = noop;
process.once = noop;
process.off = noop;
process.removeListener = noop;
process.removeAllListeners = noop;
process.emit = noop;
process.prependListener = noop;
process.prependOnceListener = noop;

process.listeners = function (name) { return [] }

process.binding = function (name) {
    throw new Error('process.binding is not supported');
};

process.cwd = function () { return '/' };
process.chdir = function (dir) {
    throw new Error('process.chdir is not supported');
};
process.umask = function() { return 0; };


/***/ }),
/* 100 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(setImmediate, global) {/* harmony import */ var atob__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(103);
/* harmony import */ var atob__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(atob__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var btoa__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(104);
/* harmony import */ var btoa__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(btoa__WEBPACK_IMPORTED_MODULE_1__);



if (!('atob' in window)) {
    window.atob = atob__WEBPACK_IMPORTED_MODULE_0___default.a;
}
if (!('btoa' in window)) {
    window.btoa = btoa__WEBPACK_IMPORTED_MODULE_1___default.a;
}

!function (e, n) {
    "object" == typeof exports && "undefined" != typeof module ? n() : "function" == typeof define && __webpack_require__(325) ? define(n) : n()
}(0, function () {
    "use strict";

    function e(e) {
        var n = this.constructor;
        return this.then(function (t) {
            return n.resolve(e()).then(function () {
                return t
            })
        }, function (t) {
            return n.resolve(e()).then(function () {
                return n.reject(t)
            })
        })
    }

    function n() {
    }

    function t(e) {
        if (!(this instanceof t)) throw new TypeError("Promises must be constructed via new");
        if ("function" != typeof e) throw new TypeError("not a function");
        this._state = 0, this._handled = !1, this._value = undefined, this._deferreds = [], u(e, this)
    }

    function o(e, n) {
        for (; 3 === e._state;) e = e._value;
        0 !== e._state ? (e._handled = !0, t._immediateFn(function () {
            var t = 1 === e._state ? n.onFulfilled : n.onRejected;
            if (null !== t) {
                var o;
                try {
                    o = t(e._value)
                } catch (f) {
                    return void i(n.promise, f)
                }
                r(n.promise, o)
            }
            else (1 === e._state ? r : i)(n.promise, e._value)
        })) : e._deferreds.push(n)
    }

    function r(e, n) {
        try {
            if (n === e) throw new TypeError("A promise cannot be resolved with itself.");
            if (n && ("object" == typeof n || "function" == typeof n)) {
                var o = n.then;
                if (n instanceof t) return e._state = 3, e._value = n, void f(e);
                if ("function" == typeof o) return void u(function (e, n) {
                    return function () {
                        e.apply(n, arguments)
                    }
                }(o, n), e)
            }
            e._state = 1, e._value = n, f(e)
        } catch (r) {
            i(e, r)
        }
    }

    function i(e, n) {
        e._state = 2, e._value = n, f(e)
    }

    function f(e) {
        2 === e._state && 0 === e._deferreds.length && t._immediateFn(function () {
            e._handled || t._unhandledRejectionFn(e._value)
        });
        for (var n = 0, r = e._deferreds.length; r > n; n++) o(e, e._deferreds[n]);
        e._deferreds = null
    }

    function u(e, n) {
        var t = !1;
        try {
            e(function (e) {
                t || (t = !0, r(n, e))
            }, function (e) {
                t || (t = !0, i(n, e))
            })
        } catch (o) {
            if (t) return;
            t = !0, i(n, o)
        }
    }

    var c = setTimeout;
    t.prototype["catch"] = function (e) {
        return this.then(null, e)
    }, t.prototype.then = function (e, t) {
        var r = new this.constructor(n);
        return o(this, new function (e, n, t) {
            this.onFulfilled = "function" == typeof e ? e : null, this.onRejected = "function" == typeof n ? n : null, this.promise = t
        }(e, t, r)), r
    }, t.prototype["finally"] = e, t.all = function (e) {
        return new t(function (n, t) {
            function o(e, f) {
                try {
                    if (f && ("object" == typeof f || "function" == typeof f)) {
                        var u = f.then;
                        if ("function" == typeof u) return void u.call(f, function (n) {
                            o(e, n)
                        }, t)
                    }
                    r[e] = f, 0 == --i && n(r)
                } catch (c) {
                    t(c)
                }
            }

            if (!e || "undefined" == typeof e.length) throw new TypeError("Promise.all accepts an array");
            var r = Array.prototype.slice.call(e);
            if (0 === r.length) return n([]);
            for (var i = r.length, f = 0; r.length > f; f++) o(f, r[f])
        })
    }, t.resolve = function (e) {
        return e && "object" == typeof e && e.constructor === t ? e : new t(function (n) {
            n(e)
        })
    }, t.reject = function (e) {
        return new t(function (n, t) {
            t(e)
        })
    }, t.race = function (e) {
        return new t(function (n, t) {
            for (var o = 0, r = e.length; r > o; o++) e[o].then(n, t)
        })
    }, t._immediateFn = "function" == typeof setImmediate && function (e) {
        setImmediate(e)
    } || function (e) {
        c(e, 0)
    }, t._unhandledRejectionFn = function (e) {
        void 0 !== console && console && console.warn("Possible Unhandled Promise Rejection:", e)
    };
    var l = function () {
        if ("undefined" != typeof self) return self;
        if ("undefined" != typeof window) return window;
        if ("undefined" != typeof global) return global;
        throw Error("unable to locate global object")
    }();
    "Promise" in l ? l.Promise.prototype["finally"] || (l.Promise.prototype["finally"] = e) : l.Promise = t
});


!(function () {
    var vendors = ['ms', 'moz', 'webkit', 'o'];
    for (var x = 0; x < vendors.length && !window.requestAnimationFrame; ++x) {
        window.requestAnimationFrame = window[vendors[x] + 'RequestAnimationFrame'];
        window.cancelAnimationFrame = window[vendors[x] + 'CancelAnimationFrame']
            || window[vendors[x] + 'CancelRequestAnimationFrame'];
    }

    if (!window.requestAnimationFrame)
        window.requestAnimationFrame = function (callback, element) {
            var id = window.setTimeout(function () {
                    callback(element);
                },
                1000 / 60);
            return id;
        };

    if (!window.cancelAnimationFrame)
        window.cancelAnimationFrame = function (id) {
            clearTimeout(id);
        };
}());


//Object
(function () {
    'use strict';
    var ObjectProto = Object.prototype,
        defineGetter = ObjectProto.__defineGetter__,
        defineSetter = ObjectProto.__defineSetter__,
        lookupGetter = ObjectProto.__lookupGetter__,
        lookupSetter = ObjectProto.__lookupSetter__,
        hasOwnProp = ObjectProto.hasOwnProperty;


    var supportDom = true;
    try {
        if (Object.defineProperty) {
            Object.defineProperty(document.createElement('div'), 'theRandomName', {
                set: function () {
                },
                get: function () {
                }
            });
        }
    } catch (error) {
        supportDom = false;
    }

    if ((!supportDom || !Object.defineProperty) && defineGetter && defineSetter && lookupGetter && lookupSetter) {
        var originObjetDefineProperty = Object.defineProperty;
        Object.defineProperty = function (obj, prop, descriptor) {
            if (!originObjetDefineProperty || (typeof obj.nodeType === "number" && typeof obj.nodeName === "string")) {
                if (arguments.length < 3) { // all arguments required
                    throw new TypeError("Arguments not optional");
                }

                prop += ""; // convert prop to string

                if (hasOwnProp.call(descriptor, "value")) {
                    if (!lookupGetter.call(obj, prop) && !lookupSetter.call(obj, prop)) {
                        // data property defined and no pre-existing accessors
                        obj[prop] = descriptor.value;
                    }

                    if ((hasOwnProp.call(descriptor, "get") ||
                        hasOwnProp.call(descriptor, "set"))) {
                        // descriptor has a value prop but accessor already exists
                        throw new TypeError("Cannot specify an accessor and a value");
                    }
                }


                if (descriptor.get) {
                    defineGetter.call(obj, prop, descriptor.get);
                }
                if (descriptor.set) {
                    defineSetter.call(obj, prop, descriptor.set);
                }

                return obj;
            }
            else {
                return originObjetDefineProperty.call(this, obj, prop, descriptor);
            }
        };

        var originObjectGetOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
        Object.getOwnPropertyDescriptor = function (obj, prop) {
            if (!originObjectGetOwnPropertyDescriptor || typeof obj.nodeType === "number" && typeof obj.nodeName === "string") {
                if (arguments.length < 2) { // all arguments required
                    throw new TypeError("Arguments not optional.");
                }

                prop += ""; // convert prop to string

                var descriptor = {
                        configurable: true,
                        enumerable: true,
                        writable: true
                    },
                    getter = lookupGetter.call(obj, prop),
                    setter = lookupSetter.call(obj, prop);

                if (!hasOwnProp.call(obj, prop)) {
                    // property doesn't exist or is inherited
                    return descriptor;
                }
                if (!getter && !setter) { // not an accessor so return prop
                    descriptor.value = obj[prop];
                    return descriptor;
                }

                // there is an accessor, remove descriptor.writable;
                // populate descriptor.get and descriptor.set (IE's behavior)
                delete descriptor.writable;
                descriptor.get = descriptor.set = undefined;

                if (getter) {
                    descriptor.get = getter;
                }
                if (setter) {
                    descriptor.set = setter;
                }

                return descriptor;
            }
            else {
                return originObjectGetOwnPropertyDescriptor(obj, prop);
            }
        };
    }

    if (!supportDom || !Object.getOwnPropertyDescriptors) {
        Object.getOwnPropertyDescriptors = function (o) {
            var res = {};
            for (var key in o) {
                res[key] = Object.getOwnPropertyDescriptor(o, key);
            }
            return res;
        };
    }


    if (!supportDom || !Object.defineProperties) {
        Object.defineProperties = function (obj, props) {
            var prop;
            for (prop in props) {
                if (hasOwnProp.call(props, prop)) {
                    Object.defineProperty(obj, prop, props[prop]);
                }
            }
        };
    }


    if (typeof Object.assign != 'function') {
        Object.assign = function (target, varArgs) {
            'use strict';
            if (target == null) {
                throw new TypeError('Cannot convert undefined or null to object');
            }

            var to = Object(target);

            for (var index = 1; index < arguments.length; index++) {
                var nextSource = arguments[index];

                if (nextSource != null) {
                    for (var nextKey in nextSource) {

                        if (Object.prototype.hasOwnProperty.call(nextSource, nextKey)) {
                            to[nextKey] = nextSource[nextKey];
                        }
                    }
                }
            }
            return to;
        };
    }


}());

//string
!(function () {
    if (!String.prototype.startsWith) {
        String.prototype.startsWith = function (searchString, position) {
            position = position || 0;
            return this.indexOf(searchString, position) === position;
        };
    }

    if (!String.prototype.replaceAll) {
        String.prototype.replaceAll = function () {
            var find = arguments[0];
            if (!find) return this;
            if (typeof find == "string") {
                return this.split(find).join(arguments[1]);
            }
            else if (find instanceof RegExp) {
                return this.replace(new RegExp(find.source, 'g'), arguments[1]);
            }
        }
    }
})();


//array
!(function () {
    if (!Array.prototype.fill) {
        Object.defineProperty(Array.prototype, 'fill', {
            value: function (value) {

                // Steps 1-2.
                if (this == null) {
                    throw new TypeError('this is null or not defined');
                }

                var O = Object(this);

                // Steps 3-5.
                var len = O.length >>> 0;

                // Steps 6-7.
                var start = arguments[1];
                var relativeStart = start >> 0;

                // Step 8.
                var k = relativeStart < 0 ?
                    Math.max(len + relativeStart, 0) :
                    Math.min(relativeStart, len);

                // Steps 9-10.
                var end = arguments[2];
                var relativeEnd = end === undefined ?
                    len : end >> 0;

                // Step 11.
                var final = relativeEnd < 0 ?
                    Math.max(len + relativeEnd, 0) :
                    Math.min(relativeEnd, len);

                // Step 12.
                while (k < final) {
                    O[k] = value;
                    k++;
                }

                // Step 13.
                return O;
            }
        });
    }

    if (!Array.prototype.some) {
        Array.prototype.some = function (fun /*, thisp */) {
            "use strict";

            if (this == null) throw new TypeError();

            var t = Object(this),
                len = t.length >>> 0;

            if (typeof fun != "function") throw new TypeError();

            var thisp = arguments[1];

            for (var i = 0; i < len; i++) {
                if (i in t && fun.call(thisp, t[i], i, t))
                    return true;
            }

            return false;
        };
    }
})();


//function
!(function () {
    if (!Function.prototype.bind) {
        var ArrayPrototypeSlice = Array.prototype.slice;
        Function.prototype.bind = function (otherThis) {
            if (typeof this !== 'function') {
                // closest thing possible to the ECMAScript 5
                // internal IsCallable function
                throw new TypeError('Function.prototype.bind - what is trying to be bound is not callable');
            }

            var baseArgs = ArrayPrototypeSlice.call(arguments, 1),
                baseArgsLength = baseArgs.length,
                fToBind = this,
                fNOP = function () {
                },
                fBound = function () {
                    baseArgs.length = baseArgsLength; // reset to default base arguments
                    baseArgs.push.apply(baseArgs, arguments);
                    return fToBind.apply(
                        fNOP.prototype.isPrototypeOf(this) ? this : otherThis, baseArgs
                    );
                };

            if (this.prototype) {
                // Function.prototype doesn't have a prototype property
                fNOP.prototype = this.prototype;
            }
            fBound.prototype = new fNOP();

            return fBound;
        };
    }
})();
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(319).setImmediate, __webpack_require__(44)))

/***/ }),
/* 101 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(339);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 102 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global) {

const external = global.external;
const re_msie = /\b(?:msie |ie |trident\/[0-9].*rv[ :])([0-9.]+)/;
const re_blackberry_10 = /\bbb10\b.+?\bversion\/([\d.]+)/;
const re_blackberry_6_7 = /\bblackberry\b.+\bversion\/([\d.]+)/;
const re_blackberry_4_5 = /\bblackberry\d+\/([\d.]+)/;

const NA_VERSION = "-1";

const DEVICES = [
    ["nokia", function (ua) {
        //  nokia/-1
        if (ua.indexOf("nokia ") !== -1) {
            return /\bnokia ([0-9]+)?/;
        } else {
            return /\bnokia([a-z0-9]+)?/;
        }
    }],
    //Android WP
    ["samsung", function (ua) {
        if (ua.indexOf("samsung") !== -1) {
            return /\bsamsung(?:[ \-](?:sgh|gt|sm))?-([a-z0-9]+)/;
        } else {
            return /\b(?:sgh|sch|gt|sm)-([a-z0-9]+)/;
        }
    }],
    ["wp", function (ua) {
        return ua.indexOf("windows phone ") !== -1 ||
            ua.indexOf("xblwp") !== -1 ||
            ua.indexOf("zunewp") !== -1 ||
            ua.indexOf("windows ce") !== -1;
    }],
    ["pc", "windows"],
    ["ipad", "ipad"],
    // ipod iphone
    ["ipod", "ipod"],
    ["iphone", /\biphone\b|\biph(\d)/],
    ["mac", "macintosh"],
    ["mi", /\bmi[ \-]?([a-z0-9 ]+(?= build|\)))/],
    ["hongmi", /\bhm[ \-]?([a-z0-9]+)/],
    ["aliyun", /\baliyunos\b(?:[\-](\d+))?/],
    ["meizu", function (ua) {
        return ua.indexOf("meizu") >= 0 ?
            /\bmeizu[\/ ]([a-z0-9]+)\b/
            :
            /\bm([0-9cx]{1,4})\b/;
    }],
    ["nexus", /\bnexus ([0-9s.]+)/],
    ["huawei", function (ua) {
        const re_mediapad = /\bmediapad (.+?)(?= build\/huaweimediapad\b)/;
        if (ua.indexOf("huawei-huawei") !== -1) {
            return /\bhuawei\-huawei\-([a-z0-9\-]+)/;
        } else if (re_mediapad.test(ua)) {
            return re_mediapad;
        } else {
            return /\bhuawei[ _\-]?([a-z0-9]+)/;
        }
    }],
    ["lenovo", function (ua) {
        if (ua.indexOf("lenovo-lenovo") !== -1) {
            return /\blenovo\-lenovo[ \-]([a-z0-9]+)/;
        } else {
            return /\blenovo[ \-]?([a-z0-9]+)/;
        }
    }],
    ["zte", function (ua) {
        if (/\bzte\-[tu]/.test(ua)) {
            return /\bzte-[tu][ _\-]?([a-su-z0-9\+]+)/;
        } else {
            return /\bzte[ _\-]?([a-su-z0-9\+]+)/;
        }
    }],
    ["vivo", /\bvivo(?: ([a-z0-9]+))?/],
    ["htc", function (ua) {
        if (/\bhtc[a-z0-9 _\-]+(?= build\b)/.test(ua)) {
            return /\bhtc[ _\-]?([a-z0-9 ]+(?= build))/;
        } else {
            return /\bhtc[ _\-]?([a-z0-9 ]+)/;
        }
    }],
    ["oppo", /\boppo[_ ]([a-z0-9]+)/],
    ["konka", /\bkonka[_\-]([a-z0-9]+)/],
    ["sonyericsson", /\bmt([a-z0-9]+)/],
    ["coolpad", /\bcoolpad[_ ]?([a-z0-9]+)/],
    ["lg", /\blg[\-]([a-z0-9]+)/],
    ["android", /\bandroid\b|\badr\b/],
    ["blackberry", function (ua) {
        if (ua.indexOf("blackberry") >= 0) {
            return /\bblackberry\s?(\d+)/;
        }
        return "bb10";
    }],
];

const OS = [
    ["wp", function (ua) {
        if (ua.indexOf("windows phone ") !== -1) {
            return /\bwindows phone (?:os )?([0-9.]+)/;
        } else if (ua.indexOf("xblwp") !== -1) {
            return /\bxblwp([0-9.]+)/;
        } else if (ua.indexOf("zunewp") !== -1) {
            return /\bzunewp([0-9.]+)/;
        }
        return "windows phone";
    }],
    ["windows", /\bwindows nt ([0-9.]+)/],
    ["macosx", /\bmac os x ([0-9._]+)/],
    ["ios", function (ua) {
        if (/\bcpu(?: iphone)? os /.test(ua)) {
            return /\bcpu(?: iphone)? os ([0-9._]+)/;
        } else if (ua.indexOf("iph os ") !== -1) {
            return /\biph os ([0-9_]+)/;
        } else {
            return /\bios\b/;
        }
    }],
    ["yunos", /\baliyunos ([0-9.]+)/],
    ["android", function (ua) {
        if (ua.indexOf("android") >= 0) {
            return /\bandroid[ \/-]?([0-9.x]+)?/;
        } else if (ua.indexOf("adr") >= 0) {
            if (ua.indexOf("mqqbrowser") >= 0) {
                return /\badr[ ]\(linux; u; ([0-9.]+)?/;
            } else {
                return /\badr(?:[ ]([0-9.]+))?/;
            }
        }
        return "android";
        //return /\b(?:android|\badr)(?:[\/\- ](?:\(linux; u; )?)?([0-9.x]+)?/;
    }],
    ["chromeos", /\bcros i686 ([0-9.]+)/],
    ["linux", "linux"],
    ["windowsce", /\bwindows ce(?: ([0-9.]+))?/],
    ["symbian", /\bsymbian(?:os)?\/([0-9.]+)/],
    ["blackberry", function (ua) {
        const m = ua.match(re_blackberry_10) ||
            ua.match(re_blackberry_6_7) ||
            ua.match(re_blackberry_4_5);
        return m ? { version: m[1] } : "blackberry";
    }],
    ['ie', /\rv\:\/([0-9.]+)/]
];


const ENGINE = [
    ["edgehtml", /edge\/([0-9.]+)/],
    ["trident", re_msie],
    ["blink", function () {
        return "chrome" in global && "CSS" in global && /\bapplewebkit[\/]?([0-9.+]+)/;
    }],
    ["webkit", /\bapplewebkit[\/]?([0-9.+]+)/],
    ["gecko", function (ua) {
        const match = ua.match(/\brv:([\d\w.]+).*\bgecko\/(\d+)/);
        if (match) {
            return {
                version: match[1] + "." + match[2],
            };
        }
    }],
    ["presto", /\bpresto\/([0-9.]+)/],
    ["androidwebkit", /\bandroidwebkit\/([0-9.]+)/],
    ["coolpadwebkit", /\bcoolpadwebkit\/([0-9.]+)/],
    ["u2", /\bu2\/([0-9.]+)/],
    ["u3", /\bu3\/([0-9.]+)/],
];
const BROWSER = [
    ['coccoc', /coc_coc_browser\/([0-9.]+)/],
    // Microsoft Edge Browser, Default browser in Windows 10.
    ["edge", /edge\/([0-9.]+)/],
    ["chrome-edge", /chrome.+edg\/([0-9.]+)/],
    // Sogou.
    ["sogou", function (ua) {
        if (ua.indexOf("sogoumobilebrowser") >= 0) {
            return /sogoumobilebrowser\/([0-9.]+)/;
        } else if (ua.indexOf("sogoumse") >= 0) {
            return true;
        }
        return / se ([0-9.x]+)/;
    }],

    // Maxthon
    ["maxthon", function () {
        try {
            if (external && (external.mxVersion || external.max_version)) {
                return {
                    version: external.mxVersion || external.max_version,
                };
            }
        } catch (ex) { /* */ }
        return /\b(?:maxthon|mxbrowser)(?:[ \/]([0-9.]+))?/;
    }],
    ["micromessenger", /\bmicromessenger\/([\d.]+)/],
    ["qq", /\bm?qqbrowser\/([0-9.]+)/],
    ["green", "greenbrowser"],
    ["tt", /\btencenttraveler ([0-9.]+)/],
    ["liebao", function (ua) {
        if (ua.indexOf("liebaofast") >= 0) {
            return /\bliebaofast\/([0-9.]+)/;
        }
        if (ua.indexOf("lbbrowser") === -1) { return false; }
        var version;
        try {
            if (external && external.LiebaoGetVersion) {
                version = external.LiebaoGetVersion();
            }
        } catch (ex) { /* */ }
        return {
            version: version || NA_VERSION,
        };
    }],
    ["tao", /\btaobrowser\/([0-9.]+)/],
    ["coolnovo", /\bcoolnovo\/([0-9.]+)/],
    ["saayaa", "saayaa"],
    ["baidu", /\b(?:ba?idubrowser|baiduhd)[ \/]([0-9.x]+)/],
    ["ie", re_msie],
    ["mi", /\bmiuibrowser\/([0-9.]+)/],
    ["opera", function (ua) {
        const re_opera_old = /\bopera.+version\/([0-9.ab]+)/;
        const re_opera_new = /\bopr\/([0-9.]+)/;
        return re_opera_old.test(ua) ? re_opera_old : re_opera_new;
    }],
    ["oupeng", /\boupeng\/([0-9.]+)/],
    ["yandex", /yabrowser\/([0-9.]+)/],
    ["ali-ap", function (ua) {
        if (ua.indexOf("aliapp") > 0) {
            return /\baliapp\(ap\/([0-9.]+)\)/;
        } else {
            return /\balipayclient\/([0-9.]+)\b/;
        }
    }],
    ["ali-ap-pd", /\baliapp\(ap-pd\/([0-9.]+)\)/],
    ["ali-am", /\baliapp\(am\/([0-9.]+)\)/],
    ["ali-tb", /\baliapp\(tb\/([0-9.]+)\)/],
    ["ali-tb-pd", /\baliapp\(tb-pd\/([0-9.]+)\)/],
    ["ali-tm", /\baliapp\(tm\/([0-9.]+)\)/],
    ["ali-tm-pd", /\baliapp\(tm-pd\/([0-9.]+)\)/],

    ["uc", function (ua) {
        if (ua.indexOf("ucbrowser/") >= 0) {
            return /\bucbrowser\/([0-9.]+)/;
        } else if (ua.indexOf("ubrowser/") >= 0) {
            return /\bubrowser\/([0-9.]+)/;
        } else if (/\buc\/[0-9]/.test(ua)) {
            return /\buc\/([0-9.]+)/;
        } else if (ua.indexOf("ucweb") >= 0) {
            // `ucweb/2.0` is compony info.
            // `UCWEB8.7.2.214/145/800` is browser info.
            return /\bucweb([0-9.]+)?/;
        } else {
            return /\b(?:ucbrowser|uc)\b/;
        }
    }],
    ["baiduboxapp",
        function (ua) {
            var back = 0;
            var a;
            if (/ baiduboxapp\//i.test(ua)) {
                a = /([\d+.]+)_(?:diordna|enohpi)_/.exec(ua);
                if (a) {
                    a = a[1].split(".");
                    back = a.reverse().join(".");
                } else if ((a = /baiduboxapp\/([\d+.]+)/.exec(ua))) {
                    back = a[1];
                }

                return {
                    version: back,
                };
            }
            return false;
        },
    ],
    ["oppobrowser", /\boppobrowser\/([0-9.]+)/],
    ["edge-android",/ (?:edga)\/([0-9.]+)/],
    ["chrome", / (?:chrome|crios|crmo)\/([0-9.]+)/],
    // Android safari 
    ["android", function (ua) {
        if (ua.indexOf("android") === -1) { return; }
        return /\bversion\/([0-9.]+(?: beta)?)/;
    }],
    ["blackberry", function (ua) {
        const m = ua.match(re_blackberry_10) ||
            ua.match(re_blackberry_6_7) ||
            ua.match(re_blackberry_4_5);
        return m ? { version: m[1] } : "blackberry";
    }],
    ["safari", /\bversion\/([0-9.]+(?: beta)?)(?: mobile(?:\/[a-z0-9]+)?)? safari\//],
    //  Safari, WebView
    ["webview", /\bcpu(?: iphone)? os (?:[0-9._]+).+\bapplewebkit\b/],
    ["firefox", /\bfirefox\/([0-9.ab]+)/],
    ["nokia", /\bnokiabrowser\/([0-9.]+)/]
];

module.exports = {
    device: DEVICES,
    os: OS,
    browser: BROWSER,
    engine: ENGINE,
    re_msie: re_msie,
};
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(44)))

/***/ }),
/* 103 */
/***/ (function(module, exports, __webpack_require__) {

/* WEBPACK VAR INJECTION */(function(Buffer, module) {(function (w) {
  "use strict";

  function findBest(atobNative) {
    // normal window
    if ('function' === typeof atobNative) { return atobNative; }


    // browserify (web worker)
    if ('function' === typeof Buffer) {
      return function atobBrowserify(a) {
        //!! Deliberately using an API that's deprecated in node.js because
        //!! this file is for browsers and we expect them to cope with it.
        //!! Discussion: github.com/node-browser-compat/atob/pull/9
        return new Buffer(a, 'base64').toString('binary');
      };
    }

    // ios web worker with base64js
    if ('object' === typeof w.base64js) {
      // bufferToBinaryString
      // https://git.coolaj86.com/coolaj86/unibabel.js/blob/master/index.js#L50
      return function atobWebWorker_iOS(a) {
        var buf = w.base64js.b64ToByteArray(a);
        return Array.prototype.map.call(buf, function (ch) {
          return String.fromCharCode(ch);
        }).join('');
      };
    }

		return function () {
			// ios web worker without base64js
			throw new Error("You're probably in an old browser or an iOS webworker." +
				" It might help to include beatgammit's base64-js.");
    };
  }

  var atobBest = findBest(w.atob);
  w.atob = atobBest;

  if (( true) && module && module.exports) {
    module.exports = atobBest;
  }
}(window));

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(84).Buffer, __webpack_require__(324)(module)))

/***/ }),
/* 104 */
/***/ (function(module, exports, __webpack_require__) {

/* WEBPACK VAR INJECTION */(function(Buffer) {(function () {
  "use strict";

  function btoa(str) {
    var buffer;

    if (str instanceof Buffer) {
      buffer = str;
    } else {
      buffer = Buffer.from(str.toString(), 'binary');
    }

    return buffer.toString('base64');
  }

  module.exports = btoa;
}());

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(84).Buffer))

/***/ }),
/* 105 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global, Buffer) {/* harmony import */ var _DocxTpl__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(70);
/* harmony import */ var _assets_content_types_xml__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(106);
/* harmony import */ var _assets_rels_xml__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(107);
/* harmony import */ var _assets_document_xml_rels__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(108);
/* harmony import */ var _HTML5_Dom__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1);
/* harmony import */ var _HTML5_Svg__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(16);









var JSZip = window.JSZip;


function JSDocx(props) {
    if (props.blob)
        this.blob = props.blob;

    if (props.blob)
        this.buffer = props.buffer;
}

JSDocx.prototype.saveAs = function (fileName) {
    var src;
    if (this.blob) {
        src = (URL || webkitURL).createObjectURL(this.blob);
    }
    else if (this.buffer) {
        src = "data:application/octet-stream," + encodeURIComponent(this.buffer);
    }

    var element = document.createElement('a');
    element.setAttribute('href', src);
    element.setAttribute('download', fileName);

    element.style.display = 'none';
    document.body.appendChild(element);
    element.click();
    document.body.removeChild(element);
};


JSDocx._prepareImageParts = function (htmlSource) {
    var imageContentParts = [];
    var inlinedSrcPattern = /\"data:(\w+\/\w+);(\w+),(\S+)\"/g;
    var inlinedReplacer = function (match, contentType, contentEncoding, encodedContent) {
        var index = imageContentParts.length;
        var extension = contentType.split('/')[1];
        var contentLocation = "file:///C:/fake/image" + index + "." + extension;
        // mht_part: new Function('contentType', 'contentEncoding', 'contentLocation', 'encodedContent', 'return ' + TemplateString.parse(mht_pathTpl).toJSCode())
        imageContentParts.push(_DocxTpl__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].mht_part(contentType, contentEncoding, contentLocation, encodedContent));
        return "\"" + contentLocation + "\"";
    };
    if (typeof htmlSource === 'string') {
        if (!/<img/g.test(htmlSource)) {
            return {
                htmlSource: htmlSource,
                imageContentParts: imageContentParts
            };
        }
        htmlSource = htmlSource.replace(inlinedSrcPattern, inlinedReplacer);
        return {
            htmlSource: htmlSource,
            imageContentParts: imageContentParts
        };
    }
    else {
        throw new Error("Not a valid source provided!");
    }
};


JSDocx._getMHTdocument = function (htmlSource) {
    var imageContentParts, _ref;
    _ref = this._prepareImageParts(htmlSource), htmlSource = _ref.htmlSource, imageContentParts = _ref.imageContentParts;
    htmlSource = htmlSource.replace(/\=/g, '=3D');
    return _DocxTpl__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].mht_document(htmlSource,
        imageContentParts.join('\n')
    );
};

/**
 * @param {JSZip} zip
 */
JSDocx._generateDocument = function (zip) {
    return zip.generateAsync({ type: 'arraybuffer' }).then(function (buffer) {
        var props = {};
        if (global.Blob)
            props.blob = new Blob([buffer], { type: 'application/vnd.openxmlformats-officedocument.wordprocessingml.document' });
        else if (global.Buffer)
            props.buffer = new Buffer(new Uint8Array(buffer));
        else
            throw new Error("Neither Blob nor Buffer are accessible in this environment. " +
                "Consider adding Blob.js shim");
        return new JSDocx(props);
    });
};


JSDocx._renderDocumentFile = function (pageSetting) {

    return _DocxTpl__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].document(pageSetting);
};

JSDocx._createPageSetting = function (documentOptions) {
    documentOptions = documentOptions || {};
    var pageSetting = {
        margins: {
            top: 1440,
            right: 1440,
            bottom: 1440,
            left: 1440,
            header: 720,
            footer: 720,
            gutter: 0
        }
    };
    if (documentOptions.orientation == 'landscape') {
        Object.assign(pageSetting, {
            height: 12240, width: 15840, orient: 'landscape'
        });
    }
    else {
        Object.assign(pageSetting, {
            width: 12240, height: 15840, orient: 'portrait'
        });
    }
    if (documentOptions.margins) {
        Object.assign(pageSetting, documentOptions.margins);
    }
    return pageSetting;
};


JSDocx._addFiles = function (zip, htmlSource, pageSetting) {
    zip.file('[Content_Types].xml', _assets_content_types_xml__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"]);
    zip.folder('_rels')
        .file('.rels', _assets_rels_xml__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"]);
    zip.folder('word')
        .file('document.xml', _DocxTpl__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].document(pageSetting));


    zip.folder('word')
        .file('document.xml', JSDocx._renderDocumentFile(pageSetting))
        .file('afchunk.mht', JSDocx._getMHTdocument(htmlSource))
        .folder('_rels')
        .file('document.xml.rels', _assets_document_xml_rels__WEBPACK_IMPORTED_MODULE_3__[/* default */ "a"]);

    return zip;
};

JSDocx.fromHTMLCode = function (html, options) {
    var zip = new JSZip();
    JSDocx._addFiles(zip, html, JSDocx._createPageSetting(options));
    return JSDocx._generateDocument(zip);
};

JSDocx.fromHTMLElement = function (element, options, getOuter, isWorkingElement) {
    if (typeof element == 'string') {
        element = _HTML5_Dom__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].ShareInstance.$(element);
    }
    if (!element) throw new Error('@param element must be HTMLElement');

    var preRender;
    if (!isWorkingElement) {
        preRender = _HTML5_Dom__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].ShareInstance._('div');
        preRender.addStyle({
            position: 'fixed',
            top: '0',
            left: '0',
            zIndex: '-10000',
            opacity: '0'
        }).addTo(document.body);
        Array.prototype.forEach.call(element.childNodes, function (e) {
            if (e.tagName != 'script')
                preRender.addChild(e.cloneNode(true));
        });
    }
    else {
        preRender = element;
    }

    _HTML5_Dom__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].ShareInstance.$('script', preRender, function (e) {
        e.parentElement.removeChild(e);
        return false;
    });

    var imageTask = [];
    _HTML5_Dom__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].ShareInstance.$('img', preRender, function (e) {
        if (e.src && !e.src.match(/data:/)) {
            var task = _HTML5_Dom__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].imageToCanvas(e).then(function (canvas) {
                var newSrc = canvas.toDataURL();
                e.src = newSrc;
            });
            imageTask.push(task);

        }
        return false;
    });

    _HTML5_Dom__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].ShareInstance.$('svg', preRender, function (e) {
        var task = _HTML5_Svg__WEBPACK_IMPORTED_MODULE_5__[/* default */ "a"].svgToCanvas(e).then(function (canvas) {
            var newSrc = canvas.toDataURL();
            var image = _HTML5_Dom__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].ShareInstance._('img');
            image.src = newSrc;
            _HTML5_Dom__WEBPACK_IMPORTED_MODULE_4__[/* default */ "b"].ShareInstance.$(e).selfReplace(image);

        });
        imageTask.push(task);

        return false;
    });


    return Promise.all(imageTask).then(function () {
        var code;
        if (getOuter) {
            code = preRender.outerHTML;
            if (!code) {
                var temp = document.createElement('div');
                temp.addChild(preRender);
                code = temp.innerHTML;
            }
        }
        else {
            code = preRender.innerHTML;
        }
        return JSDocx.fromHTMLCode(code, options);
    });
};

/* harmony default export */ __webpack_exports__["a"] = (JSDocx);
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(44), __webpack_require__(84).Buffer))

/***/ }),
/* 106 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony default export */ __webpack_exports__["a"] = ("<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?>\n<Types xmlns=\"http://schemas.openxmlformats.org/package/2006/content-types\">\n  <Default Extension=\"rels\" ContentType=\n    \"application/vnd.openxmlformats-package.relationships+xml\" />\n  <Override PartName=\"/word/document.xml\" ContentType=\n    \"application/vnd.openxmlformats-officedocument.wordprocessingml.document.main+xml\"/>\n  <Override PartName=\"/word/afchunk.mht\" ContentType=\"message/rfc822\"/>\n</Types>\n");

/***/ }),
/* 107 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony default export */ __webpack_exports__["a"] = ("<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?>\n<Relationships xmlns=\"http://schemas.openxmlformats.org/package/2006/relationships\">\n  <Relationship\n      Type=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument\"\n      Target=\"/word/document.xml\" Id=\"R09c83fafc067488e\" />\n</Relationships>\n");

/***/ }),
/* 108 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony default export */ __webpack_exports__["a"] = ("<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?>\n<Relationships xmlns=\"http://schemas.openxmlformats.org/package/2006/relationships\">\n  <Relationship Type=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships/aFChunk\"\n    Target=\"/word/afchunk.mht\" Id=\"htmlChunk\" />\n</Relationships>\n");

/***/ }),
/* 109 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global) {/* harmony import */ var _FlagManager__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(63);
/* harmony import */ var _noop__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(13);





_FlagManager__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].add('ABSOL_DEBUG', false);

function ALogger() {
    _FlagManager__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"].on('change', this._updateProto.bind(this));
    this._updateProto();
}

ALogger.prototype._updateProto = function () {
    ['log', 'table', 'table', 'error', 'warn'].forEach(function (name) {
        var cFunction = window['ABSOL_DEBUG'] ? (console[name] && console[name].bind(console)) : _noop__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"];
        this[name] = cFunction || _noop__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"];
    }.bind(this));
};


ALogger.prototype.log = _noop__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"];
ALogger.prototype.table = _noop__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"];
ALogger.prototype.error = _noop__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"];
ALogger.prototype.warn = _noop__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"];

(window || global).ALogger = new ALogger();


/* harmony default export */ __webpack_exports__["a"] = (ALogger);
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(44)))

/***/ }),
/* 110 */
/***/ (function(module, exports, __webpack_require__) {

var __WEBPACK_AMD_DEFINE_RESULT__;;/*! showdown v 1.9.1 - 02-11-2019 */
(function(){
/**
 * Created by Tivie on 13-07-2015.
 */

function getDefaultOpts (simple) {
  'use strict';

  var defaultOptions = {
    omitExtraWLInCodeBlocks: {
      defaultValue: false,
      describe: 'Omit the default extra whiteline added to code blocks',
      type: 'boolean'
    },
    noHeaderId: {
      defaultValue: false,
      describe: 'Turn on/off generated header id',
      type: 'boolean'
    },
    prefixHeaderId: {
      defaultValue: false,
      describe: 'Add a prefix to the generated header ids. Passing a string will prefix that string to the header id. Setting to true will add a generic \'section-\' prefix',
      type: 'string'
    },
    rawPrefixHeaderId: {
      defaultValue: false,
      describe: 'Setting this option to true will prevent showdown from modifying the prefix. This might result in malformed IDs (if, for instance, the " char is used in the prefix)',
      type: 'boolean'
    },
    ghCompatibleHeaderId: {
      defaultValue: false,
      describe: 'Generate header ids compatible with github style (spaces are replaced with dashes, a bunch of non alphanumeric chars are removed)',
      type: 'boolean'
    },
    rawHeaderId: {
      defaultValue: false,
      describe: 'Remove only spaces, \' and " from generated header ids (including prefixes), replacing them with dashes (-). WARNING: This might result in malformed ids',
      type: 'boolean'
    },
    headerLevelStart: {
      defaultValue: false,
      describe: 'The header blocks level start',
      type: 'integer'
    },
    parseImgDimensions: {
      defaultValue: false,
      describe: 'Turn on/off image dimension parsing',
      type: 'boolean'
    },
    simplifiedAutoLink: {
      defaultValue: false,
      describe: 'Turn on/off GFM autolink style',
      type: 'boolean'
    },
    excludeTrailingPunctuationFromURLs: {
      defaultValue: false,
      describe: 'Excludes trailing punctuation from links generated with autoLinking',
      type: 'boolean'
    },
    literalMidWordUnderscores: {
      defaultValue: false,
      describe: 'Parse midword underscores as literal underscores',
      type: 'boolean'
    },
    literalMidWordAsterisks: {
      defaultValue: false,
      describe: 'Parse midword asterisks as literal asterisks',
      type: 'boolean'
    },
    strikethrough: {
      defaultValue: false,
      describe: 'Turn on/off strikethrough support',
      type: 'boolean'
    },
    tables: {
      defaultValue: false,
      describe: 'Turn on/off tables support',
      type: 'boolean'
    },
    tablesHeaderId: {
      defaultValue: false,
      describe: 'Add an id to table headers',
      type: 'boolean'
    },
    ghCodeBlocks: {
      defaultValue: true,
      describe: 'Turn on/off GFM fenced code blocks support',
      type: 'boolean'
    },
    tasklists: {
      defaultValue: false,
      describe: 'Turn on/off GFM tasklist support',
      type: 'boolean'
    },
    smoothLivePreview: {
      defaultValue: false,
      describe: 'Prevents weird effects in live previews due to incomplete input',
      type: 'boolean'
    },
    smartIndentationFix: {
      defaultValue: false,
      description: 'Tries to smartly fix indentation in es6 strings',
      type: 'boolean'
    },
    disableForced4SpacesIndentedSublists: {
      defaultValue: false,
      description: 'Disables the requirement of indenting nested sublists by 4 spaces',
      type: 'boolean'
    },
    simpleLineBreaks: {
      defaultValue: false,
      description: 'Parses simple line breaks as <br> (GFM Style)',
      type: 'boolean'
    },
    requireSpaceBeforeHeadingText: {
      defaultValue: false,
      description: 'Makes adding a space between `#` and the header text mandatory (GFM Style)',
      type: 'boolean'
    },
    ghMentions: {
      defaultValue: false,
      description: 'Enables github @mentions',
      type: 'boolean'
    },
    ghMentionsLink: {
      defaultValue: 'https://github.com/{u}',
      description: 'Changes the link generated by @mentions. Only applies if ghMentions option is enabled.',
      type: 'string'
    },
    encodeEmails: {
      defaultValue: true,
      description: 'Encode e-mail addresses through the use of Character Entities, transforming ASCII e-mail addresses into its equivalent decimal entities',
      type: 'boolean'
    },
    openLinksInNewWindow: {
      defaultValue: false,
      description: 'Open all links in new windows',
      type: 'boolean'
    },
    backslashEscapesHTMLTags: {
      defaultValue: false,
      description: 'Support for HTML Tag escaping. ex: \<div>foo\</div>',
      type: 'boolean'
    },
    emoji: {
      defaultValue: false,
      description: 'Enable emoji support. Ex: `this is a :smile: emoji`',
      type: 'boolean'
    },
    underline: {
      defaultValue: false,
      description: 'Enable support for underline. Syntax is double or triple underscores: `__underline word__`. With this option enabled, underscores no longer parses into `<em>` and `<strong>`',
      type: 'boolean'
    },
    completeHTMLDocument: {
      defaultValue: false,
      description: 'Outputs a complete html document, including `<html>`, `<head>` and `<body>` tags',
      type: 'boolean'
    },
    metadata: {
      defaultValue: false,
      description: 'Enable support for document metadata (defined at the top of the document between `«««` and `»»»` or between `---` and `---`).',
      type: 'boolean'
    },
    splitAdjacentBlockquotes: {
      defaultValue: false,
      description: 'Split adjacent blockquote blocks',
      type: 'boolean'
    }
  };
  if (simple === false) {
    return JSON.parse(JSON.stringify(defaultOptions));
  }
  var ret = {};
  for (var opt in defaultOptions) {
    if (defaultOptions.hasOwnProperty(opt)) {
      ret[opt] = defaultOptions[opt].defaultValue;
    }
  }
  return ret;
}

function allOptionsOn () {
  'use strict';
  var options = getDefaultOpts(true),
      ret = {};
  for (var opt in options) {
    if (options.hasOwnProperty(opt)) {
      ret[opt] = true;
    }
  }
  return ret;
}

/**
 * Created by Tivie on 06-01-2015.
 */

// Private properties
var showdown = {},
    parsers = {},
    extensions = {},
    globalOptions = getDefaultOpts(true),
    setFlavor = 'vanilla',
    flavor = {
      github: {
        omitExtraWLInCodeBlocks:              true,
        simplifiedAutoLink:                   true,
        excludeTrailingPunctuationFromURLs:   true,
        literalMidWordUnderscores:            true,
        strikethrough:                        true,
        tables:                               true,
        tablesHeaderId:                       true,
        ghCodeBlocks:                         true,
        tasklists:                            true,
        disableForced4SpacesIndentedSublists: true,
        simpleLineBreaks:                     true,
        requireSpaceBeforeHeadingText:        true,
        ghCompatibleHeaderId:                 true,
        ghMentions:                           true,
        backslashEscapesHTMLTags:             true,
        emoji:                                true,
        splitAdjacentBlockquotes:             true
      },
      original: {
        noHeaderId:                           true,
        ghCodeBlocks:                         false
      },
      ghost: {
        omitExtraWLInCodeBlocks:              true,
        parseImgDimensions:                   true,
        simplifiedAutoLink:                   true,
        excludeTrailingPunctuationFromURLs:   true,
        literalMidWordUnderscores:            true,
        strikethrough:                        true,
        tables:                               true,
        tablesHeaderId:                       true,
        ghCodeBlocks:                         true,
        tasklists:                            true,
        smoothLivePreview:                    true,
        simpleLineBreaks:                     true,
        requireSpaceBeforeHeadingText:        true,
        ghMentions:                           false,
        encodeEmails:                         true
      },
      vanilla: getDefaultOpts(true),
      allOn: allOptionsOn()
    };

/**
 * helper namespace
 * @type {{}}
 */
showdown.helper = {};

/**
 * TODO LEGACY SUPPORT CODE
 * @type {{}}
 */
showdown.extensions = {};

/**
 * Set a global option
 * @static
 * @param {string} key
 * @param {*} value
 * @returns {showdown}
 */
showdown.setOption = function (key, value) {
  'use strict';
  globalOptions[key] = value;
  return this;
};

/**
 * Get a global option
 * @static
 * @param {string} key
 * @returns {*}
 */
showdown.getOption = function (key) {
  'use strict';
  return globalOptions[key];
};

/**
 * Get the global options
 * @static
 * @returns {{}}
 */
showdown.getOptions = function () {
  'use strict';
  return globalOptions;
};

/**
 * Reset global options to the default values
 * @static
 */
showdown.resetOptions = function () {
  'use strict';
  globalOptions = getDefaultOpts(true);
};

/**
 * Set the flavor showdown should use as default
 * @param {string} name
 */
showdown.setFlavor = function (name) {
  'use strict';
  if (!flavor.hasOwnProperty(name)) {
    throw Error(name + ' flavor was not found');
  }
  showdown.resetOptions();
  var preset = flavor[name];
  setFlavor = name;
  for (var option in preset) {
    if (preset.hasOwnProperty(option)) {
      globalOptions[option] = preset[option];
    }
  }
};

/**
 * Get the currently set flavor
 * @returns {string}
 */
showdown.getFlavor = function () {
  'use strict';
  return setFlavor;
};

/**
 * Get the options of a specified flavor. Returns undefined if the flavor was not found
 * @param {string} name Name of the flavor
 * @returns {{}|undefined}
 */
showdown.getFlavorOptions = function (name) {
  'use strict';
  if (flavor.hasOwnProperty(name)) {
    return flavor[name];
  }
};

/**
 * Get the default options
 * @static
 * @param {boolean} [simple=true]
 * @returns {{}}
 */
showdown.getDefaultOptions = function (simple) {
  'use strict';
  return getDefaultOpts(simple);
};

/**
 * Get or set a subParser
 *
 * subParser(name)       - Get a registered subParser
 * subParser(name, func) - Register a subParser
 * @static
 * @param {string} name
 * @param {function} [func]
 * @returns {*}
 */
showdown.subParser = function (name, func) {
  'use strict';
  if (showdown.helper.isString(name)) {
    if (typeof func !== 'undefined') {
      parsers[name] = func;
    } else {
      if (parsers.hasOwnProperty(name)) {
        return parsers[name];
      } else {
        throw Error('SubParser named ' + name + ' not registered!');
      }
    }
  }
};

/**
 * Gets or registers an extension
 * @static
 * @param {string} name
 * @param {object|function=} ext
 * @returns {*}
 */
showdown.extension = function (name, ext) {
  'use strict';

  if (!showdown.helper.isString(name)) {
    throw Error('Extension \'name\' must be a string');
  }

  name = showdown.helper.stdExtName(name);

  // Getter
  if (showdown.helper.isUndefined(ext)) {
    if (!extensions.hasOwnProperty(name)) {
      throw Error('Extension named ' + name + ' is not registered!');
    }
    return extensions[name];

    // Setter
  } else {
    // Expand extension if it's wrapped in a function
    if (typeof ext === 'function') {
      ext = ext();
    }

    // Ensure extension is an array
    if (!showdown.helper.isArray(ext)) {
      ext = [ext];
    }

    var validExtension = validate(ext, name);

    if (validExtension.valid) {
      extensions[name] = ext;
    } else {
      throw Error(validExtension.error);
    }
  }
};

/**
 * Gets all extensions registered
 * @returns {{}}
 */
showdown.getAllExtensions = function () {
  'use strict';
  return extensions;
};

/**
 * Remove an extension
 * @param {string} name
 */
showdown.removeExtension = function (name) {
  'use strict';
  delete extensions[name];
};

/**
 * Removes all extensions
 */
showdown.resetExtensions = function () {
  'use strict';
  extensions = {};
};

/**
 * Validate extension
 * @param {array} extension
 * @param {string} name
 * @returns {{valid: boolean, error: string}}
 */
function validate (extension, name) {
  'use strict';

  var errMsg = (name) ? 'Error in ' + name + ' extension->' : 'Error in unnamed extension',
      ret = {
        valid: true,
        error: ''
      };

  if (!showdown.helper.isArray(extension)) {
    extension = [extension];
  }

  for (var i = 0; i < extension.length; ++i) {
    var baseMsg = errMsg + ' sub-extension ' + i + ': ',
        ext = extension[i];
    if (typeof ext !== 'object') {
      ret.valid = false;
      ret.error = baseMsg + 'must be an object, but ' + typeof ext + ' given';
      return ret;
    }

    if (!showdown.helper.isString(ext.type)) {
      ret.valid = false;
      ret.error = baseMsg + 'property "type" must be a string, but ' + typeof ext.type + ' given';
      return ret;
    }

    var type = ext.type = ext.type.toLowerCase();

    // normalize extension type
    if (type === 'language') {
      type = ext.type = 'lang';
    }

    if (type === 'html') {
      type = ext.type = 'output';
    }

    if (type !== 'lang' && type !== 'output' && type !== 'listener') {
      ret.valid = false;
      ret.error = baseMsg + 'type ' + type + ' is not recognized. Valid values: "lang/language", "output/html" or "listener"';
      return ret;
    }

    if (type === 'listener') {
      if (showdown.helper.isUndefined(ext.listeners)) {
        ret.valid = false;
        ret.error = baseMsg + '. Extensions of type "listener" must have a property called "listeners"';
        return ret;
      }
    } else {
      if (showdown.helper.isUndefined(ext.filter) && showdown.helper.isUndefined(ext.regex)) {
        ret.valid = false;
        ret.error = baseMsg + type + ' extensions must define either a "regex" property or a "filter" method';
        return ret;
      }
    }

    if (ext.listeners) {
      if (typeof ext.listeners !== 'object') {
        ret.valid = false;
        ret.error = baseMsg + '"listeners" property must be an object but ' + typeof ext.listeners + ' given';
        return ret;
      }
      for (var ln in ext.listeners) {
        if (ext.listeners.hasOwnProperty(ln)) {
          if (typeof ext.listeners[ln] !== 'function') {
            ret.valid = false;
            ret.error = baseMsg + '"listeners" property must be an hash of [event name]: [callback]. listeners.' + ln +
              ' must be a function but ' + typeof ext.listeners[ln] + ' given';
            return ret;
          }
        }
      }
    }

    if (ext.filter) {
      if (typeof ext.filter !== 'function') {
        ret.valid = false;
        ret.error = baseMsg + '"filter" must be a function, but ' + typeof ext.filter + ' given';
        return ret;
      }
    } else if (ext.regex) {
      if (showdown.helper.isString(ext.regex)) {
        ext.regex = new RegExp(ext.regex, 'g');
      }
      if (!(ext.regex instanceof RegExp)) {
        ret.valid = false;
        ret.error = baseMsg + '"regex" property must either be a string or a RegExp object, but ' + typeof ext.regex + ' given';
        return ret;
      }
      if (showdown.helper.isUndefined(ext.replace)) {
        ret.valid = false;
        ret.error = baseMsg + '"regex" extensions must implement a replace string or function';
        return ret;
      }
    }
  }
  return ret;
}

/**
 * Validate extension
 * @param {object} ext
 * @returns {boolean}
 */
showdown.validateExtension = function (ext) {
  'use strict';

  var validateExtension = validate(ext, null);
  if (!validateExtension.valid) {
    console.warn(validateExtension.error);
    return false;
  }
  return true;
};

/**
 * showdownjs helper functions
 */

if (!showdown.hasOwnProperty('helper')) {
  showdown.helper = {};
}

/**
 * Check if var is string
 * @static
 * @param {string} a
 * @returns {boolean}
 */
showdown.helper.isString = function (a) {
  'use strict';
  return (typeof a === 'string' || a instanceof String);
};

/**
 * Check if var is a function
 * @static
 * @param {*} a
 * @returns {boolean}
 */
showdown.helper.isFunction = function (a) {
  'use strict';
  var getType = {};
  return a && getType.toString.call(a) === '[object Function]';
};

/**
 * isArray helper function
 * @static
 * @param {*} a
 * @returns {boolean}
 */
showdown.helper.isArray = function (a) {
  'use strict';
  return Array.isArray(a);
};

/**
 * Check if value is undefined
 * @static
 * @param {*} value The value to check.
 * @returns {boolean} Returns `true` if `value` is `undefined`, else `false`.
 */
showdown.helper.isUndefined = function (value) {
  'use strict';
  return typeof value === 'undefined';
};

/**
 * ForEach helper function
 * Iterates over Arrays and Objects (own properties only)
 * @static
 * @param {*} obj
 * @param {function} callback Accepts 3 params: 1. value, 2. key, 3. the original array/object
 */
showdown.helper.forEach = function (obj, callback) {
  'use strict';
  // check if obj is defined
  if (showdown.helper.isUndefined(obj)) {
    throw new Error('obj param is required');
  }

  if (showdown.helper.isUndefined(callback)) {
    throw new Error('callback param is required');
  }

  if (!showdown.helper.isFunction(callback)) {
    throw new Error('callback param must be a function/closure');
  }

  if (typeof obj.forEach === 'function') {
    obj.forEach(callback);
  } else if (showdown.helper.isArray(obj)) {
    for (var i = 0; i < obj.length; i++) {
      callback(obj[i], i, obj);
    }
  } else if (typeof (obj) === 'object') {
    for (var prop in obj) {
      if (obj.hasOwnProperty(prop)) {
        callback(obj[prop], prop, obj);
      }
    }
  } else {
    throw new Error('obj does not seem to be an array or an iterable object');
  }
};

/**
 * Standardidize extension name
 * @static
 * @param {string} s extension name
 * @returns {string}
 */
showdown.helper.stdExtName = function (s) {
  'use strict';
  return s.replace(/[_?*+\/\\.^-]/g, '').replace(/\s/g, '').toLowerCase();
};

function escapeCharactersCallback (wholeMatch, m1) {
  'use strict';
  var charCodeToEscape = m1.charCodeAt(0);
  return '¨E' + charCodeToEscape + 'E';
}

/**
 * Callback used to escape characters when passing through String.replace
 * @static
 * @param {string} wholeMatch
 * @param {string} m1
 * @returns {string}
 */
showdown.helper.escapeCharactersCallback = escapeCharactersCallback;

/**
 * Escape characters in a string
 * @static
 * @param {string} text
 * @param {string} charsToEscape
 * @param {boolean} afterBackslash
 * @returns {XML|string|void|*}
 */
showdown.helper.escapeCharacters = function (text, charsToEscape, afterBackslash) {
  'use strict';
  // First we have to escape the escape characters so that
  // we can build a character class out of them
  var regexString = '([' + charsToEscape.replace(/([\[\]\\])/g, '\\$1') + '])';

  if (afterBackslash) {
    regexString = '\\\\' + regexString;
  }

  var regex = new RegExp(regexString, 'g');
  text = text.replace(regex, escapeCharactersCallback);

  return text;
};

/**
 * Unescape HTML entities
 * @param txt
 * @returns {string}
 */
showdown.helper.unescapeHTMLEntities = function (txt) {
  'use strict';

  return txt
    .replace(/&quot;/g, '"')
    .replace(/&lt;/g, '<')
    .replace(/&gt;/g, '>')
    .replace(/&amp;/g, '&');
};

var rgxFindMatchPos = function (str, left, right, flags) {
  'use strict';
  var f = flags || '',
      g = f.indexOf('g') > -1,
      x = new RegExp(left + '|' + right, 'g' + f.replace(/g/g, '')),
      l = new RegExp(left, f.replace(/g/g, '')),
      pos = [],
      t, s, m, start, end;

  do {
    t = 0;
    while ((m = x.exec(str))) {
      if (l.test(m[0])) {
        if (!(t++)) {
          s = x.lastIndex;
          start = s - m[0].length;
        }
      } else if (t) {
        if (!--t) {
          end = m.index + m[0].length;
          var obj = {
            left: {start: start, end: s},
            match: {start: s, end: m.index},
            right: {start: m.index, end: end},
            wholeMatch: {start: start, end: end}
          };
          pos.push(obj);
          if (!g) {
            return pos;
          }
        }
      }
    }
  } while (t && (x.lastIndex = s));

  return pos;
};

/**
 * matchRecursiveRegExp
 *
 * (c) 2007 Steven Levithan <stevenlevithan.com>
 * MIT License
 *
 * Accepts a string to search, a left and right format delimiter
 * as regex patterns, and optional regex flags. Returns an array
 * of matches, allowing nested instances of left/right delimiters.
 * Use the "g" flag to return all matches, otherwise only the
 * first is returned. Be careful to ensure that the left and
 * right format delimiters produce mutually exclusive matches.
 * Backreferences are not supported within the right delimiter
 * due to how it is internally combined with the left delimiter.
 * When matching strings whose format delimiters are unbalanced
 * to the left or right, the output is intentionally as a
 * conventional regex library with recursion support would
 * produce, e.g. "<<x>" and "<x>>" both produce ["x"] when using
 * "<" and ">" as the delimiters (both strings contain a single,
 * balanced instance of "<x>").
 *
 * examples:
 * matchRecursiveRegExp("test", "\\(", "\\)")
 * returns: []
 * matchRecursiveRegExp("<t<<e>><s>>t<>", "<", ">", "g")
 * returns: ["t<<e>><s>", ""]
 * matchRecursiveRegExp("<div id=\"x\">test</div>", "<div\\b[^>]*>", "</div>", "gi")
 * returns: ["test"]
 */
showdown.helper.matchRecursiveRegExp = function (str, left, right, flags) {
  'use strict';

  var matchPos = rgxFindMatchPos (str, left, right, flags),
      results = [];

  for (var i = 0; i < matchPos.length; ++i) {
    results.push([
      str.slice(matchPos[i].wholeMatch.start, matchPos[i].wholeMatch.end),
      str.slice(matchPos[i].match.start, matchPos[i].match.end),
      str.slice(matchPos[i].left.start, matchPos[i].left.end),
      str.slice(matchPos[i].right.start, matchPos[i].right.end)
    ]);
  }
  return results;
};

/**
 *
 * @param {string} str
 * @param {string|function} replacement
 * @param {string} left
 * @param {string} right
 * @param {string} flags
 * @returns {string}
 */
showdown.helper.replaceRecursiveRegExp = function (str, replacement, left, right, flags) {
  'use strict';

  if (!showdown.helper.isFunction(replacement)) {
    var repStr = replacement;
    replacement = function () {
      return repStr;
    };
  }

  var matchPos = rgxFindMatchPos(str, left, right, flags),
      finalStr = str,
      lng = matchPos.length;

  if (lng > 0) {
    var bits = [];
    if (matchPos[0].wholeMatch.start !== 0) {
      bits.push(str.slice(0, matchPos[0].wholeMatch.start));
    }
    for (var i = 0; i < lng; ++i) {
      bits.push(
        replacement(
          str.slice(matchPos[i].wholeMatch.start, matchPos[i].wholeMatch.end),
          str.slice(matchPos[i].match.start, matchPos[i].match.end),
          str.slice(matchPos[i].left.start, matchPos[i].left.end),
          str.slice(matchPos[i].right.start, matchPos[i].right.end)
        )
      );
      if (i < lng - 1) {
        bits.push(str.slice(matchPos[i].wholeMatch.end, matchPos[i + 1].wholeMatch.start));
      }
    }
    if (matchPos[lng - 1].wholeMatch.end < str.length) {
      bits.push(str.slice(matchPos[lng - 1].wholeMatch.end));
    }
    finalStr = bits.join('');
  }
  return finalStr;
};

/**
 * Returns the index within the passed String object of the first occurrence of the specified regex,
 * starting the search at fromIndex. Returns -1 if the value is not found.
 *
 * @param {string} str string to search
 * @param {RegExp} regex Regular expression to search
 * @param {int} [fromIndex = 0] Index to start the search
 * @returns {Number}
 * @throws InvalidArgumentError
 */
showdown.helper.regexIndexOf = function (str, regex, fromIndex) {
  'use strict';
  if (!showdown.helper.isString(str)) {
    throw 'InvalidArgumentError: first parameter of showdown.helper.regexIndexOf function must be a string';
  }
  if (regex instanceof RegExp === false) {
    throw 'InvalidArgumentError: second parameter of showdown.helper.regexIndexOf function must be an instance of RegExp';
  }
  var indexOf = str.substring(fromIndex || 0).search(regex);
  return (indexOf >= 0) ? (indexOf + (fromIndex || 0)) : indexOf;
};

/**
 * Splits the passed string object at the defined index, and returns an array composed of the two substrings
 * @param {string} str string to split
 * @param {int} index index to split string at
 * @returns {[string,string]}
 * @throws InvalidArgumentError
 */
showdown.helper.splitAtIndex = function (str, index) {
  'use strict';
  if (!showdown.helper.isString(str)) {
    throw 'InvalidArgumentError: first parameter of showdown.helper.regexIndexOf function must be a string';
  }
  return [str.substring(0, index), str.substring(index)];
};

/**
 * Obfuscate an e-mail address through the use of Character Entities,
 * transforming ASCII characters into their equivalent decimal or hex entities.
 *
 * Since it has a random component, subsequent calls to this function produce different results
 *
 * @param {string} mail
 * @returns {string}
 */
showdown.helper.encodeEmailAddress = function (mail) {
  'use strict';
  var encode = [
    function (ch) {
      return '&#' + ch.charCodeAt(0) + ';';
    },
    function (ch) {
      return '&#x' + ch.charCodeAt(0).toString(16) + ';';
    },
    function (ch) {
      return ch;
    }
  ];

  mail = mail.replace(/./g, function (ch) {
    if (ch === '@') {
      // this *must* be encoded. I insist.
      ch = encode[Math.floor(Math.random() * 2)](ch);
    } else {
      var r = Math.random();
      // roughly 10% raw, 45% hex, 45% dec
      ch = (
        r > 0.9 ? encode[2](ch) : r > 0.45 ? encode[1](ch) : encode[0](ch)
      );
    }
    return ch;
  });

  return mail;
};

/**
 *
 * @param str
 * @param targetLength
 * @param padString
 * @returns {string}
 */
showdown.helper.padEnd = function padEnd (str, targetLength, padString) {
  'use strict';
  /*jshint bitwise: false*/
  // eslint-disable-next-line space-infix-ops
  targetLength = targetLength>>0; //floor if number or convert non-number to 0;
  /*jshint bitwise: true*/
  padString = String(padString || ' ');
  if (str.length > targetLength) {
    return String(str);
  } else {
    targetLength = targetLength - str.length;
    if (targetLength > padString.length) {
      padString += padString.repeat(targetLength / padString.length); //append to original to ensure we are longer than needed
    }
    return String(str) + padString.slice(0,targetLength);
  }
};

/**
 * POLYFILLS
 */
// use this instead of builtin is undefined for IE8 compatibility
if (typeof console === 'undefined') {
  console = {
    warn: function (msg) {
      'use strict';
      alert(msg);
    },
    log: function (msg) {
      'use strict';
      alert(msg);
    },
    error: function (msg) {
      'use strict';
      throw msg;
    }
  };
}

/**
 * Common regexes.
 * We declare some common regexes to improve performance
 */
showdown.helper.regexes = {
  asteriskDashAndColon: /([*_:~])/g
};

/**
 * EMOJIS LIST
 */
showdown.helper.emojis = {
  '+1':'\ud83d\udc4d',
  '-1':'\ud83d\udc4e',
  '100':'\ud83d\udcaf',
  '1234':'\ud83d\udd22',
  '1st_place_medal':'\ud83e\udd47',
  '2nd_place_medal':'\ud83e\udd48',
  '3rd_place_medal':'\ud83e\udd49',
  '8ball':'\ud83c\udfb1',
  'a':'\ud83c\udd70\ufe0f',
  'ab':'\ud83c\udd8e',
  'abc':'\ud83d\udd24',
  'abcd':'\ud83d\udd21',
  'accept':'\ud83c\ude51',
  'aerial_tramway':'\ud83d\udea1',
  'airplane':'\u2708\ufe0f',
  'alarm_clock':'\u23f0',
  'alembic':'\u2697\ufe0f',
  'alien':'\ud83d\udc7d',
  'ambulance':'\ud83d\ude91',
  'amphora':'\ud83c\udffa',
  'anchor':'\u2693\ufe0f',
  'angel':'\ud83d\udc7c',
  'anger':'\ud83d\udca2',
  'angry':'\ud83d\ude20',
  'anguished':'\ud83d\ude27',
  'ant':'\ud83d\udc1c',
  'apple':'\ud83c\udf4e',
  'aquarius':'\u2652\ufe0f',
  'aries':'\u2648\ufe0f',
  'arrow_backward':'\u25c0\ufe0f',
  'arrow_double_down':'\u23ec',
  'arrow_double_up':'\u23eb',
  'arrow_down':'\u2b07\ufe0f',
  'arrow_down_small':'\ud83d\udd3d',
  'arrow_forward':'\u25b6\ufe0f',
  'arrow_heading_down':'\u2935\ufe0f',
  'arrow_heading_up':'\u2934\ufe0f',
  'arrow_left':'\u2b05\ufe0f',
  'arrow_lower_left':'\u2199\ufe0f',
  'arrow_lower_right':'\u2198\ufe0f',
  'arrow_right':'\u27a1\ufe0f',
  'arrow_right_hook':'\u21aa\ufe0f',
  'arrow_up':'\u2b06\ufe0f',
  'arrow_up_down':'\u2195\ufe0f',
  'arrow_up_small':'\ud83d\udd3c',
  'arrow_upper_left':'\u2196\ufe0f',
  'arrow_upper_right':'\u2197\ufe0f',
  'arrows_clockwise':'\ud83d\udd03',
  'arrows_counterclockwise':'\ud83d\udd04',
  'art':'\ud83c\udfa8',
  'articulated_lorry':'\ud83d\ude9b',
  'artificial_satellite':'\ud83d\udef0',
  'astonished':'\ud83d\ude32',
  'athletic_shoe':'\ud83d\udc5f',
  'atm':'\ud83c\udfe7',
  'atom_symbol':'\u269b\ufe0f',
  'avocado':'\ud83e\udd51',
  'b':'\ud83c\udd71\ufe0f',
  'baby':'\ud83d\udc76',
  'baby_bottle':'\ud83c\udf7c',
  'baby_chick':'\ud83d\udc24',
  'baby_symbol':'\ud83d\udebc',
  'back':'\ud83d\udd19',
  'bacon':'\ud83e\udd53',
  'badminton':'\ud83c\udff8',
  'baggage_claim':'\ud83d\udec4',
  'baguette_bread':'\ud83e\udd56',
  'balance_scale':'\u2696\ufe0f',
  'balloon':'\ud83c\udf88',
  'ballot_box':'\ud83d\uddf3',
  'ballot_box_with_check':'\u2611\ufe0f',
  'bamboo':'\ud83c\udf8d',
  'banana':'\ud83c\udf4c',
  'bangbang':'\u203c\ufe0f',
  'bank':'\ud83c\udfe6',
  'bar_chart':'\ud83d\udcca',
  'barber':'\ud83d\udc88',
  'baseball':'\u26be\ufe0f',
  'basketball':'\ud83c\udfc0',
  'basketball_man':'\u26f9\ufe0f',
  'basketball_woman':'\u26f9\ufe0f&zwj;\u2640\ufe0f',
  'bat':'\ud83e\udd87',
  'bath':'\ud83d\udec0',
  'bathtub':'\ud83d\udec1',
  'battery':'\ud83d\udd0b',
  'beach_umbrella':'\ud83c\udfd6',
  'bear':'\ud83d\udc3b',
  'bed':'\ud83d\udecf',
  'bee':'\ud83d\udc1d',
  'beer':'\ud83c\udf7a',
  'beers':'\ud83c\udf7b',
  'beetle':'\ud83d\udc1e',
  'beginner':'\ud83d\udd30',
  'bell':'\ud83d\udd14',
  'bellhop_bell':'\ud83d\udece',
  'bento':'\ud83c\udf71',
  'biking_man':'\ud83d\udeb4',
  'bike':'\ud83d\udeb2',
  'biking_woman':'\ud83d\udeb4&zwj;\u2640\ufe0f',
  'bikini':'\ud83d\udc59',
  'biohazard':'\u2623\ufe0f',
  'bird':'\ud83d\udc26',
  'birthday':'\ud83c\udf82',
  'black_circle':'\u26ab\ufe0f',
  'black_flag':'\ud83c\udff4',
  'black_heart':'\ud83d\udda4',
  'black_joker':'\ud83c\udccf',
  'black_large_square':'\u2b1b\ufe0f',
  'black_medium_small_square':'\u25fe\ufe0f',
  'black_medium_square':'\u25fc\ufe0f',
  'black_nib':'\u2712\ufe0f',
  'black_small_square':'\u25aa\ufe0f',
  'black_square_button':'\ud83d\udd32',
  'blonde_man':'\ud83d\udc71',
  'blonde_woman':'\ud83d\udc71&zwj;\u2640\ufe0f',
  'blossom':'\ud83c\udf3c',
  'blowfish':'\ud83d\udc21',
  'blue_book':'\ud83d\udcd8',
  'blue_car':'\ud83d\ude99',
  'blue_heart':'\ud83d\udc99',
  'blush':'\ud83d\ude0a',
  'boar':'\ud83d\udc17',
  'boat':'\u26f5\ufe0f',
  'bomb':'\ud83d\udca3',
  'book':'\ud83d\udcd6',
  'bookmark':'\ud83d\udd16',
  'bookmark_tabs':'\ud83d\udcd1',
  'books':'\ud83d\udcda',
  'boom':'\ud83d\udca5',
  'boot':'\ud83d\udc62',
  'bouquet':'\ud83d\udc90',
  'bowing_man':'\ud83d\ude47',
  'bow_and_arrow':'\ud83c\udff9',
  'bowing_woman':'\ud83d\ude47&zwj;\u2640\ufe0f',
  'bowling':'\ud83c\udfb3',
  'boxing_glove':'\ud83e\udd4a',
  'boy':'\ud83d\udc66',
  'bread':'\ud83c\udf5e',
  'bride_with_veil':'\ud83d\udc70',
  'bridge_at_night':'\ud83c\udf09',
  'briefcase':'\ud83d\udcbc',
  'broken_heart':'\ud83d\udc94',
  'bug':'\ud83d\udc1b',
  'building_construction':'\ud83c\udfd7',
  'bulb':'\ud83d\udca1',
  'bullettrain_front':'\ud83d\ude85',
  'bullettrain_side':'\ud83d\ude84',
  'burrito':'\ud83c\udf2f',
  'bus':'\ud83d\ude8c',
  'business_suit_levitating':'\ud83d\udd74',
  'busstop':'\ud83d\ude8f',
  'bust_in_silhouette':'\ud83d\udc64',
  'busts_in_silhouette':'\ud83d\udc65',
  'butterfly':'\ud83e\udd8b',
  'cactus':'\ud83c\udf35',
  'cake':'\ud83c\udf70',
  'calendar':'\ud83d\udcc6',
  'call_me_hand':'\ud83e\udd19',
  'calling':'\ud83d\udcf2',
  'camel':'\ud83d\udc2b',
  'camera':'\ud83d\udcf7',
  'camera_flash':'\ud83d\udcf8',
  'camping':'\ud83c\udfd5',
  'cancer':'\u264b\ufe0f',
  'candle':'\ud83d\udd6f',
  'candy':'\ud83c\udf6c',
  'canoe':'\ud83d\udef6',
  'capital_abcd':'\ud83d\udd20',
  'capricorn':'\u2651\ufe0f',
  'car':'\ud83d\ude97',
  'card_file_box':'\ud83d\uddc3',
  'card_index':'\ud83d\udcc7',
  'card_index_dividers':'\ud83d\uddc2',
  'carousel_horse':'\ud83c\udfa0',
  'carrot':'\ud83e\udd55',
  'cat':'\ud83d\udc31',
  'cat2':'\ud83d\udc08',
  'cd':'\ud83d\udcbf',
  'chains':'\u26d3',
  'champagne':'\ud83c\udf7e',
  'chart':'\ud83d\udcb9',
  'chart_with_downwards_trend':'\ud83d\udcc9',
  'chart_with_upwards_trend':'\ud83d\udcc8',
  'checkered_flag':'\ud83c\udfc1',
  'cheese':'\ud83e\uddc0',
  'cherries':'\ud83c\udf52',
  'cherry_blossom':'\ud83c\udf38',
  'chestnut':'\ud83c\udf30',
  'chicken':'\ud83d\udc14',
  'children_crossing':'\ud83d\udeb8',
  'chipmunk':'\ud83d\udc3f',
  'chocolate_bar':'\ud83c\udf6b',
  'christmas_tree':'\ud83c\udf84',
  'church':'\u26ea\ufe0f',
  'cinema':'\ud83c\udfa6',
  'circus_tent':'\ud83c\udfaa',
  'city_sunrise':'\ud83c\udf07',
  'city_sunset':'\ud83c\udf06',
  'cityscape':'\ud83c\udfd9',
  'cl':'\ud83c\udd91',
  'clamp':'\ud83d\udddc',
  'clap':'\ud83d\udc4f',
  'clapper':'\ud83c\udfac',
  'classical_building':'\ud83c\udfdb',
  'clinking_glasses':'\ud83e\udd42',
  'clipboard':'\ud83d\udccb',
  'clock1':'\ud83d\udd50',
  'clock10':'\ud83d\udd59',
  'clock1030':'\ud83d\udd65',
  'clock11':'\ud83d\udd5a',
  'clock1130':'\ud83d\udd66',
  'clock12':'\ud83d\udd5b',
  'clock1230':'\ud83d\udd67',
  'clock130':'\ud83d\udd5c',
  'clock2':'\ud83d\udd51',
  'clock230':'\ud83d\udd5d',
  'clock3':'\ud83d\udd52',
  'clock330':'\ud83d\udd5e',
  'clock4':'\ud83d\udd53',
  'clock430':'\ud83d\udd5f',
  'clock5':'\ud83d\udd54',
  'clock530':'\ud83d\udd60',
  'clock6':'\ud83d\udd55',
  'clock630':'\ud83d\udd61',
  'clock7':'\ud83d\udd56',
  'clock730':'\ud83d\udd62',
  'clock8':'\ud83d\udd57',
  'clock830':'\ud83d\udd63',
  'clock9':'\ud83d\udd58',
  'clock930':'\ud83d\udd64',
  'closed_book':'\ud83d\udcd5',
  'closed_lock_with_key':'\ud83d\udd10',
  'closed_umbrella':'\ud83c\udf02',
  'cloud':'\u2601\ufe0f',
  'cloud_with_lightning':'\ud83c\udf29',
  'cloud_with_lightning_and_rain':'\u26c8',
  'cloud_with_rain':'\ud83c\udf27',
  'cloud_with_snow':'\ud83c\udf28',
  'clown_face':'\ud83e\udd21',
  'clubs':'\u2663\ufe0f',
  'cocktail':'\ud83c\udf78',
  'coffee':'\u2615\ufe0f',
  'coffin':'\u26b0\ufe0f',
  'cold_sweat':'\ud83d\ude30',
  'comet':'\u2604\ufe0f',
  'computer':'\ud83d\udcbb',
  'computer_mouse':'\ud83d\uddb1',
  'confetti_ball':'\ud83c\udf8a',
  'confounded':'\ud83d\ude16',
  'confused':'\ud83d\ude15',
  'congratulations':'\u3297\ufe0f',
  'construction':'\ud83d\udea7',
  'construction_worker_man':'\ud83d\udc77',
  'construction_worker_woman':'\ud83d\udc77&zwj;\u2640\ufe0f',
  'control_knobs':'\ud83c\udf9b',
  'convenience_store':'\ud83c\udfea',
  'cookie':'\ud83c\udf6a',
  'cool':'\ud83c\udd92',
  'policeman':'\ud83d\udc6e',
  'copyright':'\u00a9\ufe0f',
  'corn':'\ud83c\udf3d',
  'couch_and_lamp':'\ud83d\udecb',
  'couple':'\ud83d\udc6b',
  'couple_with_heart_woman_man':'\ud83d\udc91',
  'couple_with_heart_man_man':'\ud83d\udc68&zwj;\u2764\ufe0f&zwj;\ud83d\udc68',
  'couple_with_heart_woman_woman':'\ud83d\udc69&zwj;\u2764\ufe0f&zwj;\ud83d\udc69',
  'couplekiss_man_man':'\ud83d\udc68&zwj;\u2764\ufe0f&zwj;\ud83d\udc8b&zwj;\ud83d\udc68',
  'couplekiss_man_woman':'\ud83d\udc8f',
  'couplekiss_woman_woman':'\ud83d\udc69&zwj;\u2764\ufe0f&zwj;\ud83d\udc8b&zwj;\ud83d\udc69',
  'cow':'\ud83d\udc2e',
  'cow2':'\ud83d\udc04',
  'cowboy_hat_face':'\ud83e\udd20',
  'crab':'\ud83e\udd80',
  'crayon':'\ud83d\udd8d',
  'credit_card':'\ud83d\udcb3',
  'crescent_moon':'\ud83c\udf19',
  'cricket':'\ud83c\udfcf',
  'crocodile':'\ud83d\udc0a',
  'croissant':'\ud83e\udd50',
  'crossed_fingers':'\ud83e\udd1e',
  'crossed_flags':'\ud83c\udf8c',
  'crossed_swords':'\u2694\ufe0f',
  'crown':'\ud83d\udc51',
  'cry':'\ud83d\ude22',
  'crying_cat_face':'\ud83d\ude3f',
  'crystal_ball':'\ud83d\udd2e',
  'cucumber':'\ud83e\udd52',
  'cupid':'\ud83d\udc98',
  'curly_loop':'\u27b0',
  'currency_exchange':'\ud83d\udcb1',
  'curry':'\ud83c\udf5b',
  'custard':'\ud83c\udf6e',
  'customs':'\ud83d\udec3',
  'cyclone':'\ud83c\udf00',
  'dagger':'\ud83d\udde1',
  'dancer':'\ud83d\udc83',
  'dancing_women':'\ud83d\udc6f',
  'dancing_men':'\ud83d\udc6f&zwj;\u2642\ufe0f',
  'dango':'\ud83c\udf61',
  'dark_sunglasses':'\ud83d\udd76',
  'dart':'\ud83c\udfaf',
  'dash':'\ud83d\udca8',
  'date':'\ud83d\udcc5',
  'deciduous_tree':'\ud83c\udf33',
  'deer':'\ud83e\udd8c',
  'department_store':'\ud83c\udfec',
  'derelict_house':'\ud83c\udfda',
  'desert':'\ud83c\udfdc',
  'desert_island':'\ud83c\udfdd',
  'desktop_computer':'\ud83d\udda5',
  'male_detective':'\ud83d\udd75\ufe0f',
  'diamond_shape_with_a_dot_inside':'\ud83d\udca0',
  'diamonds':'\u2666\ufe0f',
  'disappointed':'\ud83d\ude1e',
  'disappointed_relieved':'\ud83d\ude25',
  'dizzy':'\ud83d\udcab',
  'dizzy_face':'\ud83d\ude35',
  'do_not_litter':'\ud83d\udeaf',
  'dog':'\ud83d\udc36',
  'dog2':'\ud83d\udc15',
  'dollar':'\ud83d\udcb5',
  'dolls':'\ud83c\udf8e',
  'dolphin':'\ud83d\udc2c',
  'door':'\ud83d\udeaa',
  'doughnut':'\ud83c\udf69',
  'dove':'\ud83d\udd4a',
  'dragon':'\ud83d\udc09',
  'dragon_face':'\ud83d\udc32',
  'dress':'\ud83d\udc57',
  'dromedary_camel':'\ud83d\udc2a',
  'drooling_face':'\ud83e\udd24',
  'droplet':'\ud83d\udca7',
  'drum':'\ud83e\udd41',
  'duck':'\ud83e\udd86',
  'dvd':'\ud83d\udcc0',
  'e-mail':'\ud83d\udce7',
  'eagle':'\ud83e\udd85',
  'ear':'\ud83d\udc42',
  'ear_of_rice':'\ud83c\udf3e',
  'earth_africa':'\ud83c\udf0d',
  'earth_americas':'\ud83c\udf0e',
  'earth_asia':'\ud83c\udf0f',
  'egg':'\ud83e\udd5a',
  'eggplant':'\ud83c\udf46',
  'eight_pointed_black_star':'\u2734\ufe0f',
  'eight_spoked_asterisk':'\u2733\ufe0f',
  'electric_plug':'\ud83d\udd0c',
  'elephant':'\ud83d\udc18',
  'email':'\u2709\ufe0f',
  'end':'\ud83d\udd1a',
  'envelope_with_arrow':'\ud83d\udce9',
  'euro':'\ud83d\udcb6',
  'european_castle':'\ud83c\udff0',
  'european_post_office':'\ud83c\udfe4',
  'evergreen_tree':'\ud83c\udf32',
  'exclamation':'\u2757\ufe0f',
  'expressionless':'\ud83d\ude11',
  'eye':'\ud83d\udc41',
  'eye_speech_bubble':'\ud83d\udc41&zwj;\ud83d\udde8',
  'eyeglasses':'\ud83d\udc53',
  'eyes':'\ud83d\udc40',
  'face_with_head_bandage':'\ud83e\udd15',
  'face_with_thermometer':'\ud83e\udd12',
  'fist_oncoming':'\ud83d\udc4a',
  'factory':'\ud83c\udfed',
  'fallen_leaf':'\ud83c\udf42',
  'family_man_woman_boy':'\ud83d\udc6a',
  'family_man_boy':'\ud83d\udc68&zwj;\ud83d\udc66',
  'family_man_boy_boy':'\ud83d\udc68&zwj;\ud83d\udc66&zwj;\ud83d\udc66',
  'family_man_girl':'\ud83d\udc68&zwj;\ud83d\udc67',
  'family_man_girl_boy':'\ud83d\udc68&zwj;\ud83d\udc67&zwj;\ud83d\udc66',
  'family_man_girl_girl':'\ud83d\udc68&zwj;\ud83d\udc67&zwj;\ud83d\udc67',
  'family_man_man_boy':'\ud83d\udc68&zwj;\ud83d\udc68&zwj;\ud83d\udc66',
  'family_man_man_boy_boy':'\ud83d\udc68&zwj;\ud83d\udc68&zwj;\ud83d\udc66&zwj;\ud83d\udc66',
  'family_man_man_girl':'\ud83d\udc68&zwj;\ud83d\udc68&zwj;\ud83d\udc67',
  'family_man_man_girl_boy':'\ud83d\udc68&zwj;\ud83d\udc68&zwj;\ud83d\udc67&zwj;\ud83d\udc66',
  'family_man_man_girl_girl':'\ud83d\udc68&zwj;\ud83d\udc68&zwj;\ud83d\udc67&zwj;\ud83d\udc67',
  'family_man_woman_boy_boy':'\ud83d\udc68&zwj;\ud83d\udc69&zwj;\ud83d\udc66&zwj;\ud83d\udc66',
  'family_man_woman_girl':'\ud83d\udc68&zwj;\ud83d\udc69&zwj;\ud83d\udc67',
  'family_man_woman_girl_boy':'\ud83d\udc68&zwj;\ud83d\udc69&zwj;\ud83d\udc67&zwj;\ud83d\udc66',
  'family_man_woman_girl_girl':'\ud83d\udc68&zwj;\ud83d\udc69&zwj;\ud83d\udc67&zwj;\ud83d\udc67',
  'family_woman_boy':'\ud83d\udc69&zwj;\ud83d\udc66',
  'family_woman_boy_boy':'\ud83d\udc69&zwj;\ud83d\udc66&zwj;\ud83d\udc66',
  'family_woman_girl':'\ud83d\udc69&zwj;\ud83d\udc67',
  'family_woman_girl_boy':'\ud83d\udc69&zwj;\ud83d\udc67&zwj;\ud83d\udc66',
  'family_woman_girl_girl':'\ud83d\udc69&zwj;\ud83d\udc67&zwj;\ud83d\udc67',
  'family_woman_woman_boy':'\ud83d\udc69&zwj;\ud83d\udc69&zwj;\ud83d\udc66',
  'family_woman_woman_boy_boy':'\ud83d\udc69&zwj;\ud83d\udc69&zwj;\ud83d\udc66&zwj;\ud83d\udc66',
  'family_woman_woman_girl':'\ud83d\udc69&zwj;\ud83d\udc69&zwj;\ud83d\udc67',
  'family_woman_woman_girl_boy':'\ud83d\udc69&zwj;\ud83d\udc69&zwj;\ud83d\udc67&zwj;\ud83d\udc66',
  'family_woman_woman_girl_girl':'\ud83d\udc69&zwj;\ud83d\udc69&zwj;\ud83d\udc67&zwj;\ud83d\udc67',
  'fast_forward':'\u23e9',
  'fax':'\ud83d\udce0',
  'fearful':'\ud83d\ude28',
  'feet':'\ud83d\udc3e',
  'female_detective':'\ud83d\udd75\ufe0f&zwj;\u2640\ufe0f',
  'ferris_wheel':'\ud83c\udfa1',
  'ferry':'\u26f4',
  'field_hockey':'\ud83c\udfd1',
  'file_cabinet':'\ud83d\uddc4',
  'file_folder':'\ud83d\udcc1',
  'film_projector':'\ud83d\udcfd',
  'film_strip':'\ud83c\udf9e',
  'fire':'\ud83d\udd25',
  'fire_engine':'\ud83d\ude92',
  'fireworks':'\ud83c\udf86',
  'first_quarter_moon':'\ud83c\udf13',
  'first_quarter_moon_with_face':'\ud83c\udf1b',
  'fish':'\ud83d\udc1f',
  'fish_cake':'\ud83c\udf65',
  'fishing_pole_and_fish':'\ud83c\udfa3',
  'fist_raised':'\u270a',
  'fist_left':'\ud83e\udd1b',
  'fist_right':'\ud83e\udd1c',
  'flags':'\ud83c\udf8f',
  'flashlight':'\ud83d\udd26',
  'fleur_de_lis':'\u269c\ufe0f',
  'flight_arrival':'\ud83d\udeec',
  'flight_departure':'\ud83d\udeeb',
  'floppy_disk':'\ud83d\udcbe',
  'flower_playing_cards':'\ud83c\udfb4',
  'flushed':'\ud83d\ude33',
  'fog':'\ud83c\udf2b',
  'foggy':'\ud83c\udf01',
  'football':'\ud83c\udfc8',
  'footprints':'\ud83d\udc63',
  'fork_and_knife':'\ud83c\udf74',
  'fountain':'\u26f2\ufe0f',
  'fountain_pen':'\ud83d\udd8b',
  'four_leaf_clover':'\ud83c\udf40',
  'fox_face':'\ud83e\udd8a',
  'framed_picture':'\ud83d\uddbc',
  'free':'\ud83c\udd93',
  'fried_egg':'\ud83c\udf73',
  'fried_shrimp':'\ud83c\udf64',
  'fries':'\ud83c\udf5f',
  'frog':'\ud83d\udc38',
  'frowning':'\ud83d\ude26',
  'frowning_face':'\u2639\ufe0f',
  'frowning_man':'\ud83d\ude4d&zwj;\u2642\ufe0f',
  'frowning_woman':'\ud83d\ude4d',
  'middle_finger':'\ud83d\udd95',
  'fuelpump':'\u26fd\ufe0f',
  'full_moon':'\ud83c\udf15',
  'full_moon_with_face':'\ud83c\udf1d',
  'funeral_urn':'\u26b1\ufe0f',
  'game_die':'\ud83c\udfb2',
  'gear':'\u2699\ufe0f',
  'gem':'\ud83d\udc8e',
  'gemini':'\u264a\ufe0f',
  'ghost':'\ud83d\udc7b',
  'gift':'\ud83c\udf81',
  'gift_heart':'\ud83d\udc9d',
  'girl':'\ud83d\udc67',
  'globe_with_meridians':'\ud83c\udf10',
  'goal_net':'\ud83e\udd45',
  'goat':'\ud83d\udc10',
  'golf':'\u26f3\ufe0f',
  'golfing_man':'\ud83c\udfcc\ufe0f',
  'golfing_woman':'\ud83c\udfcc\ufe0f&zwj;\u2640\ufe0f',
  'gorilla':'\ud83e\udd8d',
  'grapes':'\ud83c\udf47',
  'green_apple':'\ud83c\udf4f',
  'green_book':'\ud83d\udcd7',
  'green_heart':'\ud83d\udc9a',
  'green_salad':'\ud83e\udd57',
  'grey_exclamation':'\u2755',
  'grey_question':'\u2754',
  'grimacing':'\ud83d\ude2c',
  'grin':'\ud83d\ude01',
  'grinning':'\ud83d\ude00',
  'guardsman':'\ud83d\udc82',
  'guardswoman':'\ud83d\udc82&zwj;\u2640\ufe0f',
  'guitar':'\ud83c\udfb8',
  'gun':'\ud83d\udd2b',
  'haircut_woman':'\ud83d\udc87',
  'haircut_man':'\ud83d\udc87&zwj;\u2642\ufe0f',
  'hamburger':'\ud83c\udf54',
  'hammer':'\ud83d\udd28',
  'hammer_and_pick':'\u2692',
  'hammer_and_wrench':'\ud83d\udee0',
  'hamster':'\ud83d\udc39',
  'hand':'\u270b',
  'handbag':'\ud83d\udc5c',
  'handshake':'\ud83e\udd1d',
  'hankey':'\ud83d\udca9',
  'hatched_chick':'\ud83d\udc25',
  'hatching_chick':'\ud83d\udc23',
  'headphones':'\ud83c\udfa7',
  'hear_no_evil':'\ud83d\ude49',
  'heart':'\u2764\ufe0f',
  'heart_decoration':'\ud83d\udc9f',
  'heart_eyes':'\ud83d\ude0d',
  'heart_eyes_cat':'\ud83d\ude3b',
  'heartbeat':'\ud83d\udc93',
  'heartpulse':'\ud83d\udc97',
  'hearts':'\u2665\ufe0f',
  'heavy_check_mark':'\u2714\ufe0f',
  'heavy_division_sign':'\u2797',
  'heavy_dollar_sign':'\ud83d\udcb2',
  'heavy_heart_exclamation':'\u2763\ufe0f',
  'heavy_minus_sign':'\u2796',
  'heavy_multiplication_x':'\u2716\ufe0f',
  'heavy_plus_sign':'\u2795',
  'helicopter':'\ud83d\ude81',
  'herb':'\ud83c\udf3f',
  'hibiscus':'\ud83c\udf3a',
  'high_brightness':'\ud83d\udd06',
  'high_heel':'\ud83d\udc60',
  'hocho':'\ud83d\udd2a',
  'hole':'\ud83d\udd73',
  'honey_pot':'\ud83c\udf6f',
  'horse':'\ud83d\udc34',
  'horse_racing':'\ud83c\udfc7',
  'hospital':'\ud83c\udfe5',
  'hot_pepper':'\ud83c\udf36',
  'hotdog':'\ud83c\udf2d',
  'hotel':'\ud83c\udfe8',
  'hotsprings':'\u2668\ufe0f',
  'hourglass':'\u231b\ufe0f',
  'hourglass_flowing_sand':'\u23f3',
  'house':'\ud83c\udfe0',
  'house_with_garden':'\ud83c\udfe1',
  'houses':'\ud83c\udfd8',
  'hugs':'\ud83e\udd17',
  'hushed':'\ud83d\ude2f',
  'ice_cream':'\ud83c\udf68',
  'ice_hockey':'\ud83c\udfd2',
  'ice_skate':'\u26f8',
  'icecream':'\ud83c\udf66',
  'id':'\ud83c\udd94',
  'ideograph_advantage':'\ud83c\ude50',
  'imp':'\ud83d\udc7f',
  'inbox_tray':'\ud83d\udce5',
  'incoming_envelope':'\ud83d\udce8',
  'tipping_hand_woman':'\ud83d\udc81',
  'information_source':'\u2139\ufe0f',
  'innocent':'\ud83d\ude07',
  'interrobang':'\u2049\ufe0f',
  'iphone':'\ud83d\udcf1',
  'izakaya_lantern':'\ud83c\udfee',
  'jack_o_lantern':'\ud83c\udf83',
  'japan':'\ud83d\uddfe',
  'japanese_castle':'\ud83c\udfef',
  'japanese_goblin':'\ud83d\udc7a',
  'japanese_ogre':'\ud83d\udc79',
  'jeans':'\ud83d\udc56',
  'joy':'\ud83d\ude02',
  'joy_cat':'\ud83d\ude39',
  'joystick':'\ud83d\udd79',
  'kaaba':'\ud83d\udd4b',
  'key':'\ud83d\udd11',
  'keyboard':'\u2328\ufe0f',
  'keycap_ten':'\ud83d\udd1f',
  'kick_scooter':'\ud83d\udef4',
  'kimono':'\ud83d\udc58',
  'kiss':'\ud83d\udc8b',
  'kissing':'\ud83d\ude17',
  'kissing_cat':'\ud83d\ude3d',
  'kissing_closed_eyes':'\ud83d\ude1a',
  'kissing_heart':'\ud83d\ude18',
  'kissing_smiling_eyes':'\ud83d\ude19',
  'kiwi_fruit':'\ud83e\udd5d',
  'koala':'\ud83d\udc28',
  'koko':'\ud83c\ude01',
  'label':'\ud83c\udff7',
  'large_blue_circle':'\ud83d\udd35',
  'large_blue_diamond':'\ud83d\udd37',
  'large_orange_diamond':'\ud83d\udd36',
  'last_quarter_moon':'\ud83c\udf17',
  'last_quarter_moon_with_face':'\ud83c\udf1c',
  'latin_cross':'\u271d\ufe0f',
  'laughing':'\ud83d\ude06',
  'leaves':'\ud83c\udf43',
  'ledger':'\ud83d\udcd2',
  'left_luggage':'\ud83d\udec5',
  'left_right_arrow':'\u2194\ufe0f',
  'leftwards_arrow_with_hook':'\u21a9\ufe0f',
  'lemon':'\ud83c\udf4b',
  'leo':'\u264c\ufe0f',
  'leopard':'\ud83d\udc06',
  'level_slider':'\ud83c\udf9a',
  'libra':'\u264e\ufe0f',
  'light_rail':'\ud83d\ude88',
  'link':'\ud83d\udd17',
  'lion':'\ud83e\udd81',
  'lips':'\ud83d\udc44',
  'lipstick':'\ud83d\udc84',
  'lizard':'\ud83e\udd8e',
  'lock':'\ud83d\udd12',
  'lock_with_ink_pen':'\ud83d\udd0f',
  'lollipop':'\ud83c\udf6d',
  'loop':'\u27bf',
  'loud_sound':'\ud83d\udd0a',
  'loudspeaker':'\ud83d\udce2',
  'love_hotel':'\ud83c\udfe9',
  'love_letter':'\ud83d\udc8c',
  'low_brightness':'\ud83d\udd05',
  'lying_face':'\ud83e\udd25',
  'm':'\u24c2\ufe0f',
  'mag':'\ud83d\udd0d',
  'mag_right':'\ud83d\udd0e',
  'mahjong':'\ud83c\udc04\ufe0f',
  'mailbox':'\ud83d\udceb',
  'mailbox_closed':'\ud83d\udcea',
  'mailbox_with_mail':'\ud83d\udcec',
  'mailbox_with_no_mail':'\ud83d\udced',
  'man':'\ud83d\udc68',
  'man_artist':'\ud83d\udc68&zwj;\ud83c\udfa8',
  'man_astronaut':'\ud83d\udc68&zwj;\ud83d\ude80',
  'man_cartwheeling':'\ud83e\udd38&zwj;\u2642\ufe0f',
  'man_cook':'\ud83d\udc68&zwj;\ud83c\udf73',
  'man_dancing':'\ud83d\udd7a',
  'man_facepalming':'\ud83e\udd26&zwj;\u2642\ufe0f',
  'man_factory_worker':'\ud83d\udc68&zwj;\ud83c\udfed',
  'man_farmer':'\ud83d\udc68&zwj;\ud83c\udf3e',
  'man_firefighter':'\ud83d\udc68&zwj;\ud83d\ude92',
  'man_health_worker':'\ud83d\udc68&zwj;\u2695\ufe0f',
  'man_in_tuxedo':'\ud83e\udd35',
  'man_judge':'\ud83d\udc68&zwj;\u2696\ufe0f',
  'man_juggling':'\ud83e\udd39&zwj;\u2642\ufe0f',
  'man_mechanic':'\ud83d\udc68&zwj;\ud83d\udd27',
  'man_office_worker':'\ud83d\udc68&zwj;\ud83d\udcbc',
  'man_pilot':'\ud83d\udc68&zwj;\u2708\ufe0f',
  'man_playing_handball':'\ud83e\udd3e&zwj;\u2642\ufe0f',
  'man_playing_water_polo':'\ud83e\udd3d&zwj;\u2642\ufe0f',
  'man_scientist':'\ud83d\udc68&zwj;\ud83d\udd2c',
  'man_shrugging':'\ud83e\udd37&zwj;\u2642\ufe0f',
  'man_singer':'\ud83d\udc68&zwj;\ud83c\udfa4',
  'man_student':'\ud83d\udc68&zwj;\ud83c\udf93',
  'man_teacher':'\ud83d\udc68&zwj;\ud83c\udfeb',
  'man_technologist':'\ud83d\udc68&zwj;\ud83d\udcbb',
  'man_with_gua_pi_mao':'\ud83d\udc72',
  'man_with_turban':'\ud83d\udc73',
  'tangerine':'\ud83c\udf4a',
  'mans_shoe':'\ud83d\udc5e',
  'mantelpiece_clock':'\ud83d\udd70',
  'maple_leaf':'\ud83c\udf41',
  'martial_arts_uniform':'\ud83e\udd4b',
  'mask':'\ud83d\ude37',
  'massage_woman':'\ud83d\udc86',
  'massage_man':'\ud83d\udc86&zwj;\u2642\ufe0f',
  'meat_on_bone':'\ud83c\udf56',
  'medal_military':'\ud83c\udf96',
  'medal_sports':'\ud83c\udfc5',
  'mega':'\ud83d\udce3',
  'melon':'\ud83c\udf48',
  'memo':'\ud83d\udcdd',
  'men_wrestling':'\ud83e\udd3c&zwj;\u2642\ufe0f',
  'menorah':'\ud83d\udd4e',
  'mens':'\ud83d\udeb9',
  'metal':'\ud83e\udd18',
  'metro':'\ud83d\ude87',
  'microphone':'\ud83c\udfa4',
  'microscope':'\ud83d\udd2c',
  'milk_glass':'\ud83e\udd5b',
  'milky_way':'\ud83c\udf0c',
  'minibus':'\ud83d\ude90',
  'minidisc':'\ud83d\udcbd',
  'mobile_phone_off':'\ud83d\udcf4',
  'money_mouth_face':'\ud83e\udd11',
  'money_with_wings':'\ud83d\udcb8',
  'moneybag':'\ud83d\udcb0',
  'monkey':'\ud83d\udc12',
  'monkey_face':'\ud83d\udc35',
  'monorail':'\ud83d\ude9d',
  'moon':'\ud83c\udf14',
  'mortar_board':'\ud83c\udf93',
  'mosque':'\ud83d\udd4c',
  'motor_boat':'\ud83d\udee5',
  'motor_scooter':'\ud83d\udef5',
  'motorcycle':'\ud83c\udfcd',
  'motorway':'\ud83d\udee3',
  'mount_fuji':'\ud83d\uddfb',
  'mountain':'\u26f0',
  'mountain_biking_man':'\ud83d\udeb5',
  'mountain_biking_woman':'\ud83d\udeb5&zwj;\u2640\ufe0f',
  'mountain_cableway':'\ud83d\udea0',
  'mountain_railway':'\ud83d\ude9e',
  'mountain_snow':'\ud83c\udfd4',
  'mouse':'\ud83d\udc2d',
  'mouse2':'\ud83d\udc01',
  'movie_camera':'\ud83c\udfa5',
  'moyai':'\ud83d\uddff',
  'mrs_claus':'\ud83e\udd36',
  'muscle':'\ud83d\udcaa',
  'mushroom':'\ud83c\udf44',
  'musical_keyboard':'\ud83c\udfb9',
  'musical_note':'\ud83c\udfb5',
  'musical_score':'\ud83c\udfbc',
  'mute':'\ud83d\udd07',
  'nail_care':'\ud83d\udc85',
  'name_badge':'\ud83d\udcdb',
  'national_park':'\ud83c\udfde',
  'nauseated_face':'\ud83e\udd22',
  'necktie':'\ud83d\udc54',
  'negative_squared_cross_mark':'\u274e',
  'nerd_face':'\ud83e\udd13',
  'neutral_face':'\ud83d\ude10',
  'new':'\ud83c\udd95',
  'new_moon':'\ud83c\udf11',
  'new_moon_with_face':'\ud83c\udf1a',
  'newspaper':'\ud83d\udcf0',
  'newspaper_roll':'\ud83d\uddde',
  'next_track_button':'\u23ed',
  'ng':'\ud83c\udd96',
  'no_good_man':'\ud83d\ude45&zwj;\u2642\ufe0f',
  'no_good_woman':'\ud83d\ude45',
  'night_with_stars':'\ud83c\udf03',
  'no_bell':'\ud83d\udd15',
  'no_bicycles':'\ud83d\udeb3',
  'no_entry':'\u26d4\ufe0f',
  'no_entry_sign':'\ud83d\udeab',
  'no_mobile_phones':'\ud83d\udcf5',
  'no_mouth':'\ud83d\ude36',
  'no_pedestrians':'\ud83d\udeb7',
  'no_smoking':'\ud83d\udead',
  'non-potable_water':'\ud83d\udeb1',
  'nose':'\ud83d\udc43',
  'notebook':'\ud83d\udcd3',
  'notebook_with_decorative_cover':'\ud83d\udcd4',
  'notes':'\ud83c\udfb6',
  'nut_and_bolt':'\ud83d\udd29',
  'o':'\u2b55\ufe0f',
  'o2':'\ud83c\udd7e\ufe0f',
  'ocean':'\ud83c\udf0a',
  'octopus':'\ud83d\udc19',
  'oden':'\ud83c\udf62',
  'office':'\ud83c\udfe2',
  'oil_drum':'\ud83d\udee2',
  'ok':'\ud83c\udd97',
  'ok_hand':'\ud83d\udc4c',
  'ok_man':'\ud83d\ude46&zwj;\u2642\ufe0f',
  'ok_woman':'\ud83d\ude46',
  'old_key':'\ud83d\udddd',
  'older_man':'\ud83d\udc74',
  'older_woman':'\ud83d\udc75',
  'om':'\ud83d\udd49',
  'on':'\ud83d\udd1b',
  'oncoming_automobile':'\ud83d\ude98',
  'oncoming_bus':'\ud83d\ude8d',
  'oncoming_police_car':'\ud83d\ude94',
  'oncoming_taxi':'\ud83d\ude96',
  'open_file_folder':'\ud83d\udcc2',
  'open_hands':'\ud83d\udc50',
  'open_mouth':'\ud83d\ude2e',
  'open_umbrella':'\u2602\ufe0f',
  'ophiuchus':'\u26ce',
  'orange_book':'\ud83d\udcd9',
  'orthodox_cross':'\u2626\ufe0f',
  'outbox_tray':'\ud83d\udce4',
  'owl':'\ud83e\udd89',
  'ox':'\ud83d\udc02',
  'package':'\ud83d\udce6',
  'page_facing_up':'\ud83d\udcc4',
  'page_with_curl':'\ud83d\udcc3',
  'pager':'\ud83d\udcdf',
  'paintbrush':'\ud83d\udd8c',
  'palm_tree':'\ud83c\udf34',
  'pancakes':'\ud83e\udd5e',
  'panda_face':'\ud83d\udc3c',
  'paperclip':'\ud83d\udcce',
  'paperclips':'\ud83d\udd87',
  'parasol_on_ground':'\u26f1',
  'parking':'\ud83c\udd7f\ufe0f',
  'part_alternation_mark':'\u303d\ufe0f',
  'partly_sunny':'\u26c5\ufe0f',
  'passenger_ship':'\ud83d\udef3',
  'passport_control':'\ud83d\udec2',
  'pause_button':'\u23f8',
  'peace_symbol':'\u262e\ufe0f',
  'peach':'\ud83c\udf51',
  'peanuts':'\ud83e\udd5c',
  'pear':'\ud83c\udf50',
  'pen':'\ud83d\udd8a',
  'pencil2':'\u270f\ufe0f',
  'penguin':'\ud83d\udc27',
  'pensive':'\ud83d\ude14',
  'performing_arts':'\ud83c\udfad',
  'persevere':'\ud83d\ude23',
  'person_fencing':'\ud83e\udd3a',
  'pouting_woman':'\ud83d\ude4e',
  'phone':'\u260e\ufe0f',
  'pick':'\u26cf',
  'pig':'\ud83d\udc37',
  'pig2':'\ud83d\udc16',
  'pig_nose':'\ud83d\udc3d',
  'pill':'\ud83d\udc8a',
  'pineapple':'\ud83c\udf4d',
  'ping_pong':'\ud83c\udfd3',
  'pisces':'\u2653\ufe0f',
  'pizza':'\ud83c\udf55',
  'place_of_worship':'\ud83d\uded0',
  'plate_with_cutlery':'\ud83c\udf7d',
  'play_or_pause_button':'\u23ef',
  'point_down':'\ud83d\udc47',
  'point_left':'\ud83d\udc48',
  'point_right':'\ud83d\udc49',
  'point_up':'\u261d\ufe0f',
  'point_up_2':'\ud83d\udc46',
  'police_car':'\ud83d\ude93',
  'policewoman':'\ud83d\udc6e&zwj;\u2640\ufe0f',
  'poodle':'\ud83d\udc29',
  'popcorn':'\ud83c\udf7f',
  'post_office':'\ud83c\udfe3',
  'postal_horn':'\ud83d\udcef',
  'postbox':'\ud83d\udcee',
  'potable_water':'\ud83d\udeb0',
  'potato':'\ud83e\udd54',
  'pouch':'\ud83d\udc5d',
  'poultry_leg':'\ud83c\udf57',
  'pound':'\ud83d\udcb7',
  'rage':'\ud83d\ude21',
  'pouting_cat':'\ud83d\ude3e',
  'pouting_man':'\ud83d\ude4e&zwj;\u2642\ufe0f',
  'pray':'\ud83d\ude4f',
  'prayer_beads':'\ud83d\udcff',
  'pregnant_woman':'\ud83e\udd30',
  'previous_track_button':'\u23ee',
  'prince':'\ud83e\udd34',
  'princess':'\ud83d\udc78',
  'printer':'\ud83d\udda8',
  'purple_heart':'\ud83d\udc9c',
  'purse':'\ud83d\udc5b',
  'pushpin':'\ud83d\udccc',
  'put_litter_in_its_place':'\ud83d\udeae',
  'question':'\u2753',
  'rabbit':'\ud83d\udc30',
  'rabbit2':'\ud83d\udc07',
  'racehorse':'\ud83d\udc0e',
  'racing_car':'\ud83c\udfce',
  'radio':'\ud83d\udcfb',
  'radio_button':'\ud83d\udd18',
  'radioactive':'\u2622\ufe0f',
  'railway_car':'\ud83d\ude83',
  'railway_track':'\ud83d\udee4',
  'rainbow':'\ud83c\udf08',
  'rainbow_flag':'\ud83c\udff3\ufe0f&zwj;\ud83c\udf08',
  'raised_back_of_hand':'\ud83e\udd1a',
  'raised_hand_with_fingers_splayed':'\ud83d\udd90',
  'raised_hands':'\ud83d\ude4c',
  'raising_hand_woman':'\ud83d\ude4b',
  'raising_hand_man':'\ud83d\ude4b&zwj;\u2642\ufe0f',
  'ram':'\ud83d\udc0f',
  'ramen':'\ud83c\udf5c',
  'rat':'\ud83d\udc00',
  'record_button':'\u23fa',
  'recycle':'\u267b\ufe0f',
  'red_circle':'\ud83d\udd34',
  'registered':'\u00ae\ufe0f',
  'relaxed':'\u263a\ufe0f',
  'relieved':'\ud83d\ude0c',
  'reminder_ribbon':'\ud83c\udf97',
  'repeat':'\ud83d\udd01',
  'repeat_one':'\ud83d\udd02',
  'rescue_worker_helmet':'\u26d1',
  'restroom':'\ud83d\udebb',
  'revolving_hearts':'\ud83d\udc9e',
  'rewind':'\u23ea',
  'rhinoceros':'\ud83e\udd8f',
  'ribbon':'\ud83c\udf80',
  'rice':'\ud83c\udf5a',
  'rice_ball':'\ud83c\udf59',
  'rice_cracker':'\ud83c\udf58',
  'rice_scene':'\ud83c\udf91',
  'right_anger_bubble':'\ud83d\uddef',
  'ring':'\ud83d\udc8d',
  'robot':'\ud83e\udd16',
  'rocket':'\ud83d\ude80',
  'rofl':'\ud83e\udd23',
  'roll_eyes':'\ud83d\ude44',
  'roller_coaster':'\ud83c\udfa2',
  'rooster':'\ud83d\udc13',
  'rose':'\ud83c\udf39',
  'rosette':'\ud83c\udff5',
  'rotating_light':'\ud83d\udea8',
  'round_pushpin':'\ud83d\udccd',
  'rowing_man':'\ud83d\udea3',
  'rowing_woman':'\ud83d\udea3&zwj;\u2640\ufe0f',
  'rugby_football':'\ud83c\udfc9',
  'running_man':'\ud83c\udfc3',
  'running_shirt_with_sash':'\ud83c\udfbd',
  'running_woman':'\ud83c\udfc3&zwj;\u2640\ufe0f',
  'sa':'\ud83c\ude02\ufe0f',
  'sagittarius':'\u2650\ufe0f',
  'sake':'\ud83c\udf76',
  'sandal':'\ud83d\udc61',
  'santa':'\ud83c\udf85',
  'satellite':'\ud83d\udce1',
  'saxophone':'\ud83c\udfb7',
  'school':'\ud83c\udfeb',
  'school_satchel':'\ud83c\udf92',
  'scissors':'\u2702\ufe0f',
  'scorpion':'\ud83e\udd82',
  'scorpius':'\u264f\ufe0f',
  'scream':'\ud83d\ude31',
  'scream_cat':'\ud83d\ude40',
  'scroll':'\ud83d\udcdc',
  'seat':'\ud83d\udcba',
  'secret':'\u3299\ufe0f',
  'see_no_evil':'\ud83d\ude48',
  'seedling':'\ud83c\udf31',
  'selfie':'\ud83e\udd33',
  'shallow_pan_of_food':'\ud83e\udd58',
  'shamrock':'\u2618\ufe0f',
  'shark':'\ud83e\udd88',
  'shaved_ice':'\ud83c\udf67',
  'sheep':'\ud83d\udc11',
  'shell':'\ud83d\udc1a',
  'shield':'\ud83d\udee1',
  'shinto_shrine':'\u26e9',
  'ship':'\ud83d\udea2',
  'shirt':'\ud83d\udc55',
  'shopping':'\ud83d\udecd',
  'shopping_cart':'\ud83d\uded2',
  'shower':'\ud83d\udebf',
  'shrimp':'\ud83e\udd90',
  'signal_strength':'\ud83d\udcf6',
  'six_pointed_star':'\ud83d\udd2f',
  'ski':'\ud83c\udfbf',
  'skier':'\u26f7',
  'skull':'\ud83d\udc80',
  'skull_and_crossbones':'\u2620\ufe0f',
  'sleeping':'\ud83d\ude34',
  'sleeping_bed':'\ud83d\udecc',
  'sleepy':'\ud83d\ude2a',
  'slightly_frowning_face':'\ud83d\ude41',
  'slightly_smiling_face':'\ud83d\ude42',
  'slot_machine':'\ud83c\udfb0',
  'small_airplane':'\ud83d\udee9',
  'small_blue_diamond':'\ud83d\udd39',
  'small_orange_diamond':'\ud83d\udd38',
  'small_red_triangle':'\ud83d\udd3a',
  'small_red_triangle_down':'\ud83d\udd3b',
  'smile':'\ud83d\ude04',
  'smile_cat':'\ud83d\ude38',
  'smiley':'\ud83d\ude03',
  'smiley_cat':'\ud83d\ude3a',
  'smiling_imp':'\ud83d\ude08',
  'smirk':'\ud83d\ude0f',
  'smirk_cat':'\ud83d\ude3c',
  'smoking':'\ud83d\udeac',
  'snail':'\ud83d\udc0c',
  'snake':'\ud83d\udc0d',
  'sneezing_face':'\ud83e\udd27',
  'snowboarder':'\ud83c\udfc2',
  'snowflake':'\u2744\ufe0f',
  'snowman':'\u26c4\ufe0f',
  'snowman_with_snow':'\u2603\ufe0f',
  'sob':'\ud83d\ude2d',
  'soccer':'\u26bd\ufe0f',
  'soon':'\ud83d\udd1c',
  'sos':'\ud83c\udd98',
  'sound':'\ud83d\udd09',
  'space_invader':'\ud83d\udc7e',
  'spades':'\u2660\ufe0f',
  'spaghetti':'\ud83c\udf5d',
  'sparkle':'\u2747\ufe0f',
  'sparkler':'\ud83c\udf87',
  'sparkles':'\u2728',
  'sparkling_heart':'\ud83d\udc96',
  'speak_no_evil':'\ud83d\ude4a',
  'speaker':'\ud83d\udd08',
  'speaking_head':'\ud83d\udde3',
  'speech_balloon':'\ud83d\udcac',
  'speedboat':'\ud83d\udea4',
  'spider':'\ud83d\udd77',
  'spider_web':'\ud83d\udd78',
  'spiral_calendar':'\ud83d\uddd3',
  'spiral_notepad':'\ud83d\uddd2',
  'spoon':'\ud83e\udd44',
  'squid':'\ud83e\udd91',
  'stadium':'\ud83c\udfdf',
  'star':'\u2b50\ufe0f',
  'star2':'\ud83c\udf1f',
  'star_and_crescent':'\u262a\ufe0f',
  'star_of_david':'\u2721\ufe0f',
  'stars':'\ud83c\udf20',
  'station':'\ud83d\ude89',
  'statue_of_liberty':'\ud83d\uddfd',
  'steam_locomotive':'\ud83d\ude82',
  'stew':'\ud83c\udf72',
  'stop_button':'\u23f9',
  'stop_sign':'\ud83d\uded1',
  'stopwatch':'\u23f1',
  'straight_ruler':'\ud83d\udccf',
  'strawberry':'\ud83c\udf53',
  'stuck_out_tongue':'\ud83d\ude1b',
  'stuck_out_tongue_closed_eyes':'\ud83d\ude1d',
  'stuck_out_tongue_winking_eye':'\ud83d\ude1c',
  'studio_microphone':'\ud83c\udf99',
  'stuffed_flatbread':'\ud83e\udd59',
  'sun_behind_large_cloud':'\ud83c\udf25',
  'sun_behind_rain_cloud':'\ud83c\udf26',
  'sun_behind_small_cloud':'\ud83c\udf24',
  'sun_with_face':'\ud83c\udf1e',
  'sunflower':'\ud83c\udf3b',
  'sunglasses':'\ud83d\ude0e',
  'sunny':'\u2600\ufe0f',
  'sunrise':'\ud83c\udf05',
  'sunrise_over_mountains':'\ud83c\udf04',
  'surfing_man':'\ud83c\udfc4',
  'surfing_woman':'\ud83c\udfc4&zwj;\u2640\ufe0f',
  'sushi':'\ud83c\udf63',
  'suspension_railway':'\ud83d\ude9f',
  'sweat':'\ud83d\ude13',
  'sweat_drops':'\ud83d\udca6',
  'sweat_smile':'\ud83d\ude05',
  'sweet_potato':'\ud83c\udf60',
  'swimming_man':'\ud83c\udfca',
  'swimming_woman':'\ud83c\udfca&zwj;\u2640\ufe0f',
  'symbols':'\ud83d\udd23',
  'synagogue':'\ud83d\udd4d',
  'syringe':'\ud83d\udc89',
  'taco':'\ud83c\udf2e',
  'tada':'\ud83c\udf89',
  'tanabata_tree':'\ud83c\udf8b',
  'taurus':'\u2649\ufe0f',
  'taxi':'\ud83d\ude95',
  'tea':'\ud83c\udf75',
  'telephone_receiver':'\ud83d\udcde',
  'telescope':'\ud83d\udd2d',
  'tennis':'\ud83c\udfbe',
  'tent':'\u26fa\ufe0f',
  'thermometer':'\ud83c\udf21',
  'thinking':'\ud83e\udd14',
  'thought_balloon':'\ud83d\udcad',
  'ticket':'\ud83c\udfab',
  'tickets':'\ud83c\udf9f',
  'tiger':'\ud83d\udc2f',
  'tiger2':'\ud83d\udc05',
  'timer_clock':'\u23f2',
  'tipping_hand_man':'\ud83d\udc81&zwj;\u2642\ufe0f',
  'tired_face':'\ud83d\ude2b',
  'tm':'\u2122\ufe0f',
  'toilet':'\ud83d\udebd',
  'tokyo_tower':'\ud83d\uddfc',
  'tomato':'\ud83c\udf45',
  'tongue':'\ud83d\udc45',
  'top':'\ud83d\udd1d',
  'tophat':'\ud83c\udfa9',
  'tornado':'\ud83c\udf2a',
  'trackball':'\ud83d\uddb2',
  'tractor':'\ud83d\ude9c',
  'traffic_light':'\ud83d\udea5',
  'train':'\ud83d\ude8b',
  'train2':'\ud83d\ude86',
  'tram':'\ud83d\ude8a',
  'triangular_flag_on_post':'\ud83d\udea9',
  'triangular_ruler':'\ud83d\udcd0',
  'trident':'\ud83d\udd31',
  'triumph':'\ud83d\ude24',
  'trolleybus':'\ud83d\ude8e',
  'trophy':'\ud83c\udfc6',
  'tropical_drink':'\ud83c\udf79',
  'tropical_fish':'\ud83d\udc20',
  'truck':'\ud83d\ude9a',
  'trumpet':'\ud83c\udfba',
  'tulip':'\ud83c\udf37',
  'tumbler_glass':'\ud83e\udd43',
  'turkey':'\ud83e\udd83',
  'turtle':'\ud83d\udc22',
  'tv':'\ud83d\udcfa',
  'twisted_rightwards_arrows':'\ud83d\udd00',
  'two_hearts':'\ud83d\udc95',
  'two_men_holding_hands':'\ud83d\udc6c',
  'two_women_holding_hands':'\ud83d\udc6d',
  'u5272':'\ud83c\ude39',
  'u5408':'\ud83c\ude34',
  'u55b6':'\ud83c\ude3a',
  'u6307':'\ud83c\ude2f\ufe0f',
  'u6708':'\ud83c\ude37\ufe0f',
  'u6709':'\ud83c\ude36',
  'u6e80':'\ud83c\ude35',
  'u7121':'\ud83c\ude1a\ufe0f',
  'u7533':'\ud83c\ude38',
  'u7981':'\ud83c\ude32',
  'u7a7a':'\ud83c\ude33',
  'umbrella':'\u2614\ufe0f',
  'unamused':'\ud83d\ude12',
  'underage':'\ud83d\udd1e',
  'unicorn':'\ud83e\udd84',
  'unlock':'\ud83d\udd13',
  'up':'\ud83c\udd99',
  'upside_down_face':'\ud83d\ude43',
  'v':'\u270c\ufe0f',
  'vertical_traffic_light':'\ud83d\udea6',
  'vhs':'\ud83d\udcfc',
  'vibration_mode':'\ud83d\udcf3',
  'video_camera':'\ud83d\udcf9',
  'video_game':'\ud83c\udfae',
  'violin':'\ud83c\udfbb',
  'virgo':'\u264d\ufe0f',
  'volcano':'\ud83c\udf0b',
  'volleyball':'\ud83c\udfd0',
  'vs':'\ud83c\udd9a',
  'vulcan_salute':'\ud83d\udd96',
  'walking_man':'\ud83d\udeb6',
  'walking_woman':'\ud83d\udeb6&zwj;\u2640\ufe0f',
  'waning_crescent_moon':'\ud83c\udf18',
  'waning_gibbous_moon':'\ud83c\udf16',
  'warning':'\u26a0\ufe0f',
  'wastebasket':'\ud83d\uddd1',
  'watch':'\u231a\ufe0f',
  'water_buffalo':'\ud83d\udc03',
  'watermelon':'\ud83c\udf49',
  'wave':'\ud83d\udc4b',
  'wavy_dash':'\u3030\ufe0f',
  'waxing_crescent_moon':'\ud83c\udf12',
  'wc':'\ud83d\udebe',
  'weary':'\ud83d\ude29',
  'wedding':'\ud83d\udc92',
  'weight_lifting_man':'\ud83c\udfcb\ufe0f',
  'weight_lifting_woman':'\ud83c\udfcb\ufe0f&zwj;\u2640\ufe0f',
  'whale':'\ud83d\udc33',
  'whale2':'\ud83d\udc0b',
  'wheel_of_dharma':'\u2638\ufe0f',
  'wheelchair':'\u267f\ufe0f',
  'white_check_mark':'\u2705',
  'white_circle':'\u26aa\ufe0f',
  'white_flag':'\ud83c\udff3\ufe0f',
  'white_flower':'\ud83d\udcae',
  'white_large_square':'\u2b1c\ufe0f',
  'white_medium_small_square':'\u25fd\ufe0f',
  'white_medium_square':'\u25fb\ufe0f',
  'white_small_square':'\u25ab\ufe0f',
  'white_square_button':'\ud83d\udd33',
  'wilted_flower':'\ud83e\udd40',
  'wind_chime':'\ud83c\udf90',
  'wind_face':'\ud83c\udf2c',
  'wine_glass':'\ud83c\udf77',
  'wink':'\ud83d\ude09',
  'wolf':'\ud83d\udc3a',
  'woman':'\ud83d\udc69',
  'woman_artist':'\ud83d\udc69&zwj;\ud83c\udfa8',
  'woman_astronaut':'\ud83d\udc69&zwj;\ud83d\ude80',
  'woman_cartwheeling':'\ud83e\udd38&zwj;\u2640\ufe0f',
  'woman_cook':'\ud83d\udc69&zwj;\ud83c\udf73',
  'woman_facepalming':'\ud83e\udd26&zwj;\u2640\ufe0f',
  'woman_factory_worker':'\ud83d\udc69&zwj;\ud83c\udfed',
  'woman_farmer':'\ud83d\udc69&zwj;\ud83c\udf3e',
  'woman_firefighter':'\ud83d\udc69&zwj;\ud83d\ude92',
  'woman_health_worker':'\ud83d\udc69&zwj;\u2695\ufe0f',
  'woman_judge':'\ud83d\udc69&zwj;\u2696\ufe0f',
  'woman_juggling':'\ud83e\udd39&zwj;\u2640\ufe0f',
  'woman_mechanic':'\ud83d\udc69&zwj;\ud83d\udd27',
  'woman_office_worker':'\ud83d\udc69&zwj;\ud83d\udcbc',
  'woman_pilot':'\ud83d\udc69&zwj;\u2708\ufe0f',
  'woman_playing_handball':'\ud83e\udd3e&zwj;\u2640\ufe0f',
  'woman_playing_water_polo':'\ud83e\udd3d&zwj;\u2640\ufe0f',
  'woman_scientist':'\ud83d\udc69&zwj;\ud83d\udd2c',
  'woman_shrugging':'\ud83e\udd37&zwj;\u2640\ufe0f',
  'woman_singer':'\ud83d\udc69&zwj;\ud83c\udfa4',
  'woman_student':'\ud83d\udc69&zwj;\ud83c\udf93',
  'woman_teacher':'\ud83d\udc69&zwj;\ud83c\udfeb',
  'woman_technologist':'\ud83d\udc69&zwj;\ud83d\udcbb',
  'woman_with_turban':'\ud83d\udc73&zwj;\u2640\ufe0f',
  'womans_clothes':'\ud83d\udc5a',
  'womans_hat':'\ud83d\udc52',
  'women_wrestling':'\ud83e\udd3c&zwj;\u2640\ufe0f',
  'womens':'\ud83d\udeba',
  'world_map':'\ud83d\uddfa',
  'worried':'\ud83d\ude1f',
  'wrench':'\ud83d\udd27',
  'writing_hand':'\u270d\ufe0f',
  'x':'\u274c',
  'yellow_heart':'\ud83d\udc9b',
  'yen':'\ud83d\udcb4',
  'yin_yang':'\u262f\ufe0f',
  'yum':'\ud83d\ude0b',
  'zap':'\u26a1\ufe0f',
  'zipper_mouth_face':'\ud83e\udd10',
  'zzz':'\ud83d\udca4',

  /* special emojis :P */
  'octocat':  '<img alt=":octocat:" height="20" width="20" align="absmiddle" src="https://assets-cdn.github.com/images/icons/emoji/octocat.png">',
  'showdown': '<span style="font-family: \'Anonymous Pro\', monospace; text-decoration: underline; text-decoration-style: dashed; text-decoration-color: #3e8b8a;text-underline-position: under;">S</span>'
};

/**
 * Created by Estevao on 31-05-2015.
 */

/**
 * Showdown Converter class
 * @class
 * @param {object} [converterOptions]
 * @returns {Converter}
 */
showdown.Converter = function (converterOptions) {
  'use strict';

  var
      /**
       * Options used by this converter
       * @private
       * @type {{}}
       */
      options = {},

      /**
       * Language extensions used by this converter
       * @private
       * @type {Array}
       */
      langExtensions = [],

      /**
       * Output modifiers extensions used by this converter
       * @private
       * @type {Array}
       */
      outputModifiers = [],

      /**
       * Event listeners
       * @private
       * @type {{}}
       */
      listeners = {},

      /**
       * The flavor set in this converter
       */
      setConvFlavor = setFlavor,

      /**
       * Metadata of the document
       * @type {{parsed: {}, raw: string, format: string}}
       */
      metadata = {
        parsed: {},
        raw: '',
        format: ''
      };

  _constructor();

  /**
   * Converter constructor
   * @private
   */
  function _constructor () {
    converterOptions = converterOptions || {};

    for (var gOpt in globalOptions) {
      if (globalOptions.hasOwnProperty(gOpt)) {
        options[gOpt] = globalOptions[gOpt];
      }
    }

    // Merge options
    if (typeof converterOptions === 'object') {
      for (var opt in converterOptions) {
        if (converterOptions.hasOwnProperty(opt)) {
          options[opt] = converterOptions[opt];
        }
      }
    } else {
      throw Error('Converter expects the passed parameter to be an object, but ' + typeof converterOptions +
      ' was passed instead.');
    }

    if (options.extensions) {
      showdown.helper.forEach(options.extensions, _parseExtension);
    }
  }

  /**
   * Parse extension
   * @param {*} ext
   * @param {string} [name='']
   * @private
   */
  function _parseExtension (ext, name) {

    name = name || null;
    // If it's a string, the extension was previously loaded
    if (showdown.helper.isString(ext)) {
      ext = showdown.helper.stdExtName(ext);
      name = ext;

      // LEGACY_SUPPORT CODE
      if (showdown.extensions[ext]) {
        console.warn('DEPRECATION WARNING: ' + ext + ' is an old extension that uses a deprecated loading method.' +
          'Please inform the developer that the extension should be updated!');
        legacyExtensionLoading(showdown.extensions[ext], ext);
        return;
        // END LEGACY SUPPORT CODE

      } else if (!showdown.helper.isUndefined(extensions[ext])) {
        ext = extensions[ext];

      } else {
        throw Error('Extension "' + ext + '" could not be loaded. It was either not found or is not a valid extension.');
      }
    }

    if (typeof ext === 'function') {
      ext = ext();
    }

    if (!showdown.helper.isArray(ext)) {
      ext = [ext];
    }

    var validExt = validate(ext, name);
    if (!validExt.valid) {
      throw Error(validExt.error);
    }

    for (var i = 0; i < ext.length; ++i) {
      switch (ext[i].type) {

        case 'lang':
          langExtensions.push(ext[i]);
          break;

        case 'output':
          outputModifiers.push(ext[i]);
          break;
      }
      if (ext[i].hasOwnProperty('listeners')) {
        for (var ln in ext[i].listeners) {
          if (ext[i].listeners.hasOwnProperty(ln)) {
            listen(ln, ext[i].listeners[ln]);
          }
        }
      }
    }

  }

  /**
   * LEGACY_SUPPORT
   * @param {*} ext
   * @param {string} name
   */
  function legacyExtensionLoading (ext, name) {
    if (typeof ext === 'function') {
      ext = ext(new showdown.Converter());
    }
    if (!showdown.helper.isArray(ext)) {
      ext = [ext];
    }
    var valid = validate(ext, name);

    if (!valid.valid) {
      throw Error(valid.error);
    }

    for (var i = 0; i < ext.length; ++i) {
      switch (ext[i].type) {
        case 'lang':
          langExtensions.push(ext[i]);
          break;
        case 'output':
          outputModifiers.push(ext[i]);
          break;
        default:// should never reach here
          throw Error('Extension loader error: Type unrecognized!!!');
      }
    }
  }

  /**
   * Listen to an event
   * @param {string} name
   * @param {function} callback
   */
  function listen (name, callback) {
    if (!showdown.helper.isString(name)) {
      throw Error('Invalid argument in converter.listen() method: name must be a string, but ' + typeof name + ' given');
    }

    if (typeof callback !== 'function') {
      throw Error('Invalid argument in converter.listen() method: callback must be a function, but ' + typeof callback + ' given');
    }

    if (!listeners.hasOwnProperty(name)) {
      listeners[name] = [];
    }
    listeners[name].push(callback);
  }

  function rTrimInputText (text) {
    var rsp = text.match(/^\s*/)[0].length,
        rgx = new RegExp('^\\s{0,' + rsp + '}', 'gm');
    return text.replace(rgx, '');
  }

  /**
   * Dispatch an event
   * @private
   * @param {string} evtName Event name
   * @param {string} text Text
   * @param {{}} options Converter Options
   * @param {{}} globals
   * @returns {string}
   */
  this._dispatch = function dispatch (evtName, text, options, globals) {
    if (listeners.hasOwnProperty(evtName)) {
      for (var ei = 0; ei < listeners[evtName].length; ++ei) {
        var nText = listeners[evtName][ei](evtName, text, this, options, globals);
        if (nText && typeof nText !== 'undefined') {
          text = nText;
        }
      }
    }
    return text;
  };

  /**
   * Listen to an event
   * @param {string} name
   * @param {function} callback
   * @returns {showdown.Converter}
   */
  this.listen = function (name, callback) {
    listen(name, callback);
    return this;
  };

  /**
   * Converts a markdown string into HTML
   * @param {string} text
   * @returns {*}
   */
  this.makeHtml = function (text) {
    //check if text is not falsy
    if (!text) {
      return text;
    }

    var globals = {
      gHtmlBlocks:     [],
      gHtmlMdBlocks:   [],
      gHtmlSpans:      [],
      gUrls:           {},
      gTitles:         {},
      gDimensions:     {},
      gListLevel:      0,
      hashLinkCounts:  {},
      langExtensions:  langExtensions,
      outputModifiers: outputModifiers,
      converter:       this,
      ghCodeBlocks:    [],
      metadata: {
        parsed: {},
        raw: '',
        format: ''
      }
    };

    // This lets us use ¨ trema as an escape char to avoid md5 hashes
    // The choice of character is arbitrary; anything that isn't
    // magic in Markdown will work.
    text = text.replace(/¨/g, '¨T');

    // Replace $ with ¨D
    // RegExp interprets $ as a special character
    // when it's in a replacement string
    text = text.replace(/\$/g, '¨D');

    // Standardize line endings
    text = text.replace(/\r\n/g, '\n'); // DOS to Unix
    text = text.replace(/\r/g, '\n'); // Mac to Unix

    // Stardardize line spaces
    text = text.replace(/\u00A0/g, '&nbsp;');

    if (options.smartIndentationFix) {
      text = rTrimInputText(text);
    }

    // Make sure text begins and ends with a couple of newlines:
    text = '\n\n' + text + '\n\n';

    // detab
    text = showdown.subParser('detab')(text, options, globals);

    /**
     * Strip any lines consisting only of spaces and tabs.
     * This makes subsequent regexs easier to write, because we can
     * match consecutive blank lines with /\n+/ instead of something
     * contorted like /[ \t]*\n+/
     */
    text = text.replace(/^[ \t]+$/mg, '');

    //run languageExtensions
    showdown.helper.forEach(langExtensions, function (ext) {
      text = showdown.subParser('runExtension')(ext, text, options, globals);
    });

    // run the sub parsers
    text = showdown.subParser('metadata')(text, options, globals);
    text = showdown.subParser('hashPreCodeTags')(text, options, globals);
    text = showdown.subParser('githubCodeBlocks')(text, options, globals);
    text = showdown.subParser('hashHTMLBlocks')(text, options, globals);
    text = showdown.subParser('hashCodeTags')(text, options, globals);
    text = showdown.subParser('stripLinkDefinitions')(text, options, globals);
    text = showdown.subParser('blockGamut')(text, options, globals);
    text = showdown.subParser('unhashHTMLSpans')(text, options, globals);
    text = showdown.subParser('unescapeSpecialChars')(text, options, globals);

    // attacklab: Restore dollar signs
    text = text.replace(/¨D/g, '$$');

    // attacklab: Restore tremas
    text = text.replace(/¨T/g, '¨');

    // render a complete html document instead of a partial if the option is enabled
    text = showdown.subParser('completeHTMLDocument')(text, options, globals);

    // Run output modifiers
    showdown.helper.forEach(outputModifiers, function (ext) {
      text = showdown.subParser('runExtension')(ext, text, options, globals);
    });

    // update metadata
    metadata = globals.metadata;
    return text;
  };

  /**
   * Converts an HTML string into a markdown string
   * @param src
   * @param [HTMLParser] A WHATWG DOM and HTML parser, such as JSDOM. If none is supplied, window.document will be used.
   * @returns {string}
   */
  this.makeMarkdown = this.makeMd = function (src, HTMLParser) {

    // replace \r\n with \n
    src = src.replace(/\r\n/g, '\n');
    src = src.replace(/\r/g, '\n'); // old macs

    // due to an edge case, we need to find this: > <
    // to prevent removing of non silent white spaces
    // ex: <em>this is</em> <strong>sparta</strong>
    src = src.replace(/>[ \t]+</, '>¨NBSP;<');

    if (!HTMLParser) {
      if (window && window.document) {
        HTMLParser = window.document;
      } else {
        throw new Error('HTMLParser is undefined. If in a webworker or nodejs environment, you need to provide a WHATWG DOM and HTML such as JSDOM');
      }
    }

    var doc = HTMLParser.createElement('div');
    doc.innerHTML = src;

    var globals = {
      preList: substitutePreCodeTags(doc)
    };

    // remove all newlines and collapse spaces
    clean(doc);

    // some stuff, like accidental reference links must now be escaped
    // TODO
    // doc.innerHTML = doc.innerHTML.replace(/\[[\S\t ]]/);

    var nodes = doc.childNodes,
        mdDoc = '';

    for (var i = 0; i < nodes.length; i++) {
      mdDoc += showdown.subParser('makeMarkdown.node')(nodes[i], globals);
    }

    function clean (node) {
      for (var n = 0; n < node.childNodes.length; ++n) {
        var child = node.childNodes[n];
        if (child.nodeType === 3) {
          if (!/\S/.test(child.nodeValue)) {
            node.removeChild(child);
            --n;
          } else {
            child.nodeValue = child.nodeValue.split('\n').join(' ');
            child.nodeValue = child.nodeValue.replace(/(\s)+/g, '$1');
          }
        } else if (child.nodeType === 1) {
          clean(child);
        }
      }
    }

    // find all pre tags and replace contents with placeholder
    // we need this so that we can remove all indentation from html
    // to ease up parsing
    function substitutePreCodeTags (doc) {

      var pres = doc.querySelectorAll('pre'),
          presPH = [];

      for (var i = 0; i < pres.length; ++i) {

        if (pres[i].childElementCount === 1 && pres[i].firstChild.tagName.toLowerCase() === 'code') {
          var content = pres[i].firstChild.innerHTML.trim(),
              language = pres[i].firstChild.getAttribute('data-language') || '';

          // if data-language attribute is not defined, then we look for class language-*
          if (language === '') {
            var classes = pres[i].firstChild.className.split(' ');
            for (var c = 0; c < classes.length; ++c) {
              var matches = classes[c].match(/^language-(.+)$/);
              if (matches !== null) {
                language = matches[1];
                break;
              }
            }
          }

          // unescape html entities in content
          content = showdown.helper.unescapeHTMLEntities(content);

          presPH.push(content);
          pres[i].outerHTML = '<precode language="' + language + '" precodenum="' + i.toString() + '"></precode>';
        } else {
          presPH.push(pres[i].innerHTML);
          pres[i].innerHTML = '';
          pres[i].setAttribute('prenum', i.toString());
        }
      }
      return presPH;
    }

    return mdDoc;
  };

  /**
   * Set an option of this Converter instance
   * @param {string} key
   * @param {*} value
   */
  this.setOption = function (key, value) {
    options[key] = value;
  };

  /**
   * Get the option of this Converter instance
   * @param {string} key
   * @returns {*}
   */
  this.getOption = function (key) {
    return options[key];
  };

  /**
   * Get the options of this Converter instance
   * @returns {{}}
   */
  this.getOptions = function () {
    return options;
  };

  /**
   * Add extension to THIS converter
   * @param {{}} extension
   * @param {string} [name=null]
   */
  this.addExtension = function (extension, name) {
    name = name || null;
    _parseExtension(extension, name);
  };

  /**
   * Use a global registered extension with THIS converter
   * @param {string} extensionName Name of the previously registered extension
   */
  this.useExtension = function (extensionName) {
    _parseExtension(extensionName);
  };

  /**
   * Set the flavor THIS converter should use
   * @param {string} name
   */
  this.setFlavor = function (name) {
    if (!flavor.hasOwnProperty(name)) {
      throw Error(name + ' flavor was not found');
    }
    var preset = flavor[name];
    setConvFlavor = name;
    for (var option in preset) {
      if (preset.hasOwnProperty(option)) {
        options[option] = preset[option];
      }
    }
  };

  /**
   * Get the currently set flavor of this converter
   * @returns {string}
   */
  this.getFlavor = function () {
    return setConvFlavor;
  };

  /**
   * Remove an extension from THIS converter.
   * Note: This is a costly operation. It's better to initialize a new converter
   * and specify the extensions you wish to use
   * @param {Array} extension
   */
  this.removeExtension = function (extension) {
    if (!showdown.helper.isArray(extension)) {
      extension = [extension];
    }
    for (var a = 0; a < extension.length; ++a) {
      var ext = extension[a];
      for (var i = 0; i < langExtensions.length; ++i) {
        if (langExtensions[i] === ext) {
          langExtensions[i].splice(i, 1);
        }
      }
      for (var ii = 0; ii < outputModifiers.length; ++i) {
        if (outputModifiers[ii] === ext) {
          outputModifiers[ii].splice(i, 1);
        }
      }
    }
  };

  /**
   * Get all extension of THIS converter
   * @returns {{language: Array, output: Array}}
   */
  this.getAllExtensions = function () {
    return {
      language: langExtensions,
      output: outputModifiers
    };
  };

  /**
   * Get the metadata of the previously parsed document
   * @param raw
   * @returns {string|{}}
   */
  this.getMetadata = function (raw) {
    if (raw) {
      return metadata.raw;
    } else {
      return metadata.parsed;
    }
  };

  /**
   * Get the metadata format of the previously parsed document
   * @returns {string}
   */
  this.getMetadataFormat = function () {
    return metadata.format;
  };

  /**
   * Private: set a single key, value metadata pair
   * @param {string} key
   * @param {string} value
   */
  this._setMetadataPair = function (key, value) {
    metadata.parsed[key] = value;
  };

  /**
   * Private: set metadata format
   * @param {string} format
   */
  this._setMetadataFormat = function (format) {
    metadata.format = format;
  };

  /**
   * Private: set metadata raw text
   * @param {string} raw
   */
  this._setMetadataRaw = function (raw) {
    metadata.raw = raw;
  };
};

/**
 * Turn Markdown link shortcuts into XHTML <a> tags.
 */
showdown.subParser('anchors', function (text, options, globals) {
  'use strict';

  text = globals.converter._dispatch('anchors.before', text, options, globals);

  var writeAnchorTag = function (wholeMatch, linkText, linkId, url, m5, m6, title) {
    if (showdown.helper.isUndefined(title)) {
      title = '';
    }
    linkId = linkId.toLowerCase();

    // Special case for explicit empty url
    if (wholeMatch.search(/\(<?\s*>? ?(['"].*['"])?\)$/m) > -1) {
      url = '';
    } else if (!url) {
      if (!linkId) {
        // lower-case and turn embedded newlines into spaces
        linkId = linkText.toLowerCase().replace(/ ?\n/g, ' ');
      }
      url = '#' + linkId;

      if (!showdown.helper.isUndefined(globals.gUrls[linkId])) {
        url = globals.gUrls[linkId];
        if (!showdown.helper.isUndefined(globals.gTitles[linkId])) {
          title = globals.gTitles[linkId];
        }
      } else {
        return wholeMatch;
      }
    }

    //url = showdown.helper.escapeCharacters(url, '*_', false); // replaced line to improve performance
    url = url.replace(showdown.helper.regexes.asteriskDashAndColon, showdown.helper.escapeCharactersCallback);

    var result = '<a href="' + url + '"';

    if (title !== '' && title !== null) {
      title = title.replace(/"/g, '&quot;');
      //title = showdown.helper.escapeCharacters(title, '*_', false); // replaced line to improve performance
      title = title.replace(showdown.helper.regexes.asteriskDashAndColon, showdown.helper.escapeCharactersCallback);
      result += ' title="' + title + '"';
    }

    // optionLinksInNewWindow only applies
    // to external links. Hash links (#) open in same page
    if (options.openLinksInNewWindow && !/^#/.test(url)) {
      // escaped _
      result += ' rel="noopener noreferrer" target="¨E95Eblank"';
    }

    result += '>' + linkText + '</a>';

    return result;
  };

  // First, handle reference-style links: [link text] [id]
  text = text.replace(/\[((?:\[[^\]]*]|[^\[\]])*)] ?(?:\n *)?\[(.*?)]()()()()/g, writeAnchorTag);

  // Next, inline-style links: [link text](url "optional title")
  // cases with crazy urls like ./image/cat1).png
  text = text.replace(/\[((?:\[[^\]]*]|[^\[\]])*)]()[ \t]*\([ \t]?<([^>]*)>(?:[ \t]*((["'])([^"]*?)\5))?[ \t]?\)/g,
    writeAnchorTag);

  // normal cases
  text = text.replace(/\[((?:\[[^\]]*]|[^\[\]])*)]()[ \t]*\([ \t]?<?([\S]+?(?:\([\S]*?\)[\S]*?)?)>?(?:[ \t]*((["'])([^"]*?)\5))?[ \t]?\)/g,
    writeAnchorTag);

  // handle reference-style shortcuts: [link text]
  // These must come last in case you've also got [link test][1]
  // or [link test](/foo)
  text = text.replace(/\[([^\[\]]+)]()()()()()/g, writeAnchorTag);

  // Lastly handle GithubMentions if option is enabled
  if (options.ghMentions) {
    text = text.replace(/(^|\s)(\\)?(@([a-z\d]+(?:[a-z\d.-]+?[a-z\d]+)*))/gmi, function (wm, st, escape, mentions, username) {
      if (escape === '\\') {
        return st + mentions;
      }

      //check if options.ghMentionsLink is a string
      if (!showdown.helper.isString(options.ghMentionsLink)) {
        throw new Error('ghMentionsLink option must be a string');
      }
      var lnk = options.ghMentionsLink.replace(/\{u}/g, username),
          target = '';
      if (options.openLinksInNewWindow) {
        target = ' rel="noopener noreferrer" target="¨E95Eblank"';
      }
      return st + '<a href="' + lnk + '"' + target + '>' + mentions + '</a>';
    });
  }

  text = globals.converter._dispatch('anchors.after', text, options, globals);
  return text;
});

// url allowed chars [a-z\d_.~:/?#[]@!$&'()*+,;=-]

var simpleURLRegex  = /([*~_]+|\b)(((https?|ftp|dict):\/\/|www\.)[^'">\s]+?\.[^'">\s]+?)()(\1)?(?=\s|$)(?!["<>])/gi,
    simpleURLRegex2 = /([*~_]+|\b)(((https?|ftp|dict):\/\/|www\.)[^'">\s]+\.[^'">\s]+?)([.!?,()\[\]])?(\1)?(?=\s|$)(?!["<>])/gi,
    delimUrlRegex   = /()<(((https?|ftp|dict):\/\/|www\.)[^'">\s]+)()>()/gi,
    simpleMailRegex = /(^|\s)(?:mailto:)?([A-Za-z0-9!#$%&'*+-/=?^_`{|}~.]+@[-a-z0-9]+(\.[-a-z0-9]+)*\.[a-z]+)(?=$|\s)/gmi,
    delimMailRegex  = /<()(?:mailto:)?([-.\w]+@[-a-z0-9]+(\.[-a-z0-9]+)*\.[a-z]+)>/gi,

    replaceLink = function (options) {
      'use strict';
      return function (wm, leadingMagicChars, link, m2, m3, trailingPunctuation, trailingMagicChars) {
        link = link.replace(showdown.helper.regexes.asteriskDashAndColon, showdown.helper.escapeCharactersCallback);
        var lnkTxt = link,
            append = '',
            target = '',
            lmc    = leadingMagicChars || '',
            tmc    = trailingMagicChars || '';
        if (/^www\./i.test(link)) {
          link = link.replace(/^www\./i, 'http://www.');
        }
        if (options.excludeTrailingPunctuationFromURLs && trailingPunctuation) {
          append = trailingPunctuation;
        }
        if (options.openLinksInNewWindow) {
          target = ' rel="noopener noreferrer" target="¨E95Eblank"';
        }
        return lmc + '<a href="' + link + '"' + target + '>' + lnkTxt + '</a>' + append + tmc;
      };
    },

    replaceMail = function (options, globals) {
      'use strict';
      return function (wholeMatch, b, mail) {
        var href = 'mailto:';
        b = b || '';
        mail = showdown.subParser('unescapeSpecialChars')(mail, options, globals);
        if (options.encodeEmails) {
          href = showdown.helper.encodeEmailAddress(href + mail);
          mail = showdown.helper.encodeEmailAddress(mail);
        } else {
          href = href + mail;
        }
        return b + '<a href="' + href + '">' + mail + '</a>';
      };
    };

showdown.subParser('autoLinks', function (text, options, globals) {
  'use strict';

  text = globals.converter._dispatch('autoLinks.before', text, options, globals);

  text = text.replace(delimUrlRegex, replaceLink(options));
  text = text.replace(delimMailRegex, replaceMail(options, globals));

  text = globals.converter._dispatch('autoLinks.after', text, options, globals);

  return text;
});

showdown.subParser('simplifiedAutoLinks', function (text, options, globals) {
  'use strict';

  if (!options.simplifiedAutoLink) {
    return text;
  }

  text = globals.converter._dispatch('simplifiedAutoLinks.before', text, options, globals);

  if (options.excludeTrailingPunctuationFromURLs) {
    text = text.replace(simpleURLRegex2, replaceLink(options));
  } else {
    text = text.replace(simpleURLRegex, replaceLink(options));
  }
  text = text.replace(simpleMailRegex, replaceMail(options, globals));

  text = globals.converter._dispatch('simplifiedAutoLinks.after', text, options, globals);

  return text;
});

/**
 * These are all the transformations that form block-level
 * tags like paragraphs, headers, and list items.
 */
showdown.subParser('blockGamut', function (text, options, globals) {
  'use strict';

  text = globals.converter._dispatch('blockGamut.before', text, options, globals);

  // we parse blockquotes first so that we can have headings and hrs
  // inside blockquotes
  text = showdown.subParser('blockQuotes')(text, options, globals);
  text = showdown.subParser('headers')(text, options, globals);

  // Do Horizontal Rules:
  text = showdown.subParser('horizontalRule')(text, options, globals);

  text = showdown.subParser('lists')(text, options, globals);
  text = showdown.subParser('codeBlocks')(text, options, globals);
  text = showdown.subParser('tables')(text, options, globals);

  // We already ran _HashHTMLBlocks() before, in Markdown(), but that
  // was to escape raw HTML in the original Markdown source. This time,
  // we're escaping the markup we've just created, so that we don't wrap
  // <p> tags around block-level tags.
  text = showdown.subParser('hashHTMLBlocks')(text, options, globals);
  text = showdown.subParser('paragraphs')(text, options, globals);

  text = globals.converter._dispatch('blockGamut.after', text, options, globals);

  return text;
});

showdown.subParser('blockQuotes', function (text, options, globals) {
  'use strict';

  text = globals.converter._dispatch('blockQuotes.before', text, options, globals);

  // add a couple extra lines after the text and endtext mark
  text = text + '\n\n';

  var rgx = /(^ {0,3}>[ \t]?.+\n(.+\n)*\n*)+/gm;

  if (options.splitAdjacentBlockquotes) {
    rgx = /^ {0,3}>[\s\S]*?(?:\n\n)/gm;
  }

  text = text.replace(rgx, function (bq) {
    // attacklab: hack around Konqueror 3.5.4 bug:
    // "----------bug".replace(/^-/g,"") == "bug"
    bq = bq.replace(/^[ \t]*>[ \t]?/gm, ''); // trim one level of quoting

    // attacklab: clean up hack
    bq = bq.replace(/¨0/g, '');

    bq = bq.replace(/^[ \t]+$/gm, ''); // trim whitespace-only lines
    bq = showdown.subParser('githubCodeBlocks')(bq, options, globals);
    bq = showdown.subParser('blockGamut')(bq, options, globals); // recurse

    bq = bq.replace(/(^|\n)/g, '$1  ');
    // These leading spaces screw with <pre> content, so we need to fix that:
    bq = bq.replace(/(\s*<pre>[^\r]+?<\/pre>)/gm, function (wholeMatch, m1) {
      var pre = m1;
      // attacklab: hack around Konqueror 3.5.4 bug:
      pre = pre.replace(/^  /mg, '¨0');
      pre = pre.replace(/¨0/g, '');
      return pre;
    });

    return showdown.subParser('hashBlock')('<blockquote>\n' + bq + '\n</blockquote>', options, globals);
  });

  text = globals.converter._dispatch('blockQuotes.after', text, options, globals);
  return text;
});

/**
 * Process Markdown `<pre><code>` blocks.
 */
showdown.subParser('codeBlocks', function (text, options, globals) {
  'use strict';

  text = globals.converter._dispatch('codeBlocks.before', text, options, globals);

  // sentinel workarounds for lack of \A and \Z, safari\khtml bug
  text += '¨0';

  var pattern = /(?:\n\n|^)((?:(?:[ ]{4}|\t).*\n+)+)(\n*[ ]{0,3}[^ \t\n]|(?=¨0))/g;
  text = text.replace(pattern, function (wholeMatch, m1, m2) {
    var codeblock = m1,
        nextChar = m2,
        end = '\n';

    codeblock = showdown.subParser('outdent')(codeblock, options, globals);
    codeblock = showdown.subParser('encodeCode')(codeblock, options, globals);
    codeblock = showdown.subParser('detab')(codeblock, options, globals);
    codeblock = codeblock.replace(/^\n+/g, ''); // trim leading newlines
    codeblock = codeblock.replace(/\n+$/g, ''); // trim trailing newlines

    if (options.omitExtraWLInCodeBlocks) {
      end = '';
    }

    codeblock = '<pre><code>' + codeblock + end + '</code></pre>';

    return showdown.subParser('hashBlock')(codeblock, options, globals) + nextChar;
  });

  // strip sentinel
  text = text.replace(/¨0/, '');

  text = globals.converter._dispatch('codeBlocks.after', text, options, globals);
  return text;
});

/**
 *
 *   *  Backtick quotes are used for <code></code> spans.
 *
 *   *  You can use multiple backticks as the delimiters if you want to
 *     include literal backticks in the code span. So, this input:
 *
 *         Just type ``foo `bar` baz`` at the prompt.
 *
 *       Will translate to:
 *
 *         <p>Just type <code>foo `bar` baz</code> at the prompt.</p>
 *
 *    There's no arbitrary limit to the number of backticks you
 *    can use as delimters. If you need three consecutive backticks
 *    in your code, use four for delimiters, etc.
 *
 *  *  You can use spaces to get literal backticks at the edges:
 *
 *         ... type `` `bar` `` ...
 *
 *       Turns to:
 *
 *         ... type <code>`bar`</code> ...
 */
showdown.subParser('codeSpans', function (text, options, globals) {
  'use strict';

  text = globals.converter._dispatch('codeSpans.before', text, options, globals);

  if (typeof text === 'undefined') {
    text = '';
  }
  text = text.replace(/(^|[^\\])(`+)([^\r]*?[^`])\2(?!`)/gm,
    function (wholeMatch, m1, m2, m3) {
      var c = m3;
      c = c.replace(/^([ \t]*)/g, '');	// leading whitespace
      c = c.replace(/[ \t]*$/g, '');	// trailing whitespace
      c = showdown.subParser('encodeCode')(c, options, globals);
      c = m1 + '<code>' + c + '</code>';
      c = showdown.subParser('hashHTMLSpans')(c, options, globals);
      return c;
    }
  );

  text = globals.converter._dispatch('codeSpans.after', text, options, globals);
  return text;
});

/**
 * Create a full HTML document from the processed markdown
 */
showdown.subParser('completeHTMLDocument', function (text, options, globals) {
  'use strict';

  if (!options.completeHTMLDocument) {
    return text;
  }

  text = globals.converter._dispatch('completeHTMLDocument.before', text, options, globals);

  var doctype = 'html',
      doctypeParsed = '<!DOCTYPE HTML>\n',
      title = '',
      charset = '<meta charset="utf-8">\n',
      lang = '',
      metadata = '';

  if (typeof globals.metadata.parsed.doctype !== 'undefined') {
    doctypeParsed = '<!DOCTYPE ' +  globals.metadata.parsed.doctype + '>\n';
    doctype = globals.metadata.parsed.doctype.toString().toLowerCase();
    if (doctype === 'html' || doctype === 'html5') {
      charset = '<meta charset="utf-8">';
    }
  }

  for (var meta in globals.metadata.parsed) {
    if (globals.metadata.parsed.hasOwnProperty(meta)) {
      switch (meta.toLowerCase()) {
        case 'doctype':
          break;

        case 'title':
          title = '<title>' +  globals.metadata.parsed.title + '</title>\n';
          break;

        case 'charset':
          if (doctype === 'html' || doctype === 'html5') {
            charset = '<meta charset="' + globals.metadata.parsed.charset + '">\n';
          } else {
            charset = '<meta name="charset" content="' + globals.metadata.parsed.charset + '">\n';
          }
          break;

        case 'language':
        case 'lang':
          lang = ' lang="' + globals.metadata.parsed[meta] + '"';
          metadata += '<meta name="' + meta + '" content="' + globals.metadata.parsed[meta] + '">\n';
          break;

        default:
          metadata += '<meta name="' + meta + '" content="' + globals.metadata.parsed[meta] + '">\n';
      }
    }
  }

  text = doctypeParsed + '<html' + lang + '>\n<head>\n' + title + charset + metadata + '</head>\n<body>\n' + text.trim() + '\n</body>\n</html>';

  text = globals.converter._dispatch('completeHTMLDocument.after', text, options, globals);
  return text;
});

/**
 * Convert all tabs to spaces
 */
showdown.subParser('detab', function (text, options, globals) {
  'use strict';
  text = globals.converter._dispatch('detab.before', text, options, globals);

  // expand first n-1 tabs
  text = text.replace(/\t(?=\t)/g, '    '); // g_tab_width

  // replace the nth with two sentinels
  text = text.replace(/\t/g, '¨A¨B');

  // use the sentinel to anchor our regex so it doesn't explode
  text = text.replace(/¨B(.+?)¨A/g, function (wholeMatch, m1) {
    var leadingText = m1,
        numSpaces = 4 - leadingText.length % 4;  // g_tab_width

    // there *must* be a better way to do this:
    for (var i = 0; i < numSpaces; i++) {
      leadingText += ' ';
    }

    return leadingText;
  });

  // clean up sentinels
  text = text.replace(/¨A/g, '    ');  // g_tab_width
  text = text.replace(/¨B/g, '');

  text = globals.converter._dispatch('detab.after', text, options, globals);
  return text;
});

showdown.subParser('ellipsis', function (text, options, globals) {
  'use strict';

  text = globals.converter._dispatch('ellipsis.before', text, options, globals);

  text = text.replace(/\.\.\./g, '…');

  text = globals.converter._dispatch('ellipsis.after', text, options, globals);

  return text;
});

/**
 * Turn emoji codes into emojis
 *
 * List of supported emojis: https://github.com/showdownjs/showdown/wiki/Emojis
 */
showdown.subParser('emoji', function (text, options, globals) {
  'use strict';

  if (!options.emoji) {
    return text;
  }

  text = globals.converter._dispatch('emoji.before', text, options, globals);

  var emojiRgx = /:([\S]+?):/g;

  text = text.replace(emojiRgx, function (wm, emojiCode) {
    if (showdown.helper.emojis.hasOwnProperty(emojiCode)) {
      return showdown.helper.emojis[emojiCode];
    }
    return wm;
  });

  text = globals.converter._dispatch('emoji.after', text, options, globals);

  return text;
});

/**
 * Smart processing for ampersands and angle brackets that need to be encoded.
 */
showdown.subParser('encodeAmpsAndAngles', function (text, options, globals) {
  'use strict';
  text = globals.converter._dispatch('encodeAmpsAndAngles.before', text, options, globals);

  // Ampersand-encoding based entirely on Nat Irons's Amputator MT plugin:
  // http://bumppo.net/projects/amputator/
  text = text.replace(/&(?!#?[xX]?(?:[0-9a-fA-F]+|\w+);)/g, '&amp;');

  // Encode naked <'s
  text = text.replace(/<(?![a-z\/?$!])/gi, '&lt;');

  // Encode <
  text = text.replace(/</g, '&lt;');

  // Encode >
  text = text.replace(/>/g, '&gt;');

  text = globals.converter._dispatch('encodeAmpsAndAngles.after', text, options, globals);
  return text;
});

/**
 * Returns the string, with after processing the following backslash escape sequences.
 *
 * attacklab: The polite way to do this is with the new escapeCharacters() function:
 *
 *    text = escapeCharacters(text,"\\",true);
 *    text = escapeCharacters(text,"`*_{}[]()>#+-.!",true);
 *
 * ...but we're sidestepping its use of the (slow) RegExp constructor
 * as an optimization for Firefox.  This function gets called a LOT.
 */
showdown.subParser('encodeBackslashEscapes', function (text, options, globals) {
  'use strict';
  text = globals.converter._dispatch('encodeBackslashEscapes.before', text, options, globals);

  text = text.replace(/\\(\\)/g, showdown.helper.escapeCharactersCallback);
  text = text.replace(/\\([`*_{}\[\]()>#+.!~=|-])/g, showdown.helper.escapeCharactersCallback);

  text = globals.converter._dispatch('encodeBackslashEscapes.after', text, options, globals);
  return text;
});

/**
 * Encode/escape certain characters inside Markdown code runs.
 * The point is that in code, these characters are literals,
 * and lose their special Markdown meanings.
 */
showdown.subParser('encodeCode', function (text, options, globals) {
  'use strict';

  text = globals.converter._dispatch('encodeCode.before', text, options, globals);

  // Encode all ampersands; HTML entities are not
  // entities within a Markdown code span.
  text = text
    .replace(/&/g, '&amp;')
  // Do the angle bracket song and dance:
    .replace(/</g, '&lt;')
    .replace(/>/g, '&gt;')
  // Now, escape characters that are magic in Markdown:
    .replace(/([*_{}\[\]\\=~-])/g, showdown.helper.escapeCharactersCallback);

  text = globals.converter._dispatch('encodeCode.after', text, options, globals);
  return text;
});

/**
 * Within tags -- meaning between < and > -- encode [\ ` * _ ~ =] so they
 * don't conflict with their use in Markdown for code, italics and strong.
 */
showdown.subParser('escapeSpecialCharsWithinTagAttributes', function (text, options, globals) {
  'use strict';
  text = globals.converter._dispatch('escapeSpecialCharsWithinTagAttributes.before', text, options, globals);

  // Build a regex to find HTML tags.
  var tags     = /<\/?[a-z\d_:-]+(?:[\s]+[\s\S]+?)?>/gi,
      comments = /<!(--(?:(?:[^>-]|-[^>])(?:[^-]|-[^-])*)--)>/gi;

  text = text.replace(tags, function (wholeMatch) {
    return wholeMatch
      .replace(/(.)<\/?code>(?=.)/g, '$1`')
      .replace(/([\\`*_~=|])/g, showdown.helper.escapeCharactersCallback);
  });

  text = text.replace(comments, function (wholeMatch) {
    return wholeMatch
      .replace(/([\\`*_~=|])/g, showdown.helper.escapeCharactersCallback);
  });

  text = globals.converter._dispatch('escapeSpecialCharsWithinTagAttributes.after', text, options, globals);
  return text;
});

/**
 * Handle github codeblocks prior to running HashHTML so that
 * HTML contained within the codeblock gets escaped properly
 * Example:
 * ```ruby
 *     def hello_world(x)
 *       puts "Hello, #{x}"
 *     end
 * ```
 */
showdown.subParser('githubCodeBlocks', function (text, options, globals) {
  'use strict';

  // early exit if option is not enabled
  if (!options.ghCodeBlocks) {
    return text;
  }

  text = globals.converter._dispatch('githubCodeBlocks.before', text, options, globals);

  text += '¨0';

  text = text.replace(/(?:^|\n)(?: {0,3})(```+|~~~+)(?: *)([^\s`~]*)\n([\s\S]*?)\n(?: {0,3})\1/g, function (wholeMatch, delim, language, codeblock) {
    var end = (options.omitExtraWLInCodeBlocks) ? '' : '\n';

    // First parse the github code block
    codeblock = showdown.subParser('encodeCode')(codeblock, options, globals);
    codeblock = showdown.subParser('detab')(codeblock, options, globals);
    codeblock = codeblock.replace(/^\n+/g, ''); // trim leading newlines
    codeblock = codeblock.replace(/\n+$/g, ''); // trim trailing whitespace

    codeblock = '<pre><code' + (language ? ' class="' + language + ' language-' + language + '"' : '') + '>' + codeblock + end + '</code></pre>';

    codeblock = showdown.subParser('hashBlock')(codeblock, options, globals);

    // Since GHCodeblocks can be false positives, we need to
    // store the primitive text and the parsed text in a global var,
    // and then return a token
    return '\n\n¨G' + (globals.ghCodeBlocks.push({text: wholeMatch, codeblock: codeblock}) - 1) + 'G\n\n';
  });

  // attacklab: strip sentinel
  text = text.replace(/¨0/, '');

  return globals.converter._dispatch('githubCodeBlocks.after', text, options, globals);
});

showdown.subParser('hashBlock', function (text, options, globals) {
  'use strict';
  text = globals.converter._dispatch('hashBlock.before', text, options, globals);
  text = text.replace(/(^\n+|\n+$)/g, '');
  text = '\n\n¨K' + (globals.gHtmlBlocks.push(text) - 1) + 'K\n\n';
  text = globals.converter._dispatch('hashBlock.after', text, options, globals);
  return text;
});

/**
 * Hash and escape <code> elements that should not be parsed as markdown
 */
showdown.subParser('hashCodeTags', function (text, options, globals) {
  'use strict';
  text = globals.converter._dispatch('hashCodeTags.before', text, options, globals);

  var repFunc = function (wholeMatch, match, left, right) {
    var codeblock = left + showdown.subParser('encodeCode')(match, options, globals) + right;
    return '¨C' + (globals.gHtmlSpans.push(codeblock) - 1) + 'C';
  };

  // Hash naked <code>
  text = showdown.helper.replaceRecursiveRegExp(text, repFunc, '<code\\b[^>]*>', '</code>', 'gim');

  text = globals.converter._dispatch('hashCodeTags.after', text, options, globals);
  return text;
});

showdown.subParser('hashElement', function (text, options, globals) {
  'use strict';

  return function (wholeMatch, m1) {
    var blockText = m1;

    // Undo double lines
    blockText = blockText.replace(/\n\n/g, '\n');
    blockText = blockText.replace(/^\n/, '');

    // strip trailing blank lines
    blockText = blockText.replace(/\n+$/g, '');

    // Replace the element text with a marker ("¨KxK" where x is its key)
    blockText = '\n\n¨K' + (globals.gHtmlBlocks.push(blockText) - 1) + 'K\n\n';

    return blockText;
  };
});

showdown.subParser('hashHTMLBlocks', function (text, options, globals) {
  'use strict';
  text = globals.converter._dispatch('hashHTMLBlocks.before', text, options, globals);

  var blockTags = [
        'pre',
        'div',
        'h1',
        'h2',
        'h3',
        'h4',
        'h5',
        'h6',
        'blockquote',
        'table',
        'dl',
        'ol',
        'ul',
        'script',
        'noscript',
        'form',
        'fieldset',
        'iframe',
        'math',
        'style',
        'section',
        'header',
        'footer',
        'nav',
        'article',
        'aside',
        'address',
        'audio',
        'canvas',
        'figure',
        'hgroup',
        'output',
        'video',
        'p'
      ],
      repFunc = function (wholeMatch, match, left, right) {
        var txt = wholeMatch;
        // check if this html element is marked as markdown
        // if so, it's contents should be parsed as markdown
        if (left.search(/\bmarkdown\b/) !== -1) {
          txt = left + globals.converter.makeHtml(match) + right;
        }
        return '\n\n¨K' + (globals.gHtmlBlocks.push(txt) - 1) + 'K\n\n';
      };

  if (options.backslashEscapesHTMLTags) {
    // encode backslash escaped HTML tags
    text = text.replace(/\\<(\/?[^>]+?)>/g, function (wm, inside) {
      return '&lt;' + inside + '&gt;';
    });
  }

  // hash HTML Blocks
  for (var i = 0; i < blockTags.length; ++i) {

    var opTagPos,
        rgx1     = new RegExp('^ {0,3}(<' + blockTags[i] + '\\b[^>]*>)', 'im'),
        patLeft  = '<' + blockTags[i] + '\\b[^>]*>',
        patRight = '</' + blockTags[i] + '>';
    // 1. Look for the first position of the first opening HTML tag in the text
    while ((opTagPos = showdown.helper.regexIndexOf(text, rgx1)) !== -1) {

      // if the HTML tag is \ escaped, we need to escape it and break


      //2. Split the text in that position
      var subTexts = showdown.helper.splitAtIndex(text, opTagPos),
          //3. Match recursively
          newSubText1 = showdown.helper.replaceRecursiveRegExp(subTexts[1], repFunc, patLeft, patRight, 'im');

      // prevent an infinite loop
      if (newSubText1 === subTexts[1]) {
        break;
      }
      text = subTexts[0].concat(newSubText1);
    }
  }
  // HR SPECIAL CASE
  text = text.replace(/(\n {0,3}(<(hr)\b([^<>])*?\/?>)[ \t]*(?=\n{2,}))/g,
    showdown.subParser('hashElement')(text, options, globals));

  // Special case for standalone HTML comments
  text = showdown.helper.replaceRecursiveRegExp(text, function (txt) {
    return '\n\n¨K' + (globals.gHtmlBlocks.push(txt) - 1) + 'K\n\n';
  }, '^ {0,3}<!--', '-->', 'gm');

  // PHP and ASP-style processor instructions (<?...?> and <%...%>)
  text = text.replace(/(?:\n\n)( {0,3}(?:<([?%])[^\r]*?\2>)[ \t]*(?=\n{2,}))/g,
    showdown.subParser('hashElement')(text, options, globals));

  text = globals.converter._dispatch('hashHTMLBlocks.after', text, options, globals);
  return text;
});

/**
 * Hash span elements that should not be parsed as markdown
 */
showdown.subParser('hashHTMLSpans', function (text, options, globals) {
  'use strict';
  text = globals.converter._dispatch('hashHTMLSpans.before', text, options, globals);

  function hashHTMLSpan (html) {
    return '¨C' + (globals.gHtmlSpans.push(html) - 1) + 'C';
  }

  // Hash Self Closing tags
  text = text.replace(/<[^>]+?\/>/gi, function (wm) {
    return hashHTMLSpan(wm);
  });

  // Hash tags without properties
  text = text.replace(/<([^>]+?)>[\s\S]*?<\/\1>/g, function (wm) {
    return hashHTMLSpan(wm);
  });

  // Hash tags with properties
  text = text.replace(/<([^>]+?)\s[^>]+?>[\s\S]*?<\/\1>/g, function (wm) {
    return hashHTMLSpan(wm);
  });

  // Hash self closing tags without />
  text = text.replace(/<[^>]+?>/gi, function (wm) {
    return hashHTMLSpan(wm);
  });

  /*showdown.helper.matchRecursiveRegExp(text, '<code\\b[^>]*>', '</code>', 'gi');*/

  text = globals.converter._dispatch('hashHTMLSpans.after', text, options, globals);
  return text;
});

/**
 * Unhash HTML spans
 */
showdown.subParser('unhashHTMLSpans', function (text, options, globals) {
  'use strict';
  text = globals.converter._dispatch('unhashHTMLSpans.before', text, options, globals);

  for (var i = 0; i < globals.gHtmlSpans.length; ++i) {
    var repText = globals.gHtmlSpans[i],
        // limiter to prevent infinite loop (assume 10 as limit for recurse)
        limit = 0;

    while (/¨C(\d+)C/.test(repText)) {
      var num = RegExp.$1;
      repText = repText.replace('¨C' + num + 'C', globals.gHtmlSpans[num]);
      if (limit === 10) {
        console.error('maximum nesting of 10 spans reached!!!');
        break;
      }
      ++limit;
    }
    text = text.replace('¨C' + i + 'C', repText);
  }

  text = globals.converter._dispatch('unhashHTMLSpans.after', text, options, globals);
  return text;
});

/**
 * Hash and escape <pre><code> elements that should not be parsed as markdown
 */
showdown.subParser('hashPreCodeTags', function (text, options, globals) {
  'use strict';
  text = globals.converter._dispatch('hashPreCodeTags.before', text, options, globals);

  var repFunc = function (wholeMatch, match, left, right) {
    // encode html entities
    var codeblock = left + showdown.subParser('encodeCode')(match, options, globals) + right;
    return '\n\n¨G' + (globals.ghCodeBlocks.push({text: wholeMatch, codeblock: codeblock}) - 1) + 'G\n\n';
  };

  // Hash <pre><code>
  text = showdown.helper.replaceRecursiveRegExp(text, repFunc, '^ {0,3}<pre\\b[^>]*>\\s*<code\\b[^>]*>', '^ {0,3}</code>\\s*</pre>', 'gim');

  text = globals.converter._dispatch('hashPreCodeTags.after', text, options, globals);
  return text;
});

showdown.subParser('headers', function (text, options, globals) {
  'use strict';

  text = globals.converter._dispatch('headers.before', text, options, globals);

  var headerLevelStart = (isNaN(parseInt(options.headerLevelStart))) ? 1 : parseInt(options.headerLevelStart),

      // Set text-style headers:
      //	Header 1
      //	========
      //
      //	Header 2
      //	--------
      //
      setextRegexH1 = (options.smoothLivePreview) ? /^(.+)[ \t]*\n={2,}[ \t]*\n+/gm : /^(.+)[ \t]*\n=+[ \t]*\n+/gm,
      setextRegexH2 = (options.smoothLivePreview) ? /^(.+)[ \t]*\n-{2,}[ \t]*\n+/gm : /^(.+)[ \t]*\n-+[ \t]*\n+/gm;

  text = text.replace(setextRegexH1, function (wholeMatch, m1) {

    var spanGamut = showdown.subParser('spanGamut')(m1, options, globals),
        hID = (options.noHeaderId) ? '' : ' id="' + headerId(m1) + '"',
        hLevel = headerLevelStart,
        hashBlock = '<h' + hLevel + hID + '>' + spanGamut + '</h' + hLevel + '>';
    return showdown.subParser('hashBlock')(hashBlock, options, globals);
  });

  text = text.replace(setextRegexH2, function (matchFound, m1) {
    var spanGamut = showdown.subParser('spanGamut')(m1, options, globals),
        hID = (options.noHeaderId) ? '' : ' id="' + headerId(m1) + '"',
        hLevel = headerLevelStart + 1,
        hashBlock = '<h' + hLevel + hID + '>' + spanGamut + '</h' + hLevel + '>';
    return showdown.subParser('hashBlock')(hashBlock, options, globals);
  });

  // atx-style headers:
  //  # Header 1
  //  ## Header 2
  //  ## Header 2 with closing hashes ##
  //  ...
  //  ###### Header 6
  //
  var atxStyle = (options.requireSpaceBeforeHeadingText) ? /^(#{1,6})[ \t]+(.+?)[ \t]*#*\n+/gm : /^(#{1,6})[ \t]*(.+?)[ \t]*#*\n+/gm;

  text = text.replace(atxStyle, function (wholeMatch, m1, m2) {
    var hText = m2;
    if (options.customizedHeaderId) {
      hText = m2.replace(/\s?\{([^{]+?)}\s*$/, '');
    }

    var span = showdown.subParser('spanGamut')(hText, options, globals),
        hID = (options.noHeaderId) ? '' : ' id="' + headerId(m2) + '"',
        hLevel = headerLevelStart - 1 + m1.length,
        header = '<h' + hLevel + hID + '>' + span + '</h' + hLevel + '>';

    return showdown.subParser('hashBlock')(header, options, globals);
  });

  function headerId (m) {
    var title,
        prefix;

    // It is separate from other options to allow combining prefix and customized
    if (options.customizedHeaderId) {
      var match = m.match(/\{([^{]+?)}\s*$/);
      if (match && match[1]) {
        m = match[1];
      }
    }

    title = m;

    // Prefix id to prevent causing inadvertent pre-existing style matches.
    if (showdown.helper.isString(options.prefixHeaderId)) {
      prefix = options.prefixHeaderId;
    } else if (options.prefixHeaderId === true) {
      prefix = 'section-';
    } else {
      prefix = '';
    }

    if (!options.rawPrefixHeaderId) {
      title = prefix + title;
    }

    if (options.ghCompatibleHeaderId) {
      title = title
        .replace(/ /g, '-')
        // replace previously escaped chars (&, ¨ and $)
        .replace(/&amp;/g, '')
        .replace(/¨T/g, '')
        .replace(/¨D/g, '')
        // replace rest of the chars (&~$ are repeated as they might have been escaped)
        // borrowed from github's redcarpet (some they should produce similar results)
        .replace(/[&+$,\/:;=?@"#{}|^¨~\[\]`\\*)(%.!'<>]/g, '')
        .toLowerCase();
    } else if (options.rawHeaderId) {
      title = title
        .replace(/ /g, '-')
        // replace previously escaped chars (&, ¨ and $)
        .replace(/&amp;/g, '&')
        .replace(/¨T/g, '¨')
        .replace(/¨D/g, '$')
        // replace " and '
        .replace(/["']/g, '-')
        .toLowerCase();
    } else {
      title = title
        .replace(/[^\w]/g, '')
        .toLowerCase();
    }

    if (options.rawPrefixHeaderId) {
      title = prefix + title;
    }

    if (globals.hashLinkCounts[title]) {
      title = title + '-' + (globals.hashLinkCounts[title]++);
    } else {
      globals.hashLinkCounts[title] = 1;
    }
    return title;
  }

  text = globals.converter._dispatch('headers.after', text, options, globals);
  return text;
});

/**
 * Turn Markdown link shortcuts into XHTML <a> tags.
 */
showdown.subParser('horizontalRule', function (text, options, globals) {
  'use strict';
  text = globals.converter._dispatch('horizontalRule.before', text, options, globals);

  var key = showdown.subParser('hashBlock')('<hr />', options, globals);
  text = text.replace(/^ {0,2}( ?-){3,}[ \t]*$/gm, key);
  text = text.replace(/^ {0,2}( ?\*){3,}[ \t]*$/gm, key);
  text = text.replace(/^ {0,2}( ?_){3,}[ \t]*$/gm, key);

  text = globals.converter._dispatch('horizontalRule.after', text, options, globals);
  return text;
});

/**
 * Turn Markdown image shortcuts into <img> tags.
 */
showdown.subParser('images', function (text, options, globals) {
  'use strict';

  text = globals.converter._dispatch('images.before', text, options, globals);

  var inlineRegExp      = /!\[([^\]]*?)][ \t]*()\([ \t]?<?([\S]+?(?:\([\S]*?\)[\S]*?)?)>?(?: =([*\d]+[A-Za-z%]{0,4})x([*\d]+[A-Za-z%]{0,4}))?[ \t]*(?:(["'])([^"]*?)\6)?[ \t]?\)/g,
      crazyRegExp       = /!\[([^\]]*?)][ \t]*()\([ \t]?<([^>]*)>(?: =([*\d]+[A-Za-z%]{0,4})x([*\d]+[A-Za-z%]{0,4}))?[ \t]*(?:(?:(["'])([^"]*?)\6))?[ \t]?\)/g,
      base64RegExp      = /!\[([^\]]*?)][ \t]*()\([ \t]?<?(data:.+?\/.+?;base64,[A-Za-z0-9+/=\n]+?)>?(?: =([*\d]+[A-Za-z%]{0,4})x([*\d]+[A-Za-z%]{0,4}))?[ \t]*(?:(["'])([^"]*?)\6)?[ \t]?\)/g,
      referenceRegExp   = /!\[([^\]]*?)] ?(?:\n *)?\[([\s\S]*?)]()()()()()/g,
      refShortcutRegExp = /!\[([^\[\]]+)]()()()()()/g;

  function writeImageTagBase64 (wholeMatch, altText, linkId, url, width, height, m5, title) {
    url = url.replace(/\s/g, '');
    return writeImageTag (wholeMatch, altText, linkId, url, width, height, m5, title);
  }

  function writeImageTag (wholeMatch, altText, linkId, url, width, height, m5, title) {

    var gUrls   = globals.gUrls,
        gTitles = globals.gTitles,
        gDims   = globals.gDimensions;

    linkId = linkId.toLowerCase();

    if (!title) {
      title = '';
    }
    // Special case for explicit empty url
    if (wholeMatch.search(/\(<?\s*>? ?(['"].*['"])?\)$/m) > -1) {
      url = '';

    } else if (url === '' || url === null) {
      if (linkId === '' || linkId === null) {
        // lower-case and turn embedded newlines into spaces
        linkId = altText.toLowerCase().replace(/ ?\n/g, ' ');
      }
      url = '#' + linkId;

      if (!showdown.helper.isUndefined(gUrls[linkId])) {
        url = gUrls[linkId];
        if (!showdown.helper.isUndefined(gTitles[linkId])) {
          title = gTitles[linkId];
        }
        if (!showdown.helper.isUndefined(gDims[linkId])) {
          width = gDims[linkId].width;
          height = gDims[linkId].height;
        }
      } else {
        return wholeMatch;
      }
    }

    altText = altText
      .replace(/"/g, '&quot;')
    //altText = showdown.helper.escapeCharacters(altText, '*_', false);
      .replace(showdown.helper.regexes.asteriskDashAndColon, showdown.helper.escapeCharactersCallback);
    //url = showdown.helper.escapeCharacters(url, '*_', false);
    url = url.replace(showdown.helper.regexes.asteriskDashAndColon, showdown.helper.escapeCharactersCallback);
    var result = '<img src="' + url + '" alt="' + altText + '"';

    if (title && showdown.helper.isString(title)) {
      title = title
        .replace(/"/g, '&quot;')
      //title = showdown.helper.escapeCharacters(title, '*_', false);
        .replace(showdown.helper.regexes.asteriskDashAndColon, showdown.helper.escapeCharactersCallback);
      result += ' title="' + title + '"';
    }

    if (width && height) {
      width  = (width === '*') ? 'auto' : width;
      height = (height === '*') ? 'auto' : height;

      result += ' width="' + width + '"';
      result += ' height="' + height + '"';
    }

    result += ' />';

    return result;
  }

  // First, handle reference-style labeled images: ![alt text][id]
  text = text.replace(referenceRegExp, writeImageTag);

  // Next, handle inline images:  ![alt text](url =<width>x<height> "optional title")

  // base64 encoded images
  text = text.replace(base64RegExp, writeImageTagBase64);

  // cases with crazy urls like ./image/cat1).png
  text = text.replace(crazyRegExp, writeImageTag);

  // normal cases
  text = text.replace(inlineRegExp, writeImageTag);

  // handle reference-style shortcuts: ![img text]
  text = text.replace(refShortcutRegExp, writeImageTag);

  text = globals.converter._dispatch('images.after', text, options, globals);
  return text;
});

showdown.subParser('italicsAndBold', function (text, options, globals) {
  'use strict';

  text = globals.converter._dispatch('italicsAndBold.before', text, options, globals);

  // it's faster to have 3 separate regexes for each case than have just one
  // because of backtracing, in some cases, it could lead to an exponential effect
  // called "catastrophic backtrace". Ominous!

  function parseInside (txt, left, right) {
    /*
    if (options.simplifiedAutoLink) {
      txt = showdown.subParser('simplifiedAutoLinks')(txt, options, globals);
    }
    */
    return left + txt + right;
  }

  // Parse underscores
  if (options.literalMidWordUnderscores) {
    text = text.replace(/\b___(\S[\s\S]*?)___\b/g, function (wm, txt) {
      return parseInside (txt, '<strong><em>', '</em></strong>');
    });
    text = text.replace(/\b__(\S[\s\S]*?)__\b/g, function (wm, txt) {
      return parseInside (txt, '<strong>', '</strong>');
    });
    text = text.replace(/\b_(\S[\s\S]*?)_\b/g, function (wm, txt) {
      return parseInside (txt, '<em>', '</em>');
    });
  } else {
    text = text.replace(/___(\S[\s\S]*?)___/g, function (wm, m) {
      return (/\S$/.test(m)) ? parseInside (m, '<strong><em>', '</em></strong>') : wm;
    });
    text = text.replace(/__(\S[\s\S]*?)__/g, function (wm, m) {
      return (/\S$/.test(m)) ? parseInside (m, '<strong>', '</strong>') : wm;
    });
    text = text.replace(/_([^\s_][\s\S]*?)_/g, function (wm, m) {
      // !/^_[^_]/.test(m) - test if it doesn't start with __ (since it seems redundant, we removed it)
      return (/\S$/.test(m)) ? parseInside (m, '<em>', '</em>') : wm;
    });
  }

  // Now parse asterisks
  if (options.literalMidWordAsterisks) {
    text = text.replace(/([^*]|^)\B\*\*\*(\S[\s\S]*?)\*\*\*\B(?!\*)/g, function (wm, lead, txt) {
      return parseInside (txt, lead + '<strong><em>', '</em></strong>');
    });
    text = text.replace(/([^*]|^)\B\*\*(\S[\s\S]*?)\*\*\B(?!\*)/g, function (wm, lead, txt) {
      return parseInside (txt, lead + '<strong>', '</strong>');
    });
    text = text.replace(/([^*]|^)\B\*(\S[\s\S]*?)\*\B(?!\*)/g, function (wm, lead, txt) {
      return parseInside (txt, lead + '<em>', '</em>');
    });
  } else {
    text = text.replace(/\*\*\*(\S[\s\S]*?)\*\*\*/g, function (wm, m) {
      return (/\S$/.test(m)) ? parseInside (m, '<strong><em>', '</em></strong>') : wm;
    });
    text = text.replace(/\*\*(\S[\s\S]*?)\*\*/g, function (wm, m) {
      return (/\S$/.test(m)) ? parseInside (m, '<strong>', '</strong>') : wm;
    });
    text = text.replace(/\*([^\s*][\s\S]*?)\*/g, function (wm, m) {
      // !/^\*[^*]/.test(m) - test if it doesn't start with ** (since it seems redundant, we removed it)
      return (/\S$/.test(m)) ? parseInside (m, '<em>', '</em>') : wm;
    });
  }


  text = globals.converter._dispatch('italicsAndBold.after', text, options, globals);
  return text;
});

/**
 * Form HTML ordered (numbered) and unordered (bulleted) lists.
 */
showdown.subParser('lists', function (text, options, globals) {
  'use strict';

  /**
   * Process the contents of a single ordered or unordered list, splitting it
   * into individual list items.
   * @param {string} listStr
   * @param {boolean} trimTrailing
   * @returns {string}
   */
  function processListItems (listStr, trimTrailing) {
    // The $g_list_level global keeps track of when we're inside a list.
    // Each time we enter a list, we increment it; when we leave a list,
    // we decrement. If it's zero, we're not in a list anymore.
    //
    // We do this because when we're not inside a list, we want to treat
    // something like this:
    //
    //    I recommend upgrading to version
    //    8. Oops, now this line is treated
    //    as a sub-list.
    //
    // As a single paragraph, despite the fact that the second line starts
    // with a digit-period-space sequence.
    //
    // Whereas when we're inside a list (or sub-list), that line will be
    // treated as the start of a sub-list. What a kludge, huh? This is
    // an aspect of Markdown's syntax that's hard to parse perfectly
    // without resorting to mind-reading. Perhaps the solution is to
    // change the syntax rules such that sub-lists must start with a
    // starting cardinal number; e.g. "1." or "a.".
    globals.gListLevel++;

    // trim trailing blank lines:
    listStr = listStr.replace(/\n{2,}$/, '\n');

    // attacklab: add sentinel to emulate \z
    listStr += '¨0';

    var rgx = /(\n)?(^ {0,3})([*+-]|\d+[.])[ \t]+((\[(x|X| )?])?[ \t]*[^\r]+?(\n{1,2}))(?=\n*(¨0| {0,3}([*+-]|\d+[.])[ \t]+))/gm,
        isParagraphed = (/\n[ \t]*\n(?!¨0)/.test(listStr));

    // Since version 1.5, nesting sublists requires 4 spaces (or 1 tab) indentation,
    // which is a syntax breaking change
    // activating this option reverts to old behavior
    if (options.disableForced4SpacesIndentedSublists) {
      rgx = /(\n)?(^ {0,3})([*+-]|\d+[.])[ \t]+((\[(x|X| )?])?[ \t]*[^\r]+?(\n{1,2}))(?=\n*(¨0|\2([*+-]|\d+[.])[ \t]+))/gm;
    }

    listStr = listStr.replace(rgx, function (wholeMatch, m1, m2, m3, m4, taskbtn, checked) {
      checked = (checked && checked.trim() !== '');

      var item = showdown.subParser('outdent')(m4, options, globals),
          bulletStyle = '';

      // Support for github tasklists
      if (taskbtn && options.tasklists) {
        bulletStyle = ' class="task-list-item" style="list-style-type: none;"';
        item = item.replace(/^[ \t]*\[(x|X| )?]/m, function () {
          var otp = '<input type="checkbox" disabled style="margin: 0px 0.35em 0.25em -1.6em; vertical-align: middle;"';
          if (checked) {
            otp += ' checked';
          }
          otp += '>';
          return otp;
        });
      }

      // ISSUE #312
      // This input: - - - a
      // causes trouble to the parser, since it interprets it as:
      // <ul><li><li><li>a</li></li></li></ul>
      // instead of:
      // <ul><li>- - a</li></ul>
      // So, to prevent it, we will put a marker (¨A)in the beginning of the line
      // Kind of hackish/monkey patching, but seems more effective than overcomplicating the list parser
      item = item.replace(/^([-*+]|\d\.)[ \t]+[\S\n ]*/g, function (wm2) {
        return '¨A' + wm2;
      });

      // m1 - Leading line or
      // Has a double return (multi paragraph) or
      // Has sublist
      if (m1 || (item.search(/\n{2,}/) > -1)) {
        item = showdown.subParser('githubCodeBlocks')(item, options, globals);
        item = showdown.subParser('blockGamut')(item, options, globals);
      } else {
        // Recursion for sub-lists:
        item = showdown.subParser('lists')(item, options, globals);
        item = item.replace(/\n$/, ''); // chomp(item)
        item = showdown.subParser('hashHTMLBlocks')(item, options, globals);

        // Colapse double linebreaks
        item = item.replace(/\n\n+/g, '\n\n');
        if (isParagraphed) {
          item = showdown.subParser('paragraphs')(item, options, globals);
        } else {
          item = showdown.subParser('spanGamut')(item, options, globals);
        }
      }

      // now we need to remove the marker (¨A)
      item = item.replace('¨A', '');
      // we can finally wrap the line in list item tags
      item =  '<li' + bulletStyle + '>' + item + '</li>\n';

      return item;
    });

    // attacklab: strip sentinel
    listStr = listStr.replace(/¨0/g, '');

    globals.gListLevel--;

    if (trimTrailing) {
      listStr = listStr.replace(/\s+$/, '');
    }

    return listStr;
  }

  function styleStartNumber (list, listType) {
    // check if ol and starts by a number different than 1
    if (listType === 'ol') {
      var res = list.match(/^ *(\d+)\./);
      if (res && res[1] !== '1') {
        return ' start="' + res[1] + '"';
      }
    }
    return '';
  }

  /**
   * Check and parse consecutive lists (better fix for issue #142)
   * @param {string} list
   * @param {string} listType
   * @param {boolean} trimTrailing
   * @returns {string}
   */
  function parseConsecutiveLists (list, listType, trimTrailing) {
    // check if we caught 2 or more consecutive lists by mistake
    // we use the counterRgx, meaning if listType is UL we look for OL and vice versa
    var olRgx = (options.disableForced4SpacesIndentedSublists) ? /^ ?\d+\.[ \t]/gm : /^ {0,3}\d+\.[ \t]/gm,
        ulRgx = (options.disableForced4SpacesIndentedSublists) ? /^ ?[*+-][ \t]/gm : /^ {0,3}[*+-][ \t]/gm,
        counterRxg = (listType === 'ul') ? olRgx : ulRgx,
        result = '';

    if (list.search(counterRxg) !== -1) {
      (function parseCL (txt) {
        var pos = txt.search(counterRxg),
            style = styleStartNumber(list, listType);
        if (pos !== -1) {
          // slice
          result += '\n\n<' + listType + style + '>\n' + processListItems(txt.slice(0, pos), !!trimTrailing) + '</' + listType + '>\n';

          // invert counterType and listType
          listType = (listType === 'ul') ? 'ol' : 'ul';
          counterRxg = (listType === 'ul') ? olRgx : ulRgx;

          //recurse
          parseCL(txt.slice(pos));
        } else {
          result += '\n\n<' + listType + style + '>\n' + processListItems(txt, !!trimTrailing) + '</' + listType + '>\n';
        }
      })(list);
    } else {
      var style = styleStartNumber(list, listType);
      result = '\n\n<' + listType + style + '>\n' + processListItems(list, !!trimTrailing) + '</' + listType + '>\n';
    }

    return result;
  }

  /** Start of list parsing **/
  text = globals.converter._dispatch('lists.before', text, options, globals);
  // add sentinel to hack around khtml/safari bug:
  // http://bugs.webkit.org/show_bug.cgi?id=11231
  text += '¨0';

  if (globals.gListLevel) {
    text = text.replace(/^(( {0,3}([*+-]|\d+[.])[ \t]+)[^\r]+?(¨0|\n{2,}(?=\S)(?![ \t]*(?:[*+-]|\d+[.])[ \t]+)))/gm,
      function (wholeMatch, list, m2) {
        var listType = (m2.search(/[*+-]/g) > -1) ? 'ul' : 'ol';
        return parseConsecutiveLists(list, listType, true);
      }
    );
  } else {
    text = text.replace(/(\n\n|^\n?)(( {0,3}([*+-]|\d+[.])[ \t]+)[^\r]+?(¨0|\n{2,}(?=\S)(?![ \t]*(?:[*+-]|\d+[.])[ \t]+)))/gm,
      function (wholeMatch, m1, list, m3) {
        var listType = (m3.search(/[*+-]/g) > -1) ? 'ul' : 'ol';
        return parseConsecutiveLists(list, listType, false);
      }
    );
  }

  // strip sentinel
  text = text.replace(/¨0/, '');
  text = globals.converter._dispatch('lists.after', text, options, globals);
  return text;
});

/**
 * Parse metadata at the top of the document
 */
showdown.subParser('metadata', function (text, options, globals) {
  'use strict';

  if (!options.metadata) {
    return text;
  }

  text = globals.converter._dispatch('metadata.before', text, options, globals);

  function parseMetadataContents (content) {
    // raw is raw so it's not changed in any way
    globals.metadata.raw = content;

    // escape chars forbidden in html attributes
    // double quotes
    content = content
      // ampersand first
      .replace(/&/g, '&amp;')
      // double quotes
      .replace(/"/g, '&quot;');

    content = content.replace(/\n {4}/g, ' ');
    content.replace(/^([\S ]+): +([\s\S]+?)$/gm, function (wm, key, value) {
      globals.metadata.parsed[key] = value;
      return '';
    });
  }

  text = text.replace(/^\s*«««+(\S*?)\n([\s\S]+?)\n»»»+\n/, function (wholematch, format, content) {
    parseMetadataContents(content);
    return '¨M';
  });

  text = text.replace(/^\s*---+(\S*?)\n([\s\S]+?)\n---+\n/, function (wholematch, format, content) {
    if (format) {
      globals.metadata.format = format;
    }
    parseMetadataContents(content);
    return '¨M';
  });

  text = text.replace(/¨M/g, '');

  text = globals.converter._dispatch('metadata.after', text, options, globals);
  return text;
});

/**
 * Remove one level of line-leading tabs or spaces
 */
showdown.subParser('outdent', function (text, options, globals) {
  'use strict';
  text = globals.converter._dispatch('outdent.before', text, options, globals);

  // attacklab: hack around Konqueror 3.5.4 bug:
  // "----------bug".replace(/^-/g,"") == "bug"
  text = text.replace(/^(\t|[ ]{1,4})/gm, '¨0'); // attacklab: g_tab_width

  // attacklab: clean up hack
  text = text.replace(/¨0/g, '');

  text = globals.converter._dispatch('outdent.after', text, options, globals);
  return text;
});

/**
 *
 */
showdown.subParser('paragraphs', function (text, options, globals) {
  'use strict';

  text = globals.converter._dispatch('paragraphs.before', text, options, globals);
  // Strip leading and trailing lines:
  text = text.replace(/^\n+/g, '');
  text = text.replace(/\n+$/g, '');

  var grafs = text.split(/\n{2,}/g),
      grafsOut = [],
      end = grafs.length; // Wrap <p> tags

  for (var i = 0; i < end; i++) {
    var str = grafs[i];
    // if this is an HTML marker, copy it
    if (str.search(/¨(K|G)(\d+)\1/g) >= 0) {
      grafsOut.push(str);

    // test for presence of characters to prevent empty lines being parsed
    // as paragraphs (resulting in undesired extra empty paragraphs)
    } else if (str.search(/\S/) >= 0) {
      str = showdown.subParser('spanGamut')(str, options, globals);
      str = str.replace(/^([ \t]*)/g, '<p>');
      str += '</p>';
      grafsOut.push(str);
    }
  }

  /** Unhashify HTML blocks */
  end = grafsOut.length;
  for (i = 0; i < end; i++) {
    var blockText = '',
        grafsOutIt = grafsOut[i],
        codeFlag = false;
    // if this is a marker for an html block...
    // use RegExp.test instead of string.search because of QML bug
    while (/¨(K|G)(\d+)\1/.test(grafsOutIt)) {
      var delim = RegExp.$1,
          num   = RegExp.$2;

      if (delim === 'K') {
        blockText = globals.gHtmlBlocks[num];
      } else {
        // we need to check if ghBlock is a false positive
        if (codeFlag) {
          // use encoded version of all text
          blockText = showdown.subParser('encodeCode')(globals.ghCodeBlocks[num].text, options, globals);
        } else {
          blockText = globals.ghCodeBlocks[num].codeblock;
        }
      }
      blockText = blockText.replace(/\$/g, '$$$$'); // Escape any dollar signs

      grafsOutIt = grafsOutIt.replace(/(\n\n)?¨(K|G)\d+\2(\n\n)?/, blockText);
      // Check if grafsOutIt is a pre->code
      if (/^<pre\b[^>]*>\s*<code\b[^>]*>/.test(grafsOutIt)) {
        codeFlag = true;
      }
    }
    grafsOut[i] = grafsOutIt;
  }
  text = grafsOut.join('\n');
  // Strip leading and trailing lines:
  text = text.replace(/^\n+/g, '');
  text = text.replace(/\n+$/g, '');
  return globals.converter._dispatch('paragraphs.after', text, options, globals);
});

/**
 * Run extension
 */
showdown.subParser('runExtension', function (ext, text, options, globals) {
  'use strict';

  if (ext.filter) {
    text = ext.filter(text, globals.converter, options);

  } else if (ext.regex) {
    // TODO remove this when old extension loading mechanism is deprecated
    var re = ext.regex;
    if (!(re instanceof RegExp)) {
      re = new RegExp(re, 'g');
    }
    text = text.replace(re, ext.replace);
  }

  return text;
});

/**
 * These are all the transformations that occur *within* block-level
 * tags like paragraphs, headers, and list items.
 */
showdown.subParser('spanGamut', function (text, options, globals) {
  'use strict';

  text = globals.converter._dispatch('spanGamut.before', text, options, globals);
  text = showdown.subParser('codeSpans')(text, options, globals);
  text = showdown.subParser('escapeSpecialCharsWithinTagAttributes')(text, options, globals);
  text = showdown.subParser('encodeBackslashEscapes')(text, options, globals);

  // Process anchor and image tags. Images must come first,
  // because ![foo][f] looks like an anchor.
  text = showdown.subParser('images')(text, options, globals);
  text = showdown.subParser('anchors')(text, options, globals);

  // Make links out of things like `<http://example.com/>`
  // Must come after anchors, because you can use < and >
  // delimiters in inline links like [this](<url>).
  text = showdown.subParser('autoLinks')(text, options, globals);
  text = showdown.subParser('simplifiedAutoLinks')(text, options, globals);
  text = showdown.subParser('emoji')(text, options, globals);
  text = showdown.subParser('underline')(text, options, globals);
  text = showdown.subParser('italicsAndBold')(text, options, globals);
  text = showdown.subParser('strikethrough')(text, options, globals);
  text = showdown.subParser('ellipsis')(text, options, globals);

  // we need to hash HTML tags inside spans
  text = showdown.subParser('hashHTMLSpans')(text, options, globals);

  // now we encode amps and angles
  text = showdown.subParser('encodeAmpsAndAngles')(text, options, globals);

  // Do hard breaks
  if (options.simpleLineBreaks) {
    // GFM style hard breaks
    // only add line breaks if the text does not contain a block (special case for lists)
    if (!/\n\n¨K/.test(text)) {
      text = text.replace(/\n+/g, '<br />\n');
    }
  } else {
    // Vanilla hard breaks
    text = text.replace(/  +\n/g, '<br />\n');
  }

  text = globals.converter._dispatch('spanGamut.after', text, options, globals);
  return text;
});

showdown.subParser('strikethrough', function (text, options, globals) {
  'use strict';

  function parseInside (txt) {
    if (options.simplifiedAutoLink) {
      txt = showdown.subParser('simplifiedAutoLinks')(txt, options, globals);
    }
    return '<del>' + txt + '</del>';
  }

  if (options.strikethrough) {
    text = globals.converter._dispatch('strikethrough.before', text, options, globals);
    text = text.replace(/(?:~){2}([\s\S]+?)(?:~){2}/g, function (wm, txt) { return parseInside(txt); });
    text = globals.converter._dispatch('strikethrough.after', text, options, globals);
  }

  return text;
});

/**
 * Strips link definitions from text, stores the URLs and titles in
 * hash references.
 * Link defs are in the form: ^[id]: url "optional title"
 */
showdown.subParser('stripLinkDefinitions', function (text, options, globals) {
  'use strict';

  var regex       = /^ {0,3}\[(.+)]:[ \t]*\n?[ \t]*<?([^>\s]+)>?(?: =([*\d]+[A-Za-z%]{0,4})x([*\d]+[A-Za-z%]{0,4}))?[ \t]*\n?[ \t]*(?:(\n*)["|'(](.+?)["|')][ \t]*)?(?:\n+|(?=¨0))/gm,
      base64Regex = /^ {0,3}\[(.+)]:[ \t]*\n?[ \t]*<?(data:.+?\/.+?;base64,[A-Za-z0-9+/=\n]+?)>?(?: =([*\d]+[A-Za-z%]{0,4})x([*\d]+[A-Za-z%]{0,4}))?[ \t]*\n?[ \t]*(?:(\n*)["|'(](.+?)["|')][ \t]*)?(?:\n\n|(?=¨0)|(?=\n\[))/gm;

  // attacklab: sentinel workarounds for lack of \A and \Z, safari\khtml bug
  text += '¨0';

  var replaceFunc = function (wholeMatch, linkId, url, width, height, blankLines, title) {
    linkId = linkId.toLowerCase();
    if (url.match(/^data:.+?\/.+?;base64,/)) {
      // remove newlines
      globals.gUrls[linkId] = url.replace(/\s/g, '');
    } else {
      globals.gUrls[linkId] = showdown.subParser('encodeAmpsAndAngles')(url, options, globals);  // Link IDs are case-insensitive
    }

    if (blankLines) {
      // Oops, found blank lines, so it's not a title.
      // Put back the parenthetical statement we stole.
      return blankLines + title;

    } else {
      if (title) {
        globals.gTitles[linkId] = title.replace(/"|'/g, '&quot;');
      }
      if (options.parseImgDimensions && width && height) {
        globals.gDimensions[linkId] = {
          width:  width,
          height: height
        };
      }
    }
    // Completely remove the definition from the text
    return '';
  };

  // first we try to find base64 link references
  text = text.replace(base64Regex, replaceFunc);

  text = text.replace(regex, replaceFunc);

  // attacklab: strip sentinel
  text = text.replace(/¨0/, '');

  return text;
});

showdown.subParser('tables', function (text, options, globals) {
  'use strict';

  if (!options.tables) {
    return text;
  }

  var tableRgx       = /^ {0,3}\|?.+\|.+\n {0,3}\|?[ \t]*:?[ \t]*(?:[-=]){2,}[ \t]*:?[ \t]*\|[ \t]*:?[ \t]*(?:[-=]){2,}[\s\S]+?(?:\n\n|¨0)/gm,
      //singeColTblRgx = /^ {0,3}\|.+\|\n {0,3}\|[ \t]*:?[ \t]*(?:[-=]){2,}[ \t]*:?[ \t]*\|[ \t]*\n(?: {0,3}\|.+\|\n)+(?:\n\n|¨0)/gm;
      singeColTblRgx = /^ {0,3}\|.+\|[ \t]*\n {0,3}\|[ \t]*:?[ \t]*(?:[-=]){2,}[ \t]*:?[ \t]*\|[ \t]*\n( {0,3}\|.+\|[ \t]*\n)*(?:\n|¨0)/gm;

  function parseStyles (sLine) {
    if (/^:[ \t]*--*$/.test(sLine)) {
      return ' style="text-align:left;"';
    } else if (/^--*[ \t]*:[ \t]*$/.test(sLine)) {
      return ' style="text-align:right;"';
    } else if (/^:[ \t]*--*[ \t]*:$/.test(sLine)) {
      return ' style="text-align:center;"';
    } else {
      return '';
    }
  }

  function parseHeaders (header, style) {
    var id = '';
    header = header.trim();
    // support both tablesHeaderId and tableHeaderId due to error in documentation so we don't break backwards compatibility
    if (options.tablesHeaderId || options.tableHeaderId) {
      id = ' id="' + header.replace(/ /g, '_').toLowerCase() + '"';
    }
    header = showdown.subParser('spanGamut')(header, options, globals);

    return '<th' + id + style + '>' + header + '</th>\n';
  }

  function parseCells (cell, style) {
    var subText = showdown.subParser('spanGamut')(cell, options, globals);
    return '<td' + style + '>' + subText + '</td>\n';
  }

  function buildTable (headers, cells) {
    var tb = '<table>\n<thead>\n<tr>\n',
        tblLgn = headers.length;

    for (var i = 0; i < tblLgn; ++i) {
      tb += headers[i];
    }
    tb += '</tr>\n</thead>\n<tbody>\n';

    for (i = 0; i < cells.length; ++i) {
      tb += '<tr>\n';
      for (var ii = 0; ii < tblLgn; ++ii) {
        tb += cells[i][ii];
      }
      tb += '</tr>\n';
    }
    tb += '</tbody>\n</table>\n';
    return tb;
  }

  function parseTable (rawTable) {
    var i, tableLines = rawTable.split('\n');

    for (i = 0; i < tableLines.length; ++i) {
      // strip wrong first and last column if wrapped tables are used
      if (/^ {0,3}\|/.test(tableLines[i])) {
        tableLines[i] = tableLines[i].replace(/^ {0,3}\|/, '');
      }
      if (/\|[ \t]*$/.test(tableLines[i])) {
        tableLines[i] = tableLines[i].replace(/\|[ \t]*$/, '');
      }
      // parse code spans first, but we only support one line code spans
      tableLines[i] = showdown.subParser('codeSpans')(tableLines[i], options, globals);
    }

    var rawHeaders = tableLines[0].split('|').map(function (s) { return s.trim();}),
        rawStyles = tableLines[1].split('|').map(function (s) { return s.trim();}),
        rawCells = [],
        headers = [],
        styles = [],
        cells = [];

    tableLines.shift();
    tableLines.shift();

    for (i = 0; i < tableLines.length; ++i) {
      if (tableLines[i].trim() === '') {
        continue;
      }
      rawCells.push(
        tableLines[i]
          .split('|')
          .map(function (s) {
            return s.trim();
          })
      );
    }

    if (rawHeaders.length < rawStyles.length) {
      return rawTable;
    }

    for (i = 0; i < rawStyles.length; ++i) {
      styles.push(parseStyles(rawStyles[i]));
    }

    for (i = 0; i < rawHeaders.length; ++i) {
      if (showdown.helper.isUndefined(styles[i])) {
        styles[i] = '';
      }
      headers.push(parseHeaders(rawHeaders[i], styles[i]));
    }

    for (i = 0; i < rawCells.length; ++i) {
      var row = [];
      for (var ii = 0; ii < headers.length; ++ii) {
        if (showdown.helper.isUndefined(rawCells[i][ii])) {

        }
        row.push(parseCells(rawCells[i][ii], styles[ii]));
      }
      cells.push(row);
    }

    return buildTable(headers, cells);
  }

  text = globals.converter._dispatch('tables.before', text, options, globals);

  // find escaped pipe characters
  text = text.replace(/\\(\|)/g, showdown.helper.escapeCharactersCallback);

  // parse multi column tables
  text = text.replace(tableRgx, parseTable);

  // parse one column tables
  text = text.replace(singeColTblRgx, parseTable);

  text = globals.converter._dispatch('tables.after', text, options, globals);

  return text;
});

showdown.subParser('underline', function (text, options, globals) {
  'use strict';

  if (!options.underline) {
    return text;
  }

  text = globals.converter._dispatch('underline.before', text, options, globals);

  if (options.literalMidWordUnderscores) {
    text = text.replace(/\b___(\S[\s\S]*?)___\b/g, function (wm, txt) {
      return '<u>' + txt + '</u>';
    });
    text = text.replace(/\b__(\S[\s\S]*?)__\b/g, function (wm, txt) {
      return '<u>' + txt + '</u>';
    });
  } else {
    text = text.replace(/___(\S[\s\S]*?)___/g, function (wm, m) {
      return (/\S$/.test(m)) ? '<u>' + m + '</u>' : wm;
    });
    text = text.replace(/__(\S[\s\S]*?)__/g, function (wm, m) {
      return (/\S$/.test(m)) ? '<u>' + m + '</u>' : wm;
    });
  }

  // escape remaining underscores to prevent them being parsed by italic and bold
  text = text.replace(/(_)/g, showdown.helper.escapeCharactersCallback);

  text = globals.converter._dispatch('underline.after', text, options, globals);

  return text;
});

/**
 * Swap back in all the special characters we've hidden.
 */
showdown.subParser('unescapeSpecialChars', function (text, options, globals) {
  'use strict';
  text = globals.converter._dispatch('unescapeSpecialChars.before', text, options, globals);

  text = text.replace(/¨E(\d+)E/g, function (wholeMatch, m1) {
    var charCodeToReplace = parseInt(m1);
    return String.fromCharCode(charCodeToReplace);
  });

  text = globals.converter._dispatch('unescapeSpecialChars.after', text, options, globals);
  return text;
});

showdown.subParser('makeMarkdown.blockquote', function (node, globals) {
  'use strict';

  var txt = '';
  if (node.hasChildNodes()) {
    var children = node.childNodes,
        childrenLength = children.length;

    for (var i = 0; i < childrenLength; ++i) {
      var innerTxt = showdown.subParser('makeMarkdown.node')(children[i], globals);

      if (innerTxt === '') {
        continue;
      }
      txt += innerTxt;
    }
  }
  // cleanup
  txt = txt.trim();
  txt = '> ' + txt.split('\n').join('\n> ');
  return txt;
});

showdown.subParser('makeMarkdown.codeBlock', function (node, globals) {
  'use strict';

  var lang = node.getAttribute('language'),
      num  = node.getAttribute('precodenum');
  return '```' + lang + '\n' + globals.preList[num] + '\n```';
});

showdown.subParser('makeMarkdown.codeSpan', function (node) {
  'use strict';

  return '`' + node.innerHTML + '`';
});

showdown.subParser('makeMarkdown.emphasis', function (node, globals) {
  'use strict';

  var txt = '';
  if (node.hasChildNodes()) {
    txt += '*';
    var children = node.childNodes,
        childrenLength = children.length;
    for (var i = 0; i < childrenLength; ++i) {
      txt += showdown.subParser('makeMarkdown.node')(children[i], globals);
    }
    txt += '*';
  }
  return txt;
});

showdown.subParser('makeMarkdown.header', function (node, globals, headerLevel) {
  'use strict';

  var headerMark = new Array(headerLevel + 1).join('#'),
      txt = '';

  if (node.hasChildNodes()) {
    txt = headerMark + ' ';
    var children = node.childNodes,
        childrenLength = children.length;

    for (var i = 0; i < childrenLength; ++i) {
      txt += showdown.subParser('makeMarkdown.node')(children[i], globals);
    }
  }
  return txt;
});

showdown.subParser('makeMarkdown.hr', function () {
  'use strict';

  return '---';
});

showdown.subParser('makeMarkdown.image', function (node) {
  'use strict';

  var txt = '';
  if (node.hasAttribute('src')) {
    txt += '![' + node.getAttribute('alt') + '](';
    txt += '<' + node.getAttribute('src') + '>';
    if (node.hasAttribute('width') && node.hasAttribute('height')) {
      txt += ' =' + node.getAttribute('width') + 'x' + node.getAttribute('height');
    }

    if (node.hasAttribute('title')) {
      txt += ' "' + node.getAttribute('title') + '"';
    }
    txt += ')';
  }
  return txt;
});

showdown.subParser('makeMarkdown.links', function (node, globals) {
  'use strict';

  var txt = '';
  if (node.hasChildNodes() && node.hasAttribute('href')) {
    var children = node.childNodes,
        childrenLength = children.length;
    txt = '[';
    for (var i = 0; i < childrenLength; ++i) {
      txt += showdown.subParser('makeMarkdown.node')(children[i], globals);
    }
    txt += '](';
    txt += '<' + node.getAttribute('href') + '>';
    if (node.hasAttribute('title')) {
      txt += ' "' + node.getAttribute('title') + '"';
    }
    txt += ')';
  }
  return txt;
});

showdown.subParser('makeMarkdown.list', function (node, globals, type) {
  'use strict';

  var txt = '';
  if (!node.hasChildNodes()) {
    return '';
  }
  var listItems       = node.childNodes,
      listItemsLenght = listItems.length,
      listNum = node.getAttribute('start') || 1;

  for (var i = 0; i < listItemsLenght; ++i) {
    if (typeof listItems[i].tagName === 'undefined' || listItems[i].tagName.toLowerCase() !== 'li') {
      continue;
    }

    // define the bullet to use in list
    var bullet = '';
    if (type === 'ol') {
      bullet = listNum.toString() + '. ';
    } else {
      bullet = '- ';
    }

    // parse list item
    txt += bullet + showdown.subParser('makeMarkdown.listItem')(listItems[i], globals);
    ++listNum;
  }

  // add comment at the end to prevent consecutive lists to be parsed as one
  txt += '\n<!-- -->\n';
  return txt.trim();
});

showdown.subParser('makeMarkdown.listItem', function (node, globals) {
  'use strict';

  var listItemTxt = '';

  var children = node.childNodes,
      childrenLenght = children.length;

  for (var i = 0; i < childrenLenght; ++i) {
    listItemTxt += showdown.subParser('makeMarkdown.node')(children[i], globals);
  }
  // if it's only one liner, we need to add a newline at the end
  if (!/\n$/.test(listItemTxt)) {
    listItemTxt += '\n';
  } else {
    // it's multiparagraph, so we need to indent
    listItemTxt = listItemTxt
      .split('\n')
      .join('\n    ')
      .replace(/^ {4}$/gm, '')
      .replace(/\n\n+/g, '\n\n');
  }

  return listItemTxt;
});



showdown.subParser('makeMarkdown.node', function (node, globals, spansOnly) {
  'use strict';

  spansOnly = spansOnly || false;

  var txt = '';

  // edge case of text without wrapper paragraph
  if (node.nodeType === 3) {
    return showdown.subParser('makeMarkdown.txt')(node, globals);
  }

  // HTML comment
  if (node.nodeType === 8) {
    return '<!--' + node.data + '-->\n\n';
  }

  // process only node elements
  if (node.nodeType !== 1) {
    return '';
  }

  var tagName = node.tagName.toLowerCase();

  switch (tagName) {

    //
    // BLOCKS
    //
    case 'h1':
      if (!spansOnly) { txt = showdown.subParser('makeMarkdown.header')(node, globals, 1) + '\n\n'; }
      break;
    case 'h2':
      if (!spansOnly) { txt = showdown.subParser('makeMarkdown.header')(node, globals, 2) + '\n\n'; }
      break;
    case 'h3':
      if (!spansOnly) { txt = showdown.subParser('makeMarkdown.header')(node, globals, 3) + '\n\n'; }
      break;
    case 'h4':
      if (!spansOnly) { txt = showdown.subParser('makeMarkdown.header')(node, globals, 4) + '\n\n'; }
      break;
    case 'h5':
      if (!spansOnly) { txt = showdown.subParser('makeMarkdown.header')(node, globals, 5) + '\n\n'; }
      break;
    case 'h6':
      if (!spansOnly) { txt = showdown.subParser('makeMarkdown.header')(node, globals, 6) + '\n\n'; }
      break;

    case 'p':
      if (!spansOnly) { txt = showdown.subParser('makeMarkdown.paragraph')(node, globals) + '\n\n'; }
      break;

    case 'blockquote':
      if (!spansOnly) { txt = showdown.subParser('makeMarkdown.blockquote')(node, globals) + '\n\n'; }
      break;

    case 'hr':
      if (!spansOnly) { txt = showdown.subParser('makeMarkdown.hr')(node, globals) + '\n\n'; }
      break;

    case 'ol':
      if (!spansOnly) { txt = showdown.subParser('makeMarkdown.list')(node, globals, 'ol') + '\n\n'; }
      break;

    case 'ul':
      if (!spansOnly) { txt = showdown.subParser('makeMarkdown.list')(node, globals, 'ul') + '\n\n'; }
      break;

    case 'precode':
      if (!spansOnly) { txt = showdown.subParser('makeMarkdown.codeBlock')(node, globals) + '\n\n'; }
      break;

    case 'pre':
      if (!spansOnly) { txt = showdown.subParser('makeMarkdown.pre')(node, globals) + '\n\n'; }
      break;

    case 'table':
      if (!spansOnly) { txt = showdown.subParser('makeMarkdown.table')(node, globals) + '\n\n'; }
      break;

    //
    // SPANS
    //
    case 'code':
      txt = showdown.subParser('makeMarkdown.codeSpan')(node, globals);
      break;

    case 'em':
    case 'i':
      txt = showdown.subParser('makeMarkdown.emphasis')(node, globals);
      break;

    case 'strong':
    case 'b':
      txt = showdown.subParser('makeMarkdown.strong')(node, globals);
      break;

    case 'del':
      txt = showdown.subParser('makeMarkdown.strikethrough')(node, globals);
      break;

    case 'a':
      txt = showdown.subParser('makeMarkdown.links')(node, globals);
      break;

    case 'img':
      txt = showdown.subParser('makeMarkdown.image')(node, globals);
      break;

    default:
      txt = node.outerHTML + '\n\n';
  }

  // common normalization
  // TODO eventually

  return txt;
});

showdown.subParser('makeMarkdown.paragraph', function (node, globals) {
  'use strict';

  var txt = '';
  if (node.hasChildNodes()) {
    var children = node.childNodes,
        childrenLength = children.length;
    for (var i = 0; i < childrenLength; ++i) {
      txt += showdown.subParser('makeMarkdown.node')(children[i], globals);
    }
  }

  // some text normalization
  txt = txt.trim();

  return txt;
});

showdown.subParser('makeMarkdown.pre', function (node, globals) {
  'use strict';

  var num  = node.getAttribute('prenum');
  return '<pre>' + globals.preList[num] + '</pre>';
});

showdown.subParser('makeMarkdown.strikethrough', function (node, globals) {
  'use strict';

  var txt = '';
  if (node.hasChildNodes()) {
    txt += '~~';
    var children = node.childNodes,
        childrenLength = children.length;
    for (var i = 0; i < childrenLength; ++i) {
      txt += showdown.subParser('makeMarkdown.node')(children[i], globals);
    }
    txt += '~~';
  }
  return txt;
});

showdown.subParser('makeMarkdown.strong', function (node, globals) {
  'use strict';

  var txt = '';
  if (node.hasChildNodes()) {
    txt += '**';
    var children = node.childNodes,
        childrenLength = children.length;
    for (var i = 0; i < childrenLength; ++i) {
      txt += showdown.subParser('makeMarkdown.node')(children[i], globals);
    }
    txt += '**';
  }
  return txt;
});

showdown.subParser('makeMarkdown.table', function (node, globals) {
  'use strict';

  var txt = '',
      tableArray = [[], []],
      headings   = node.querySelectorAll('thead>tr>th'),
      rows       = node.querySelectorAll('tbody>tr'),
      i, ii;
  for (i = 0; i < headings.length; ++i) {
    var headContent = showdown.subParser('makeMarkdown.tableCell')(headings[i], globals),
        allign = '---';

    if (headings[i].hasAttribute('style')) {
      var style = headings[i].getAttribute('style').toLowerCase().replace(/\s/g, '');
      switch (style) {
        case 'text-align:left;':
          allign = ':---';
          break;
        case 'text-align:right;':
          allign = '---:';
          break;
        case 'text-align:center;':
          allign = ':---:';
          break;
      }
    }
    tableArray[0][i] = headContent.trim();
    tableArray[1][i] = allign;
  }

  for (i = 0; i < rows.length; ++i) {
    var r = tableArray.push([]) - 1,
        cols = rows[i].getElementsByTagName('td');

    for (ii = 0; ii < headings.length; ++ii) {
      var cellContent = ' ';
      if (typeof cols[ii] !== 'undefined') {
        cellContent = showdown.subParser('makeMarkdown.tableCell')(cols[ii], globals);
      }
      tableArray[r].push(cellContent);
    }
  }

  var cellSpacesCount = 3;
  for (i = 0; i < tableArray.length; ++i) {
    for (ii = 0; ii < tableArray[i].length; ++ii) {
      var strLen = tableArray[i][ii].length;
      if (strLen > cellSpacesCount) {
        cellSpacesCount = strLen;
      }
    }
  }

  for (i = 0; i < tableArray.length; ++i) {
    for (ii = 0; ii < tableArray[i].length; ++ii) {
      if (i === 1) {
        if (tableArray[i][ii].slice(-1) === ':') {
          tableArray[i][ii] = showdown.helper.padEnd(tableArray[i][ii].slice(-1), cellSpacesCount - 1, '-') + ':';
        } else {
          tableArray[i][ii] = showdown.helper.padEnd(tableArray[i][ii], cellSpacesCount, '-');
        }
      } else {
        tableArray[i][ii] = showdown.helper.padEnd(tableArray[i][ii], cellSpacesCount);
      }
    }
    txt += '| ' + tableArray[i].join(' | ') + ' |\n';
  }

  return txt.trim();
});

showdown.subParser('makeMarkdown.tableCell', function (node, globals) {
  'use strict';

  var txt = '';
  if (!node.hasChildNodes()) {
    return '';
  }
  var children = node.childNodes,
      childrenLength = children.length;

  for (var i = 0; i < childrenLength; ++i) {
    txt += showdown.subParser('makeMarkdown.node')(children[i], globals, true);
  }
  return txt.trim();
});

showdown.subParser('makeMarkdown.txt', function (node) {
  'use strict';

  var txt = node.nodeValue;

  // multiple spaces are collapsed
  txt = txt.replace(/ +/g, ' ');

  // replace the custom ¨NBSP; with a space
  txt = txt.replace(/¨NBSP;/g, ' ');

  // ", <, > and & should replace escaped html entities
  txt = showdown.helper.unescapeHTMLEntities(txt);

  // escape markdown magic characters
  // emphasis, strong and strikethrough - can appear everywhere
  // we also escape pipe (|) because of tables
  // and escape ` because of code blocks and spans
  txt = txt.replace(/([*_~|`])/g, '\\$1');

  // escape > because of blockquotes
  txt = txt.replace(/^(\s*)>/g, '\\$1>');

  // hash character, only troublesome at the beginning of a line because of headers
  txt = txt.replace(/^#/gm, '\\#');

  // horizontal rules
  txt = txt.replace(/^(\s*)([-=]{3,})(\s*)$/, '$1\\$2$3');

  // dot, because of ordered lists, only troublesome at the beginning of a line when preceded by an integer
  txt = txt.replace(/^( {0,3}\d+)\./gm, '$1\\.');

  // +, * and -, at the beginning of a line becomes a list, so we need to escape them also (asterisk was already escaped)
  txt = txt.replace(/^( {0,3})([+-])/gm, '$1\\$2');

  // images and links, ] followed by ( is problematic, so we escape it
  txt = txt.replace(/]([\s]*)\(/g, '\\]$1\\(');

  // reference URIs must also be escaped
  txt = txt.replace(/^ {0,3}\[([\S \t]*?)]:/gm, '\\[$1]:');

  return txt;
});

var root = this;

// AMD Loader
if (true) {
  !(__WEBPACK_AMD_DEFINE_RESULT__ = (function () {
    'use strict';
    return showdown;
  }).call(exports, __webpack_require__, exports, module),
				__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));

// CommonJS/nodeJS Loader
} else {}
}).call(this);

//# sourceMappingURL=showdown.js.map


/***/ }),
/* 111 */
/***/ (function(module, exports, __webpack_require__) {

module.exports = __webpack_require__(354);


/***/ }),
/* 112 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(113);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 113 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ":root {\n    --punctured-x: 0px;\n    --punctured-y: 0px;\n    --punctured-width: 100vw;\n    --punctured-height: 100vh;\n}\n\n\n.atr-punctured-modal {\n    position: fixed;\n    z-index: 200000000;\n    background-color: inherit;\n}\n\n.atr-punctured-modal.as-non-interact {\n    pointer-events: none;\n}\n\n.atr-punctured-modal.as-transparent {\n    opacity: 0;\n}\n\n.atr-punctured-modal.as-hidden {\n    visibility: hidden;\n}\n\n.atr-punctured-modal.as-animation {\n    transition: opacity 0.2s;\n}\n\n\n.atr-punctured-modal-a {\n    left: 0;\n    top: 0;\n    width: calc(var(--punctured-x) + var(--punctured-width));\n    height: var(--punctured-y);\n}\n\n\n.atr-punctured-modal.as-animation .atr-punctured-modal-a {\n    transition: width 0.2s, height 0.2s;\n}\n\n\n.atr-punctured-modal-b {\n    right: 0;\n    top: 0;\n    left: calc(var(--punctured-x) + var(--punctured-width));\n    height: calc(var(--punctured-y) + var(--punctured-height));\n}\n\n.atr-punctured-modal.as-animation .atr-punctured-modal-b {\n    transition: left 0.2s, height 0.2s;\n}\n\n.atr-punctured-modal-c {\n    right: 0;\n    bottom: 0;\n    top: calc(var(--punctured-y) + var(--punctured-height));\n    left: var(--punctured-x);\n}\n\n\n.atr-punctured-modal.as-animation .atr-punctured-modal-c {\n    transition: top 0.2s, left 0.2s;\n}\n\n.atr-punctured-modal-d {\n    left: 0;\n    bottom: 0;\n    width: var(--punctured-x);\n    top: var(--punctured-y);\n}\n\n.atr-punctured-modal.as-animation .atr-punctured-modal-d {\n    transition: top 0.2s, width 0.2s;\n}\n\n\n.atr-punctured-modal > :not(.atr-punctured-modal) {\n    pointer-events: none;\n}", ""]);



/***/ }),
/* 114 */
/***/ (function(module, exports) {


/**
 * When source maps are enabled, `style-loader` uses a link element with a data-uri to
 * embed the css on the page. This breaks all relative urls because now they are relative to a
 * bundle instead of the current page.
 *
 * One solution is to only use full urls, but that may be impossible.
 *
 * Instead, this function "fixes" the relative urls to be absolute according to the current page location.
 *
 * A rudimentary test suite is located at `test/fixUrls.js` and can be run via the `npm test` command.
 *
 */

module.exports = function (css) {
  // get current location
  var location = typeof window !== "undefined" && window.location;

  if (!location) {
    throw new Error("fixUrls requires window.location");
  }

	// blank or null?
	if (!css || typeof css !== "string") {
	  return css;
  }

  var baseUrl = location.protocol + "//" + location.host;
  var currentDir = baseUrl + location.pathname.replace(/\/[^\/]*$/, "/");

	// convert each url(...)
	/*
	This regular expression is just a way to recursively match brackets within
	a string.

	 /url\s*\(  = Match on the word "url" with any whitespace after it and then a parens
	   (  = Start a capturing group
	     (?:  = Start a non-capturing group
	         [^)(]  = Match anything that isn't a parentheses
	         |  = OR
	         \(  = Match a start parentheses
	             (?:  = Start another non-capturing groups
	                 [^)(]+  = Match anything that isn't a parentheses
	                 |  = OR
	                 \(  = Match a start parentheses
	                     [^)(]*  = Match anything that isn't a parentheses
	                 \)  = Match a end parentheses
	             )  = End Group
              *\) = Match anything and then a close parens
          )  = Close non-capturing group
          *  = Match anything
       )  = Close capturing group
	 \)  = Match a close parens

	 /gi  = Get all matches, not the first.  Be case insensitive.
	 */
	var fixedCss = css.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi, function(fullMatch, origUrl) {
		// strip quotes (if they exist)
		var unquotedOrigUrl = origUrl
			.trim()
			.replace(/^"(.*)"$/, function(o, $1){ return $1; })
			.replace(/^'(.*)'$/, function(o, $1){ return $1; });

		// already a full url? no change
		if (/^(#|data:|http:\/\/|https:\/\/|file:\/\/\/|\s*$)/i.test(unquotedOrigUrl)) {
		  return fullMatch;
		}

		// convert the url to a full url
		var newUrl;

		if (unquotedOrigUrl.indexOf("//") === 0) {
		  	//TODO: should we add protocol?
			newUrl = unquotedOrigUrl;
		} else if (unquotedOrigUrl.indexOf("/") === 0) {
			// path should be relative to the base url
			newUrl = baseUrl + unquotedOrigUrl; // already starts with '/'
		} else {
			// path should be relative to current directory
			newUrl = currentDir + unquotedOrigUrl.replace(/^\.\//, ""); // Strip leading './'
		}

		// send back the fixed url(...)
		return "url(" + JSON.stringify(newUrl) + ")";
	});

	// send back the fixed css
	return fixedCss;
};


/***/ }),
/* 115 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(116);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 116 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-autocomplete-input {\n    display: inline-block;\n    position: relative;\n    box-sizing: border-box;\n    border: solid 1px #d6d6d6;\n}\n\n.absol-autocomplete-input.absol-disabled {\n    pointer-events: none;\n    color: rgb(84, 84, 84);\n    background-color: rgb(235, 235, 228);\n}\n\n.absol-autocomplete-input>input {\n    min-width: 100%;\n    min-height: 100%;\n    box-sizing: border-box;\n    background-color: transparent;\n    border: none;\n}\n\n\n.absol-autocomplete-input-dropdown {\n    position: absolute;\n    left: 0;\n    top: 100%;\n    min-width: 100%;\n    z-index: 1005;\n    border: solid 1px rgb(169, 169, 169);\n    box-sizing: border-box;\n    background-color: white;\n}\n\n.absol-autocomplete-input-dropdown .as-bscroller{\n    overflow-y: auto;\n}\n\n.absol-autocomplete-input-dropdown.top {\n    top: auto;\n    bottom: 100%;\n}\n\n.absol-autocomplete-input-item {\n    height: 30px;\n}\n\n.absol-autocomplete-input-item:hover {\n    background-color: rgba(169, 169, 169, 0.18605);\n    cursor: pointer;\n}\n\n.absol-autocomplete-input-item.active,\n.absol-autocomplete-input-item.active:hover {\n    background-color: rgba(169, 169, 169, 0.37209);\n}\n\n.absol-autocomplete-input-item-text {\n    line-height: 30px;\n    margin-left: 5px;\n    margin-right: 5px;\n}", ""]);



/***/ }),
/* 117 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(118);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 118 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ":root {\n    --as-input-height: 30px;\n    --as-input-font-size: 14px;\n    --as-input-font-family: Arial, Helvetica, sans-serif;\n    --as-input-vertical-padding: 0.3571em;\n    --as-input-horizontal-padding: 0.5em;\n    --as-context-menu-font-size: 14px;\n    --as-context-font-family: Arial, Helvetica, sans-serif;\n    --as-disabled-background-color: #ebebe4;\n    --as-disabled-text-color: rgb(102, 102, 102);\n    --icon-background-cover-hover: #91e4fb;\n    --as-transparent-button-hover-color: rgba(169, 169, 172, 0.1);\n    --as-transparent-button-focus-color:  rgba(20, 185, 235, 0.3);\n    --as-transparent-button-active-color:  rgba(169, 169, 172, 0.2);\n    --as-transparent-button-text-color: rgb(139, 139, 140);\n    --as-transparent-button-text-hover-color: rgb(107, 107, 107);\n    --as-transparent-button-text-active-color: rgb(0, 0, 0);\n\n}\n\n", ""]);



/***/ }),
/* 119 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-has-board-table-drag,\n.as-has-board-table-drag * {\n    cursor: grabbing;\n    -webkit-user-select: none !important;\n    -moz-user-select: none !important;\n    -ms-user-select: none !important;\n    user-select: none !important;\n}\n\n\n\n.as-board-table {\n    overflow: visible;\n    position: relative;\n\n}\n\n.as-board-drag-zone {\n    -webkit-user-select: none !important;\n    -moz-user-select: none !important;\n    -ms-user-select: none !important;\n    user-select: none !important;\n}\n\n\n.as-board {\n    white-space: normal;\n    box-sizing: border-box;\n    position: relative;\n    vertical-align: middle;\n}\n\n/**\nBug note: don't put fixed position element to a element which has transform\n */\n.as-board-moving {\n    transform-origin: 30% 55%;\n    transform: rotate(5deg);\n    transition: transform 0.05s;\n    user-select: none;\n    pointer-events: none;\n    position: fixed !important;\n    z-index: 2000;\n}\n\n\n.as-board-place-holder {\n    opacity: 0.3;\n}\n\n.as-board-table-prevent-context {\n    position: fixed;\n    --x: -10000px;\n    --y: -10000px;\n    left: calc(var(--x) - 100px);\n    top: calc(var(--y) - 100px);\n    opacity: 0;\n    z-index: 100000000;\n    width: 200px;\n    height: 200px;\n    cursor: default;\n    -webkit-user-select: none;\n    -webkit-touch-callout: none;\n    -khtml-user-select: none;\n    -moz-user-select: none;\n    -ms-user-select: none;\n    -o-user-select: none;\n}", ""]);



/***/ }),
/* 120 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(121);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 121 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-has-hanger-drag,\n.as-has-hanger-drag * {\n    touch-action: none;\n    -webkit-user-select: none !important;\n    -moz-user-select: none !important;\n    -ms-user-select: none !important;\n    user-select: none !important;\n}", ""]);



/***/ }),
/* 122 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(123);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 123 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, "/* OLD module */\n\n.absol-bscroller {\n    scrollbar-width: thin;\n    scrollbar-color: rgba(151, 151, 151, 0.4) rgba(220, 220, 220, 0.4);\n    overflow: auto;\n}\n\n\n.absol-bscroller::-webkit-scrollbar {\n    width: 6px;\n    height: 6px;\n}\n\n.absol-bscroller::-webkit-scrollbar-track {\n    background: rgba(220, 220, 220, 0.4);\n}\n\n.absol-bscroller::-webkit-scrollbar-thumb {\n    background: rgba(182, 182, 182, 0.4);\n}\n\n.absol-bscroller::-webkit-scrollbar-thumb:hover {\n    background: rgba(32, 32, 32, 0.4);\n}\n\n.absol-bscroller::-webkit-scrollbar-thumb:active {\n    background: rgba(13, 13, 13, 0.6);\n}\n\n.absol-bscroller.dark,\n.dark .absol-bscroller {\n    scrollbar-color: rgba(104, 104, 104, 0.4) rgba(35, 35, 35, 0.4);\n}\n\n\n.absol-bscroller.dark::-webkit-scrollbar-track,\n.dark .absol-bscroller::-webkit-scrollbar-track {\n    background: rgba(35, 35, 35, 0.4);\n}\n\n.absol-bscroller.dark::-webkit-scrollbar-thumb,\n.dark .absol-bscroller::-webkit-scrollbar-thumb {\n    background: rgba(73, 73, 73, 0.4);\n}\n\n.absol-bscroller.dark::-webkit-scrollbar-thumb:hover,\n.dark .absol-bscroller::-webkit-scrollbar-thumb:hover {\n    background: rgba(223, 223, 223, 0.4);\n}\n\n.absol-bscroller.dark::-webkit-scrollbar-thumb:active,\n.dark .absol-bscroller::-webkit-scrollbar-thumb:active {\n    background: rgba(242, 242, 242, 0.6);\n}\n\n/*******************************************/\n.as-bscroller {\n    scrollbar-width: thin;\n    scrollbar-color: rgba(151, 151, 151, 0.4) rgba(220, 220, 220, 0.4);\n}\n\n\n.as-bscroller::-webkit-scrollbar {\n    width: 6px;\n    height: 6px;\n}\n\n.as-bscroller::-webkit-scrollbar-track {\n    background: rgba(220, 220, 220, 0.4);\n}\n\n.as-bscroller::-webkit-scrollbar-thumb {\n    background: rgba(182, 182, 182, 0.4);\n}\n\n.as-bscroller::-webkit-scrollbar-thumb:hover {\n    background: rgba(32, 32, 32, 0.4);\n}\n\n.as-bscroller::-webkit-scrollbar-thumb:active {\n    background: rgba(13, 13, 13, 0.6);\n}\n\n.as-bscroller.dark,\n.dark .as-bscroller,\n.as-dark .as-bscroller,\n.as-dark.as-bscroller\n{\n    scrollbar-color: rgba(104, 104, 104, 0.4) rgba(150, 150, 150, 0.4);\n}\n\n\n.as-bscroller.dark::-webkit-scrollbar-track,\n.dark .as-bscroller::-webkit-scrollbar-track,\n.as-dark .as-bscroller::-webkit-scrollbar-track,\n.as-dark.as-bscroller::-webkit-scrollbar-track\n{\n    background: rgba(150, 150, 150, 0.4);\n}\n\n.as-bscroller.dark::-webkit-scrollbar-thumb,\n.dark .as-bscroller::-webkit-scrollbar-thumb,\n.as-dark .as-bscroller::-webkit-scrollbar-thumb,\n.as-dark.as-bscroller::-webkit-scrollbar-thumb\n{\n    background: rgba(104, 104, 104, 0.4);\n}\n\n.as-bscroller.dark::-webkit-scrollbar-thumb:hover,\n.dark .as-bscroller::-webkit-scrollbar-thumb:hover,\n.as-dark .as-bscroller::-webkit-scrollbar-thumb:hover,\n.as-dark.as-bscroller::-webkit-scrollbar-thumb:hover\n{\n    background: rgba(223, 223, 223, 0.4);\n}\n\n.as-bscroller.dark::-webkit-scrollbar-thumb:active,\n.dark .as-bscroller::-webkit-scrollbar-thumb:active,\n.as-dark .as-bscroller::-webkit-scrollbar-thumb:active,\n.as-dark.as-bscroller::-webkit-scrollbar-thumb:active\n{\n    background: rgba(242, 242, 242, 0.6);\n}", ""]);



/***/ }),
/* 124 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(125);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 125 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-button-array {\n    font-size: 14px;\n    border: 1px solid #006ce5;\n    display: inline-block;\n    border-radius: 0.2em;\n    overflow: hidden;\n}\n\n.as-button-array-item {\n    text-align: center;\n    font-size: inherit;\n    height: 2em;\n    border: none;\n    box-sizing: border-box;\n    padding-left: 0.35714em;\n    padding-right: 0.35714em;\n    outline: none;\n    color: #006ce5;\n    background-color: white;\n    border-radius: 0;\n    transition: background-color 0.1s, color 0.1s;\n    margin: 0;\n}\n\n.as-button-array-item:not(:first-child) {\n    border-left: 1px solid #006ce5;\n    border-right: none;\n}\n\n\n.as-button-array-item.as-active {\n    color: white;\n    background-color: #006ce5;\n}", ""]);



/***/ }),
/* 126 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(127);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 127 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-calendar-input {\n    font-size: 14px;\n    width: 7em;\n    height: 2em;\n    box-sizing: content-box;\n    display: inline-block;\n    vertical-align: middle;\n    border: solid 1px #d6d6d6;\n    border-radius: 0.2em;\n}\n\n.absol-calendar-input>input {\n    text-align: center;\n    width: 100%;\n    height: 100%;\n    outline: none;\n    cursor: pointer;\n    border: none;\n    background: transparent;\n    padding: 0;\n}\n\n.absol-calendar-input>input:hover,\n.absol-calendar-input>input:focus {\n    color: red;\n}\n\n.absol-calendar-input.absol-disabled {\n    pointer-events: none;\n}\n\n.absol-calendar-input.absol-disabled input {\n    color: rgb(169, 169, 171);\n}", ""]);



/***/ }),
/* 128 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(129);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 129 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-chrome-calendar {\n    display: inline-block;\n    font-family: Arial;\n    font-size: 14px;\n    padding: 0.6em;\n    border: solid 1px rgb(191, 191, 191);\n    box-shadow: 1px 1px 2px rgb(240, 240, 240);\n    z-index: 100;\n    touch-action: manipulation;\n    user-select: none;\n    background-color: rgb(255, 255, 255);\n    white-space: initial;\n}\n\n\n.absol-chrome-calendar-header {\n    white-space: nowrap;\n    position: relative;\n}\n\n\n.absol-chrome-calendar-title {\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.absol-chrome-calendar-header-buttons {\n    position: absolute;\n    top: 0;\n    bottom: 0;\n    right: 0;\n}\n\n.absol-chrome-calendar-header-buttons > button {\n    font-size: 1em;\n    width: 1.5em;\n    height: 1.5em;\n    padding: 0;\n    border-radius: 0.2em;\n    border: solid 1px rgb(167, 167, 167);\n    background: linear-gradient(rgb(240, 240, 240), rgb(233, 233, 233), rgb(223, 223, 223));\n    cursor: pointer;\n    outline: none;\n    box-shadow: 1px 1px 2px #aaa;\n    color: rgb(110, 110, 110);\n}\n\n.absol-chrome-calendar-header-buttons > button:nth-child(2) {\n    margin-left: 0.2em;\n    margin-right: 0.2em;\n}\n\n\n.absol-chrome-calendar-header-buttons > button:active {\n    box-shadow: 0px 0px 2px #aaa;\n\n}\n\n.absol-chrome-calendar:not(.view-era) .absol-chrome-calendar-title {\n    cursor: pointer;\n}\n\n.absol-chrome-calendar.as-level-day .absol-chrome-calendar-title::after {\n    content: \"\\25BC\";\n}\n\n\n.absol-chrome-calendar-title > span {\n    line-height: 1.5em;\n}\n\n.absol-chrome-calendar-instance {\n    margin-top: 1em;\n    border: solid 1px rgb(190, 190, 190);\n    width: 14em;\n    position: relative;\n    height: calc(8.4em + 3px);\n    overflow: hidden;\n    /*border*/\n}\n\n.absol-chrome-calendar-dayofweek {\n    background-color: rgb(241, 241, 241);\n    height: 1.2em;\n    white-space: nowrap;\n    position: absolute;\n    left: 0;\n    right: 0;\n    z-index: 10;\n}\n\n.absol-chrome-calendar.as-level-week .absol-chrome-calendar-dayofweek::before {\n    content: \"wk\";\n    text-align: center;\n    line-height: 1.2;\n    display: inline-block;\n    color: rgb(130, 130, 255);\n    border-bottom: solid 1px rgb(191, 191, 191);\n    border-right: solid 1px rgb(191, 191, 191);\n    box-sizing: border-box;\n    width: 12.5%;\n}\n\n.absol-chrome-calendar-dayofweek > div {\n    text-align: center;\n    line-height: 1.2;\n    display: inline-block;\n    width: 14.2857142857%;\n    border-bottom: solid 1px rgb(191, 191, 191);\n    box-sizing: border-box;\n}\n\n.absol-chrome-calendar.as-level-week .absol-chrome-calendar-dayofweek > div {\n    width: 12.5%;\n}\n\n.absol-chrome-calendar-month-animation-container {\n    position: absolute;\n    transition: top 0.2s;\n}\n\n.absol-chrome-calendar-month-animation-container.old {\n    z-index: 7;\n    /* background: red; */\n}\n\n.absol-chrome-calendar-month-animation-container.new {\n    z-index: 8;\n    /* background: blue; */\n}\n\n.absol-chrome-calendar-month-animation-container > .absol-chrome-calendar-month {\n    width: 100%;\n    height: 100%;\n    margin-top: -1px;\n}\n\n\n.absol-chrome-calendar-month {\n    display: table;\n    width: 100%;\n    margin-top: 1.2em;\n    background-color: white;\n    /*for header*/\n}\n\n.absol-chrome-calendar-week-in-month {\n    display: table-row;\n    height: 1.2em;\n}\n\n.absol-chrome-calendar.as-level-week .absol-chrome-calendar-week-in-month::before {\n    content: attr(data-week-idx-text);\n    display: table-cell;\n    text-align: right;\n    padding-right: 0.4em;\n    color: rgb(130, 130, 255);\n    text-shadow: 1px 0 0 currentColor;\n    border-right: solid 1px rgb(191, 191, 191);\n    width: 12.5%;\n}\n\n\n.absol-chrome-calendar-week-in-month > div {\n    display: table-cell;\n    text-align: right;\n    padding-right: 0.4em;\n    cursor: pointer;\n}\n\n.absol-chrome-calendar-week-in-month > div:hover,\n.absol-chrome-calendar.as-level-week .absol-chrome-calendar-week-in-month:hover {\n    background-color: rgb(224, 245, 256);\n}\n\n.absol-chrome-calendar.as-level-week\n.absol-chrome-calendar-not-in-month {\n    color: rgb(190, 190, 190);\n}\n\n.absol-chrome-calendar-today {\n    border: inset 1px rgb(191, 191, 191);\n    box-sizing: border-box;\n}\n\n.absol-chrome-calendar-selected,\n.absol-chrome-calendar.as-level-week .as-week-selected {\n    background-color: rgb(188, 205, 236);\n}\n\n.absol-chrome-calendar.as-level-week .as-week-selected .absol-chrome-calendar-selected {\n    background-color: transparent;\n}\n\n\n.absol-chrome-calendar-years {\n    width: 100%;\n    height: 100%;\n}\n\n\n.absol-chrome-calendar:not(.view-year) .absol-chrome-calendar-years {\n    /* display: none; */\n    position: absolute;\n    left: 0;\n    top: 0;\n    width: 100%;\n    height: 100%;\n    z-index: -10000;\n    opacity: 0;\n    visibility: hidden;\n}\n\n.absol-chrome-calendar.view-year .absol-chrome-calendar-instance {\n    border-color: rgb(77, 114, 254)\n}\n\n.absol-chrome-calendar:not(.view-month) .absol-chrome-calendar-month,\n.absol-chrome-calendar:not(.view-month) .absol-chrome-calendar-dayofweek,\n.absol-chrome-calendar:not(.view-era) .absol-chrome-calendar-era {\n    display: none;\n}\n\n.absol-chrome-calendar:not(.view-month) .absol-chrome-calendar-title {\n    color: rgb(191, 191, 191);\n}\n\n\n.absol-chrome-calendar-year {\n    overflow: hidden;\n}\n\n\n.absol-chrome-calendar-year-head {\n    background-color: rgb(241, 241, 241);\n    border-bottom: solid 1px rgb(191, 191, 191);\n    height: 1.5em;\n    text-align: center;\n    line-height: 1.5em;\n}\n\n\n.absol-chrome-calendar-year:last-child .absol-chrome-calendar-year-head {\n    border-bottom: solid 1px rgb(191, 191, 191);\n}\n\n.absol-chrome-calendar-year.start-opening .absol-chrome-calendar-year-mounths,\n.absol-chrome-calendar-year.closing .absol-chrome-calendar-year-mounths {\n    margin-bottom: -6em;\n    transition: margin-bottom linear 0.1s;\n}\n\n.absol-chrome-calendar-year.opening .absol-chrome-calendar-year-mounths,\n.absol-chrome-calendar-year.start-closing .absol-chrome-calendar-year-mounths {\n    margin-bottom: 0;\n    transition: margin-bottom linear 0.1s;\n\n}\n\n.absol-chrome-calendar-year-mounths {\n    width: 100%;\n    display: table;\n    height: 6em;\n    border-bottom: solid 1px rgb(191, 191, 191);\n}\n\n.absol-chrome-calendar-year-row-months {\n    display: table-row;\n}\n\n.absol-chrome-calendar-year-month {\n    text-align: center;\n    display: table-cell;\n    vertical-align: middle;\n}\n\n.absol-chrome-calendar-year-month:hover,\n.absol-chrome-calendar-era-year:hover {\n    background-color: rgb(224, 245, 256);\n}\n\n\n.absol-chrome-calendar-years:hover .absol-scrollbar {\n    opacity: 1;\n\n}\n\n.absol-chrome-calendar-years .absol-scrollbar {\n    background-color: rgba(169, 169, 172, 0.2);\n    opacity: 0;\n    transition: opacity 0.2s;\n}\n\n.absol-chrome-calendar-date-disabled,\n.absol-chrome-calendar-era-year.absol-chrome-calendar-date-disabled {\n    color: rgb(240, 230, 230);\n    pointer-events: none;\n    cursor: not-allowed;\n}\n\nbutton.absol-chrome-calendar-button-disabled,\n.absol-chrome-calendar button:disabled {\n    color: rgb(220, 210, 210);\n    pointer-events: none;\n    box-shadow: none;\n    cursor: not-allowed;\n}\n\n.absol-chrome-calendar-era {\n    position: absolute;\n    left: 0;\n    top: 0;\n    z-index: 1000000;\n    /*width: 100%;*/\n    /*height: 100%; */\n    width: calc(196px + 17px);\n    box-sizing: border-box;\n    height: 100%;\n    background-color: white;\n    box-shadow: 0px 0px 1px 0 black;\n    overflow-y: scroll;\n    font-size: inherit;\n}\n\n.absol-chrome-calendar-era-row {\n    width: 14em;\n    height: 25%;\n    white-space: nowrap;\n    font-size: inherit;\n}\n\n.absol-chrome-calendar-era-year {\n    display: inline-block;\n    vertical-align: top;\n    height: 100%;\n    width: 25%;\n    text-align: center;\n    line-height: 2.1em;\n    font-size: inherit;\n    color: rgb(190, 190, 190);\n}\n\n\n.absol-chrome-calendar-in-decade:not(.absol-chrome-calendar-date-disabled) {\n    color: black;\n}\n\n/*.absol-chrome-calendar-era*/", ""]);



/***/ }),
/* 130 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(131);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 131 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-vscroller {\n    position: relative;\n    overflow-x: hidden;\n}\n\n\n.absol-vscroller.disabled>.absol-vscroller-viewport {\n    overflow-y: visible;\n    margin-right: 0px;\n    min-width: 100%;\n}\n\n.absol-vscroller.disabled {\n    overflow: visible;\n    overflow-x: visible;\n\n}\n\n\n.absol-vscroller-viewport {\n    overflow-y: scroll;\n    box-sizing: content-box;\n\n}\n\n.absol-vscroller>.absol-vscroller-viewport {\n    max-height: 100%;\n}\n\n.absol-vscroller.limited-height>.absol-vscroller-viewport {\n    max-height: inherit;\n}\n\n\n/************  hscroller  ***********/\n.absol-hscroller {\n    position: relative;\n    overflow-y: hidden;\n}\n\n.absol-hscroller.disabled {\n    overflow: visible;\n    overflow-y: visible;\n}\n\n.absol-hscroller-viewport {\n    overflow-x: scroll;\n    box-sizing: content-box;\n    min-height: calc(100% + 17px);\n}\n\n.absol-hscroller.disabled>.absol-hscroller-viewport {\n    overflow-x: visible;\n    margin-bottom: 0px;\n}\n\n\n.absol-hscroller>.absol-hscroller-viewport {\n    max-width: 100%;\n}\n\n\n/********** scroll bar *********************/\n.absol-scrollbar-force-modal {\n    position: fixed;\n    top: 5px;\n    left: 5px;\n    right: 5px;\n    bottom: 5px;\n    z-index: 1000000;\n}\n\n.absol-scrollbar-container {\n    position: absolute;\n    right: 0;\n    bottom: 0;\n    z-index: 10;\n}\n\n.absol-scrollbar-container.vertical {\n    top: 0;\n    width: 7px;\n}\n\n.absol-scrollbar-container.horizontal {\n    height: 7px;\n    left: 0;\n}\n\n.absol-scrollbar-container>.absol-scrollbar {\n    width: 100%;\n    height: 100%;\n}\n\n\n\n\n\n.absol-scrollbar-container.vertical>.absol-scrollbar>.absol-scrollbar-button {\n    left: 1px;\n    right: 1px;\n    top: 0;\n}\n\n.absol-scrollbar-container.horizontal>.absol-scrollbar>.absol-scrollbar-button {\n    top: 1px;\n    bottom: 1px;\n    left: 0;\n}\n\n.absol-scrollbar {\n    position: relative;\n    background: transparent;\n}\n\n.absol-scrollbar-button {\n    position: absolute;\n    background-color: rgba(0, 0, 0, 0.25);\n    border-radius: 2px;\n}\n\n\n.absol-scrollbar.absol-hidden {\n    visibility: hidden;\n}", ""]);



/***/ }),
/* 132 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(133);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 133 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ":root {\n    --candy-border-color: #929292;\n    --candy-hover-background-color: #eeeee9;\n    --candy-disabled-background-color: #ebebe4;\n}\n\nlabel.as-checkbox-input {\n    display: inline-block;\n    position: relative;\n    width: calc(1em + 2px);\n    height: calc(1em + 2px);\n    cursor: pointer;\n    font-size: inherit;\n    box-sizing: border-box;\n    vertical-align: middle;\n    border-radius: 0.25em;\n    padding: 0;\n    margin: 0; /*fix boostrap override*/\n}\n\nlabel.as-checkbox-input:hover .bound,\n.absol-checkbox:hover .bound {\n    fill: var(--candy-hover-background-color);\n}\n\n.as-checkbox-input .tick,\n.as-checkbox-input .minus {\n    fill: #606060;\n}\n\n\n.as-checkbox-input input.as-checkbox-input-value {\n    font-size: inherit;\n    position: absolute;\n    right: 100%;\n    top: 0;\n    opacity: 0.0;\n    z-index: -100000000000;\n}\n\ninput.as-checkbox-input-value:not(:checked) ~ svg .tick {\n    opacity: 0;\n}\n\n.as-checkbox-input.as-has-minus .minus {\n    opacity: 1;\n}\n\n.as-checkbox-input .minus,\ninput.as-checkbox-input-value:checked ~ svg .minus {\n    opacity: 0;\n}\n\n\nlabel.as-checkbox-input .bound {\n    stroke: var(--candy-border-color);\n    fill: white;\n}\n\nlabel.as-checkbox-input .tick {\n    opacity: 1;\n    transition: opacity 0.1s;\n}\n\nlabel.as-checkbox-input .minus {\n    transition: opacity 0.1s;\n}\n\nlabel.as-checkbox-input.as-disabled > svg .bound,\nlabel.as-checkbox-input.as-disabled:hover > svg .bound {\n    stroke: #929292;\n    fill: #ebebe4;\n}\n\n\n.as-checkbox-input > svg {\n    width: 100%;\n    height: 100%;\n}\n\n", ""]);



/***/ }),
/* 134 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(135);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 135 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, "/** align middle in table cell **/\n.KPIsimpletableclass  td > .absol-checkbox:first-child:last-child,\n.KPIsimpletableclass  td > .absol-checkbox.as-no-label:first-child:last-child .as-checkbox-input{\n    display: block;\n    margin: auto;\n}\n\n.absol-checkbox {\n    display: inline-block;\n    vertical-align: middle;\n    cursor: pointer;\n    user-select: none;\n    line-height: 16px;\n}\n\n.absol-checkbox.right > .absol-checkbox-label.as-right {\n    display: none;\n}\n\n\n.absol-checkbox:not(.right) > .absol-checkbox-label.as-left {\n    display: none;\n}\n\n.absol-checkbox-label {\n    vertical-align: middle;\n    display: inline-block;\n}\n\n\n.absol-checkbox-label.as-left {\n    padding-right: 0.3em;\n}\n\n\n.absol-checkbox-label.as-right {\n    padding-left: 0.3em;\n}\n\n.absol-checkbox.as-no-label {\n    width: calc(1em + 2px);\n    height: calc(1em + 2px);\n}\n\n\n.absol-checkbox.as-no-label .absol-checkbox-label {\n    display: none;\n}\n\n.absol-checkbox.as-no-label .as-checkbox-input {\n    display: block;\n}\n\n.absol-checkbox.as-disabled .absol-checkbox-label {\n    color: #777;\n}\n", ""]);



/***/ }),
/* 136 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(137);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 137 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-circle-section-label {\n    position: relative;\n    -webkit-print-color-adjust: exact;\n    /*friendly print*/\n}\n\n.as-circle-section-label-text {\n    position: relative;\n    display: inline-block;\n    vertical-align: middle;\n    font-size: 1em;\n    padding-right: 2.5em;\n    color: white;\n    font-weight: bold;\n    z-index: 2;\n}\n\n\n.as-circle-section-label-index {\n    position: relative;\n    display: inline-block;\n    vertical-align: middle;\n    text-align: center;\n    color: rgb(30, 162, 245);\n    font-weight: 900;\n    z-index: 2;\n}\n\n\n@media print {\n    .as-circle-section-label-text {\n        color: white !important;\n    }\n\n    .as-circle-section-label-index {\n        color: rgb(30, 162, 245) !important;\n    }\n}\n\n\n.as-circle-section-label-background {\n    position: absolute;\n    top: 0;\n    left: 0;\n    bottom: 0;\n    z-index: 1;\n}\n\n.as-circle-section-label-background>svg {\n    display: block;\n}\n\n.as-circle-section-label-index-box {\n    stroke: rgb(129, 211, 246);\n    fill: white;\n    stroke-width: 2.5;\n}\n\n.as-circle-section-label-arrow {\n    stroke: rgb(30, 162, 245);\n    fill: none;\n    stroke-linecap: round;\n}\n\n.as-circle-section-label-text-box {\n    fill: rgb(30, 162, 245);\n    stroke: none;\n}\n\n.as-circle-section-label-arrow-marker-path {\n    fill: rgb(30, 162, 245);\n    stroke: none;\n}", ""]);



/***/ }),
/* 138 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(139);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 139 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-context-menu-hook {\n    position: absolute;\n    z-index: -100000;\n    width: 14px;\n    height: 14px;\n    top: 0;\n    opacity: 0;\n    resize: none;\n    cursor: default;\n}\n\n.absol-context-hinge-fixed-container {\n    position: fixed;\n    left: 0;\n    top: 0;\n    z-index: 1000000001;\n}\n\n.absol-context-hinge {\n    position: relative;\n    width: 0;\n    height: 0;\n}\n\n.absol-context-hinge > .absol-context-menu {\n    position: absolute;\n    top: -10000px;\n    left: -10000px;\n    visibility: hidden;\n    z-index: 55;\n    display: inline-block;\n}\n\n.absol-context-hinge .absol-vmenu,\n.absol-context-hinge .absol-hmenu {\n    padding-top: 0.4em;\n    padding-bottom: 0.4em;\n    /* background-color: rgb(37, 37, 38);\n    -webkit-box-shadow: 2px 2px 9px 0px rgba(7, 7, 7, 1);\n    -moz-box-shadow: 2px 2px 9px 0px rgb(7, 7, 7, 1);\n    box-shadow: 2px 2px 9px 0px rgba(7, 7, 7, 1); */\n    color: black;\n    background-color: rgb(252, 252, 255);\n    -webkit-box-shadow: 2px 2px 9px 0px rgba(20, 20, 20, 1);\n    -moz-box-shadow: 2px 2px 9px 0px rgba(20, 20, 20, 1);\n    box-shadow: 2px 2px 9px 0px rgba(20, 20, 20, 1);\n}\n\n.absol-context-menu-anchor.dark .absol-hmenu,\n.absol-context-menu-anchor.dark .absol-vmenu,\n.dark .absol-context-menu-anchor .absol-hmenu,\n.dark .absol-context-menu-anchor .absol-vmenu {\n    background-color: rgb(37, 37, 38);\n}\n\n\n.absol-context-menu-anchor {\n    position: fixed;\n    z-index: -1000;\n    left: 0;\n    top: 0;\n    display: block;\n    opacity: 0;\n    visibility: hidden;\n    font-size: inherit;\n}\n\n.absol-context-menu-anchor > textarea {\n    width: 160px;\n    height: 160px;\n    margin: 0;\n    resize: none;\n    border: none;\n    opacity: 0;\n    cursor: default;\n    user-select: none;\n    -webkit-user-select: none;\n    -moz-user-select: none;\n}\n\n.absol-context-menu-anchor.absol-active {\n    z-index: 100000000;\n    opacity: 1;\n    visibility: visible;\n}\n\n\n.absol-context-menu-anchor .absol-vmenu,\n.absol-context-menu-anchor .absol-hmenu {\n    padding-top: 0.4em;\n    padding-bottom: 0.4em;\n    color: black;\n    background-color: rgb(252, 252, 255);\n    -webkit-box-shadow: 2px 2px 9px 0px rgba(20, 20, 20, 1);\n    -moz-box-shadow: 2px 2px 9px 0px rgba(20, 20, 20, 1);\n    box-shadow: 2px 2px 9px 0px rgba(20, 20, 20, 1);\n}\n\n\n.as-system-context-menu {\n    /** nothing here, to define use system context menu**/\n}\n\n.as-context-menu-ctn {\n    font-size: var(--as-context-menu-font-size);\n    font-family: var(--as-input-font-family);\n}\n\n.as-context-menu-ctn.as-anchor-modal,\n.absol-context-menu-anchor.as-anchor-modal{\n    position: fixed;\n    z-index: 8000000;\n    left: 0 !important;\n    right: 0 !important;;\n    top: 0 !important;;\n    bottom: 0 !important;;\n    box-sizing: border-box;\n    text-align: center;\n    background-color: rgba(155, 155, 155, 0.3);\n}\n\n.as-context-menu-ctn.as-anchor-modal::before,\n.as-context-menu-ctn.as-anchor-modal > .absol-vmenu ,\n.absol-context-menu-anchor.as-anchor-modal::before,\n.absol-context-menu-anchor.as-anchor-modal > .absol-vmenu\n{\n    display: inline-block;\n    vertical-align: middle;\n    white-space: nowrap;\n}\n\n.as-context-menu-ctn.as-anchor-modal > .absol-vmenu,\n.absol-context-menu-anchor.as-anchor-modal > .absol-vmenu\n{\n    text-align: left;\n}\n\n\n.as-context-menu-ctn.as-anchor-modal::before,\n.absol-context-menu-anchor.as-anchor-modal::before{\n    content: \"\";\n    height: 100%;\n}\n\n.as-context-menu-ctn.as-anchor-modal > .absol-vmenu,\n.absol-context-menu-anchor.as-anchor-modal > .absol-vmenu {\n    min-width: 70%;\n    max-width: calc(100% - 10px);\n    max-height: calc(100% - 10px);\n}\n\n.as-quick-menu {\n    font-size: 14px;\n}", ""]);



/***/ }),
/* 140 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(141);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 141 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-ico {\n    width: 1em;\n    height: 1em;\n}\n\n.absol-button {\n    white-space: normal;\n    -webkit-touch-callout: none;\n    -webkit-user-select: none;\n    -khtml-user-select: none;\n    -moz-user-select: none;\n    -ms-user-select: none;\n    user-select: none;\n}\n\n.absol-dropdown {\n    position: relative;\n}\n\n.absol-dropdown-content {\n    z-index: 1;\n    position: fixed;\n    left: 0;\n    top: 0;\n    overflow: auto;\n    -webkit-touch-callout: none;\n    -webkit-user-select: none;\n    -khtml-user-select: none;\n    -moz-user-select: none;\n    -ms-user-select: none;\n    user-select: none;\n}\n\n.absol-dropdown.top > .absol-dropdown-content {\n    top: auto;\n    bottom: 100%;\n}\n\n.absol-dropdown.overlap-left > .absol-dropdown-content {\n    left: auto;\n    right: 0;\n}\n\n.absol-dropright {\n    position: relative;\n}\n\n.absol-dropright-content {\n    z-index: 1;\n    position: fixed;\n    left: 0;\n    top: 0;\n    -webkit-touch-callout: none;\n    -webkit-user-select: none;\n    -khtml-user-select: none;\n    -moz-user-select: none;\n    -ms-user-select: none;\n    user-select: none;\n    overflow: auto;\n}\n\n.absol-dropright.overlap-top > .absol-dropright-content {\n    top: unset;\n    bottom: 0;\n}\n\n.absol-drop-hidden > .absol-dropdown-content,\n.absol-drop-hidden > .absol-dropright-content {\n    visibility: hidden;\n    top: 0 !important;\n    left: 0 !important;\n    max-height: 99vh !important;\n    opacity: 0;\n    pointer-events: none;\n}\n\n.absol-drop-hidden > .absol-dropright-content *,\n.absol-drop-hidden > .absol-dropdown-content *{\n    visibility: hidden;\n}\n\n.absol-hmenu {\n    display: inline-block;\n    background-color: rgb(252, 252, 255);\n    /* background-color: rgb(33, 33, 33); */\n\n}\n\n.absol-hmenu > .absol-dropdown {\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.absol-hmenu-button:hover,\n.absol-hmenu .absol-hmenu-button-hover {\n\n    background-color: rgb(175, 175, 175);\n}\n\n.absol-hmenu-button {\n    padding-left: 1em;\n    padding-right: 1em;\n}\n\n.absol-hmenu-button:focus {\n    outline: none;\n}\n\n.absol-hmenu-button,\n.absol-vmenu-button {\n    color: rgb(55, 55, 55);\n    height: 100%;\n    background-color: transparent;\n    font-size: 1em;\n    border: none;\n    padding: 0;\n    margin: 0;\n    outline: none;\n}\n\n.absol-hmenu-button {\n    padding-left: 1em;\n    padding-right: 1em;\n}\n\n.absol-vmenu {\n\n}\n\n.absol-hmenu .absol-dropdown-content,\n.absol-hmenu .absol-dropright-content,\n.as-v-root-menu .absol-dropright-content {\n    padding-top: 0.4em;\n    padding-bottom: 0.4em;\n    background-color: rgb(252, 252, 255);\n    -webkit-box-shadow: 2px 2px 9px 0px rgba(20, 20, 20, 1);\n    -moz-box-shadow: 2px 2px 9px 0px rgba(20, 20, 20, 1);\n    box-shadow: 2px 2px 9px 0px rgba(20, 20, 20, 1);\n}\n\n.absol-vmenu-button {\n    text-align: left;\n    padding-left: 0.5em;\n    padding-right: 2em;\n    height: 1.8em;\n    white-space: nowrap;\n    position: relative;\n}\n\nimg.absol-vmenu-button-icon {\n    opacity: 0;\n    display: none;\n}\n\nimg.absol-vmenu-button-icon[src] {\n    display: block;\n}\n\n.absol-vmenu-button-ext-icon-container {\n    display: inline-block;\n    width: 1.2em;\n    height: 1.2em;\n    vertical-align: middle;\n    margin-right: 0.5em;\n}\n\n.absol-vmenu-button-ext-icon-container > span,\n.absol-vmenu-button-ext-icon-container > i {\n    font-size: 1.2em;\n    line-height: 1;\n    display: block;\n}\n\n\n.absol-vmenu-button-ext-icon-container > svg,\n.absol-vmenu-button-ext-icon-container > img {\n    height: 1.2em;\n    width: 1.2em;\n    display: block;\n}\n\n\n.absol-vmenu-button-text,\n.absol-vmenu-button-key {\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.absol-vmenu-button-key {\n    font-style: italic;\n    text-align: right;\n    margin-left: 1em;\n}\n\n.absol-vmenu-arrow-container {\n    position: absolute;\n    right: 0.2em;\n    top: 0.3em;\n    bottom: 0.3em;\n}\n\n\n.absol-vmenu-arrow-container::after {\n    content: \"\";\n    display: inline-block;\n    vertical-align: middle;\n    height: 100%;\n}\n\n\n.absol-vmenu-arrow {\n    display: inline-block;\n    font-size: inherit;\n    vertical-align: middle;\n}\n\n.absol-menu-item-disable .absol-vmenu-arrow {\n    display: none;\n}\n\n.absol-vmenu-button:hover,\n.absol-vmenu .absol-vmenu-button-hover {\n    background-color: rgb(214, 214, 217);\n}\n\n.absol-menu-item-disable .absol-vmenu-button:hover,\n.absol-menu-item-disable .absol-vmenu .absol-vmenu-button-hover,\n.absol-menu-item-disable .absol-hmenu-button:hover,\n.absol-menu-item-disable .absol-hmenu .absol-hmenu-button-hover {\n    background-color: transparent;\n}\n\n.absol-vmenu-line {\n    text-align: center;\n    padding: 0.2em 1em;\n}\n\n.absol-vmenu-line > div {\n    height: 1px;\n    background-color: rgb(97, 97, 97);\n}\n\n.absol-menu-item-disable {\n}\n\n.absol-menu-item-disable button {\n    color: rgb(155, 155, 159);\n}\n\n.dark .absol-menu-item-disable button {\n    color: rgb(100, 100, 100);\n}\n\n.dark .absol-vmenu-button:hover,\n.dark .absol-vmenu .absol-vmenu-button-hover {\n    background-color: rgb(9, 71, 113);\n}\n\n\n.dark .absol-hmenu .absol-dropdown-content,\n.dark .absol-hmenu .absol-dropright-content {\n    background-color: rgb(37, 37, 38);\n}\n\n\n.dark .absol-hmenu-button,\n.dark .absol-vmenu-button {\n    color: rgb(200, 200, 200);\n\n}\n\n\n.dark .absol-hmenu-button:hover,\n.dark .absol-hmenu .absol-hmenu-button-hover {\n    background-color: rgb(80, 80, 80);\n}\n\n\n.dark .absol-hmenu {\n    background-color: rgb(33, 33, 33);\n}\n\n/*standard-alone*/\n.absol-vmenu-button.standard-alone {\n    height: 2em;\n    border-radius: 0.3em;\n    border: solid rgb(169, 169, 170) 1px;\n    outline: none;\n}\n\n.as-v-root-menu {\n    display: inline-block;\n    box-sizing: border-box;\n    /*overflow-y: auto;*/\n    /*overflow-x: hidden;*/\n}", ""]);



/***/ }),
/* 142 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(143);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 143 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-follower {\n    position: fixed;\n    z-index: 100;\n}\n\n.absol-follower-hidden{\n    z-index: -1000 !important;\n    opacity: 0;\n    visibility: hidden;\n}", ""]);



/***/ }),
/* 144 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-date-input {\n    border: 1px solid #ddd;\n    border-radius: 3px;\n    height: 30px;\n    width: calc(6em + 50px);\n    box-sizing: border-box;\n    display: inline-block;\n    vertical-align: middle;\n    position: relative;\n    background-color: white;\n    font: inherit;\n}\n\n.as-date-input-text {\n    outline: none;\n    width: calc(100% - 29px);\n    height: 100%;\n    border: none;\n    background-color: transparent;\n    display: block;\n    padding: 0 0 0 var(--as-input-horizontal-padding);\n    font: inherit;\n    box-sizing: border-box;\n\n}\n\n.as-date-input-icon-ctn {\n    border-left: 1px solid #ddd;\n    border-right: none;\n    border-top: none;\n    border-bottom: none;\n    text-align: center;\n    position: absolute;\n    right: 0;\n    width: 29px;\n    box-sizing: border-box;\n    top: 0;\n    height: 100%;\n    background-color: rgba(169, 169, 169, 0.1);\n    cursor: pointer;\n}\n\n\n.as-date-input-icon-ctn:hover {\n    background-color: rgba(169, 169, 169, 0.25);\n}\n\n.as-date-input-icon-ctn:active {\n    background-color: rgba(169, 169, 169, 0.5);\n}\n\n\n.as-date-input-icon-ctn > span {\n    line-height: 28px;\n    font-size: 16px;\n}\n\n.as-date-input.as-disabled {\n    color: var(--as-disabled-text-color);\n    pointer-events: none;\n}\n\n.as-date-input.as-disabled input {\n    background-color: var(--as-disabled-background-color);\n}\n\n.as-date-input.as-value-null .as-date-input-clear-btn,\n.as-date-input.as-must-not-null .as-date-input-clear-btn {\n    display: none;\n}\n\n.as-date-input-clear-btn {\n    font-size: inherit;\n    position: absolute;\n    right: 30px;\n    height: 30px;\n    top: calc(50% - 15px);\n    box-sizing: border-box;\n    background-color: transparent;\n    border: none;\n    color: #bbb;\n    visibility: hidden;\n}\n\n.as-date-input-clear-btn:hover {\n    color: rgb(132, 132, 132)\n}\n\n.as-date-input-clear-btn:active {\n    color: #525555;\n}\n\n.as-date-input-text:focus + .as-date-input-clear-btn,\n.as-date-input:hover .as-date-input-clear-btn {\n    visibility: visible;\n}\n", ""]);



/***/ }),
/* 145 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(146);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 146 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-date-time-input {\n    border: 1px solid #ddd;\n    border-radius: 3px;\n    height: 30px;\n    width: calc(12em + 30px);\n    box-sizing: border-box;\n    display: inline-block;\n    vertical-align: middle;\n    position: relative;\n    background-color: white;\n    overflow: hidden;\n}\n\n.as-date-time-input.as-disabled {\n    color: var(--as-disabled-text-color);\n    pointer-events: none;\n}\n\n\n.as-date-time-input input {\n    outline: none;\n    width: calc(100% - 29px);\n    height: 100%;\n    border: none;\n    display: block;\n    padding: 0 0 0 var(--as-input-horizontal-padding);\n    -webkit-user-select: auto;\n    user-select: auto;\n    -webkit-user-drag: none;\n    color: inherit;\n    box-sizing: border-box;\n}\n\n.as-date-time-input.as-disabled input {\n    background-color: var(--as-disabled-background-color);\n}\n\n.as-date-time-input-icon-btn {\n    border-right: none;\n    border-top: none;\n    border-bottom: none;\n    border-left: 1px solid #ddd;\n    position: absolute;\n    right: 0;\n    width: 29px;\n    box-sizing: border-box;\n    top: 0;\n    bottom: 0;\n    background-color: rgba(169, 169, 169, 0.1);\n    cursor: pointer;\n    border-radius: 0;\n    color: inherit;\n}\n\n.as-date-time-input-icon-btn > span {\n    font-size: 16px;\n}\n\n\n.as-date-time-input-icon-btn:hover {\n    background-color: rgba(169, 169, 169, 0.25);\n}\n\n.as-date-time-input-icon-btn:active {\n    background-color: rgba(169, 169, 169, 0.5);\n}\n\n\n.as-date-time-input-icon-btn.as-disabled {\n    color: rgb(102, 102, 102);\n    pointer-events: none;\n}\n\n.as-date-time-input-follower {\n    box-sizing: border-box;\n    background-color: white;\n    border: 1px solid #ddd;\n    padding: 5px;\n}\n\n.as-date-time-input-date-picker {\n    border: none;\n    box-shadow: none;\n}\n\n.as-date-time-input-picker-header {\n    text-align: right;\n    padding-bottom: 5px;\n}\n\n.as-date-time-input-picker-footer {\n    text-align: center;\n}\n\n.as-date-time-input-picker-footer > button {\n    margin: 0 10px;\n}\n\n.as-date-time-input-picker-btn {\n    height: 20px;\n    min-width: 25px;\n    padding: 0 5px;\n    box-sizing: border-box;\n    font-size: inherit;\n    border: 1px solid rgb(47, 82, 143);\n    background-color: rgb(68, 144, 196);\n    color: white;\n    border-radius: 0;\n}\n\n.as-date-time-input-picker-btn:active {\n    background-color: rgb(50, 122, 169);\n}\n\n\n.as-chrome-time-picker.as-date-time-input-time-picker {\n    height: 166px;\n    box-sizing: border-box;\n}\n\n.as-date-time-input-picker-ctn {\n    white-space: nowrap;\n}\n\n.as-date-time-input-picker-ctn > div {\n    display: inline-block;\n    white-space: initial;\n    vertical-align: top;\n}\n\n.as-date-time-input-follower > div {\n    border-color: white;\n}\n\n.as-date-time-input:hover .as-time-input-clear-btn {\n    visibility: visible;\n}", ""]);



/***/ }),
/* 147 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-chrome-time-picker {\n    box-sizing: border-box;\n    vertical-align: top;\n    display: inline-block;\n    font-family: Arial;\n    font-size: 14px;\n    padding: 0.6em;\n    border: solid 1px rgb(191, 191, 191);\n    box-shadow: 1px 1px 2px rgb(240, 240, 240);\n    z-index: 100;\n    touch-action: manipulation;\n    user-select: none;\n    background-color: rgb(255, 255, 255);\n    /*width: calc(160px + 1.2em);*/\n    height: 176px;\n    white-space: nowrap;\n}\n\n.as-chrome-time-picker.as-24h-clock .as-chrome-time-picker-scroller-h12,\n.as-chrome-time-picker:not(.as-24h-clock) .as-chrome-time-picker-scroller-h24,\n.as-chrome-time-picker.as-24h-clock .as-chrome-time-picker-period {\n    display: none;\n}\n\n.as-chrome-time-picker-period {\n    padding-top: 20px;\n    padding-bottom: 20px;\n}\n\n\n.as-chrome-time-picker > div:not(:first-child) {\n    margin-left: 5px;\n}\n\n\n.as-chrome-time-picker-scroller {\n    position: relative;\n    padding-top: 20px;\n    padding-bottom: 20px;\n    display: inline-block;\n    vertical-align: top;\n    height: 100%;\n    box-sizing: border-box;\n}\n\n.as-chrome-time-picker-scroller-up,\n.as-chrome-time-picker-scroller-down {\n    position: absolute;\n    left: 0;\n    width: 100%;\n    height: 20px;\n    padding: 0;\n    box-sizing: border-box;\n    background-color: transparent;\n    border-radius: 3px;\n    border: none;\n    font-size: 1.5em;\n}\n\n.as-chrome-time-picker-scroller-up:hover,\n.as-chrome-time-picker-scroller-down:hover {\n    background-color: rgba(169, 169, 169, 0.2);\n}\n\n.as-chrome-time-picker-scroller-up {\n    top: -5px;\n}\n\n.as-chrome-time-picker-scroller-down {\n    bottom: -5px;\n}\n\n\n.as-chrome-time-picker-viewport {\n    width: 50px;\n    height: 100%;\n    overflow: hidden;\n    white-space: normal;\n    display: inline-block;\n    vertical-align: top;\n}\n\n\n.as-chrome-time-picker-list {\n    height: 100%;\n    overflow-y: scroll;\n    width: calc(100% + 18px);\n}\n\n.as-chrome-time-picker-btn {\n    font-size: inherit;\n    height: 28px;\n    width: 100%;\n    padding: 0;\n    border: none;\n    background-color: transparent;\n}\n\n.as-chrome-time-picker-btn:hover {\n    background-color: rgb(224, 245, 256);\n}\n\n.as-chrome-time-picker-btn.as-selected {\n    background-color: rgb(188, 205, 236);\n    border-radius: 3px;\n}\n\n.as-chrome-time-picker-btn > span {\n    font-size: 16px;\n}\n\n\n\n", ""]);



/***/ }),
/* 148 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-draggable-stack {\n    position: relative;\n}\n\n.absol-draggable-stack .drag-zone {\n    touch-action: none;\n}\n\n.absol-draggable-stack > .as-dragging {\n    opacity: 0.2 !important;\n}\n\n.absol-draggable-stack-child-container.as-dragging {\n    opacity: 0.2 !important;\n}\n\n.absol-draggable-stack-clone-container {\n    position: fixed;\n    left: 0;\n    top: 0;\n    z-index: 100000;\n    user-select: none;\n    -moz-user-select: none;\n    -webkit-user-select: none;\n    -ms-user-select: none;\n    pointer-events: all;\n    opacity: 0.5;\n    background: white;\n}\n\n.absol-draggable-vstack > .absol-draggable-stack-clone-container {\n    left: 0;\n    right: 0;\n\n}\n\n.absol-draggable-stack-clone-container * {\n    pointer-events: none !important;\n}\n\n.absol-draggable-stack-clone-container > * {\n    width: 100% !important;\n    height: 100% !important;\n    box-sizing: border-box;\n}\n\n\n.absol-draggable-stack-clone-container.home-going {\n    transition: top 0.2s;\n}\n\n.absol-draggable-stack-dest-line {\n    position: absolute;\n    z-index: 99;\n    box-sizing: content-box;\n}\n\n.absol-draggable-vstack > .absol-draggable-stack-dest-line {\n    transition: top 0.1s;\n    left: 0;\n    right: 0;\n    border-top: solid 3px rgb(74, 174, 233);\n    border-bottom: solid 3px rgb(74, 174, 233);\n}\n\n\n.absol-draggable-hstack {\n    --dest-x: 0px;\n}\n\n.absol-draggable-hstack.as-has-dragging::after {\n    content: \"\";\n    position: absolute;\n    transition: left 0.1s;\n    top: 0;\n    bottom: 0;\n    left: calc(var(--dest-x) - 3px);\n    border-left: solid 3px rgb(74, 174, 233);\n    border-right: solid 3px rgb(74, 174, 233);\n}\n\n.absol-draggable-hstack.as-no-change::after {\n    visibility: hidden;\n}\n\n\n.absol-draggable-hstack > * {\n    display: inline-block;\n    vertical-align: middle;\n}\n\n\n.absol-draggable-vstack {\n    --dest-y: unset;\n}\n\n/**.as-state-drag*/\n.absol-draggable-vstack.as-state-drag::after {\n    content: \"\";\n    display: block;\n    position: absolute;\n    top: calc(var(--dest-y) - 3px);\n    left: 0;\n    right: 0;\n    transition: top 0.1s;\n    border-top: solid 3px rgb(74, 174, 233);\n    border-bottom: solid 3px rgb(74, 174, 233);\n    z-index: 999;\n}\n\n\n.absol-draggable-vstack.as-state-no-change::after {\n    visibility: hidden;\n}", ""]);



/***/ }),
/* 149 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-drop-panel-head {\n    height: 2.75em;\n    line-height: 2.75em;\n    -webkit-box-shadow: 0px 3px 4px -3px rgba(0, 0, 0, 0.75);\n    -moz-box-shadow: 0px 3px 4px -3px rgba(0, 0, 0, 0.75);\n    box-shadow: 0px 3px 4px -3px rgba(0, 0, 0, 0.75);\n    background-color: rgba(240, 240, 242);\n    color: black;\n}\n\n.absol-drop-panel-head .toggler-ico path {\n    fill: rgb(104, 104, 104);\n}\n\n\n.dark .absol-drop-panel-head {\n    background-color: rgba(54, 54, 56);\n    color: rgb(204, 204, 204);\n}\n\n.absol-drop-panel.show .absol-drop-panel-body {\n    height:auto;\n}\n\n.absol-drop-panel-body {\n    transition: height 0.2s;\n    height: 0;\n    overflow-x: hidden;\n    overflow-y: auto;\n}\n\n\n.absol-drop-panel.show>.absol-drop-panel-head  .toggle-close{\n    display: none;\n}\n\n.absol-drop-panel:not(.show)>.absol-drop-panel-head  .toggle-open{\n    display: none;\n}\n\n", ""]);



/***/ }),
/* 150 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(151);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 151 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-exp-node {\n    height: 2em;\n    text-align: left;\n    background-color: transparent;\n    border: none;\n    outline: none;\n    white-space: nowrap;\n    font-size: inherit;\n    overflow: hidden;\n    text-overflow: ellipsis;\n    position: relative;\n    color: rgb(33, 33, 34);\n}\n\n.absol-exp-node .toggler-ico {\n    width: 0.7em;\n    height: 0.7em;\n    margin-right: 0.35em;\n}\n\n.absol-exp-node .toggler-ico path {\n    fill: rgb(104, 104, 104);\n}\n\n.absol-exp-node.status-removable .toggler-ico,\n.absol-exp-node.status-modified .toggler-ico {\n    display: none;\n}\n\n.absol-exp-node:not(.status-open) .toggle-open {\n    display: none;\n}\n\n.absol-exp-node:not(.status-close) .toggle-close {\n    display: none;\n}\n\n\n\n.absol-exp-node:hover .remove-ico {\n    visibility: visible;\n}\n\n\n\n.absol-exp-node.status-removable .remove-ico,\n.absol-exp-node.status-modified .remove-ico {\n    display: inline-block;\n}\n\n.absol-exp-node.status-removable .remove-ico .modified {\n    visibility: hidden;\n}\n\n.absol-exp-node.status-modified .remove-ico .close {\n    visibility: hidden;\n}\n\n.absol-exp-node.status-modified .remove-ico:hover .close {\n    visibility: visible;\n}\n\n.absol-exp-node.status-modified .remove-ico:hover .modified {\n    visibility: hidden;\n}\n\n\n.absol-exp-node .remove-ico {\n    width: 0.9em;\n    height: 0.9em;\n    display: none;\n    visibility: hidden;\n    margin-left: -0.3em;\n    margin-right: 0.45em;\n}\n\n.absol-exp-node .remove-ico .close,\n.absol-exp-node .remove-ico .modified {\n    fill: rgb(169, 169, 169);\n    stroke: none;\n}\n\n\n.absol-exp-node.has-status {\n    padding-right: 2.5em;\n}\n\n.absol-exp-node>div,\n.absol-exp-node>svg {\n    display: inline-block;\n    vertical-align: middle;\n}\n\n\n.absol-exp-node .editing input {\n    color: khaki;\n    padding-top: 2px;\n    padding-bottom: 2px;\n}\n\n.absol-exp-node:hover {\n    background-color: var(--as-transparent-button-hover-color);\n}\n\n.absol-exp-node:focus,\n.absol-exp-node.as-active:focus {\n    background-color: var(--as-transparent-button-focus-color);\n}\n\n.absol-exp-node.as-active {\n    background-color: var(--as-transparent-button-active-color);\n}\n\n\n\n.absol-exp-node-name {\n    /* -webkit-touch-callout: none;\n    -webkit-user-select: none;\n    -khtml-user-select: none;\n    -moz-user-select: none;\n    -ms-user-select: none; */\n    user-select: none;\n    vertical-align: middle;\n    color: black;\n    margin-left: 0.5em;\n}\n\n.absol-exp-node-desc {\n    color: rgb(104, 104, 104);\n    margin-left: 0.5em;\n    font-size: 0.85em;\n}\n\n.absol-exp-node-desc:empty {\n    margin-left: 0;\n}\n\n\n.absol-exp-node-expand-icon {\n    display: inline-block;\n    vertical-align: middle;\n    margin-right: 0.2em;\n    height: 0.5em;\n    width: 0.5em;\n}\n\nimg.absol-exp-node-ext-icon {\n    display: none;\n}\n\n.absol-exp-node-ext-icon,\n.absol-exp-node-ext-icon>img {\n    display: inline-block;\n    vertical-align: middle;\n    width: 1.5em;\n    height: 1.5em;\n}\n\ndiv.absol-exp-node-ext-icon:empty {\n    display: none;\n}\n\ndiv.absol-exp-node-ext-icon {\n    text-align: center;\n}\n\n.absol-exp-node-ext-icon>.mdi,\n.absol-exp-node-ext-icon>span .absol-exp-node-ext-icon>svg {\n    line-height: 1em;\n    font-size: 1.5em;\n}\n\nimg.absol-exp-node-ext-icon[src] {\n    display: inline-block;\n}\n\n\n.absol-exp-tree>.absol-exp-node {\n    width: 100%;\n    display: block;\n}\n\n.absol-exp-tree.hide-children>.absol-exp-items {\n    display: none;\n}\n\n\n.dark .toggler-ico path {\n    fill: rgb(169, 169, 169);\n}\n\n\n.dark .absol-exp-node-name {\n    color: rgb(204, 204, 204);\n}\n\n.dark .absol-exp-node-desc {\n    color: rgb(169, 169, 170);\n}\n\n.dark .absol-exp-node {\n    color: rgb(169, 169, 170);\n}", ""]);



/***/ }),
/* 152 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(153);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 153 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, "\n.absol-editabe-text {\n    display: inline;\n}\n\n.absol-editabe-text span {\n    font-style: inherit;\n    font-size: inherit;\n    white-space: pre;\n}\n\n.absol-editabe-text-higne {\n    display: inline-block;\n    position: relative;\n    width: 0px;\n    height: 0ox;\n}\n\n.absol-editabe-text-higne input {\n    position: absolute;\n    display: none;\n    border: none;\n    top: -2;\n    left: -2;\n    padding-top: 0px;\n    padding-left: 2px;\n    padding-bottom: 4px;\n    margin: 0;\n    background: transparent;\n    outline: none;\n    font-style: inherit;\n    font-size: inherit;\n}\n\n.absol-editabe-text.editing .absol-editabe-text-higne input {\n    display: block;\n}\n\n.absol-editabe-text.editing span {\n    visibility: hidden;\n}\n\n.absol-editabe-text.editing {\n    -webkit-box-shadow: 0px 0px 2px 0px rgba(33, 77, 255, 1);\n    -moz-box-shadow: 0px 0px 2px 0px rgba(33, 77, 255, 1);\n    box-shadow: 0px 0px 2px 0px rgba(33, 77, 255, 1);\n    border-radius: 0.17em;\n}\n", ""]);



/***/ }),
/* 154 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(155);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 155 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-emoji-picker {\n    font-size: 12px;\n    border: 1px solid #dddddd;\n    box-sizing: border-box;\n    font-family: Arial, Helvetica, sans-serif;\n}\n\n.as-emoji-picker-preview {\n    display: inline-block;\n    vertical-align: top;\n    width: 80px;\n    height: 110px;\n    border-right: 1px solid #dddddd;\n    text-align: center;\n\n}\n\n\n.as-emoji-picker-preview-anim {\n    width: 60px;\n    height: 60px;\n    margin-top: 5px;\n}\n\n.as-emoji-picker-preview-desc {\n    font-size: 12px;\n    font-weight: bold;\n    color: black;\n}\n\n.as-emoji-picker-preview-shortcut {\n    font-size: 12px;\n    color: rgb(70, 70, 70);\n}\n\n\n.as-emoji-picker-list {\n    display: inline-block;\n    vertical-align: top;\n    overflow-y: auto;\n    width: calc(100% - 81px);\n    height: 110px;\n    padding: 5px;\n    box-sizing: border-box;\n}\n\n\n.as-emoji-picker-item {\n    display: inline-block;\n    padding: 5px;\n    width: 30px;\n    height: 30px;\n    box-sizing: border-box;\n    border-radius: 6px;\n}\n\n.as-emoji-picker-item:hover {\n    background-color: rgba(169, 169, 170, 0.3);\n}\n\n.as-emoji-picker-item:active {\n    background-color: rgba(169, 169, 170, 0.7);\n}", ""]);



/***/ }),
/* 156 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(157);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 157 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-flexicon-button {\n    box-sizing: border-box;\n    border: solid 1px #bfbfbf;\n    background-color: #ebebeb;\n    border-radius: 0.2em;\n    outline: none;\n    padding: 0;\n    overflow: hidden;\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.as-flexicon-button:disabled {\n    pointer-events: none;\n    background-color: #c7c7c7 !important;\n}\n\n\n.as-flexicon-button div,\n.as-flexicon-button span {\n    font-weight: inherit;\n    font-size: inherit;\n}\n\n\n.as-icon-button-table-box {\n    display: table;\n    width: 100%;\n    height: 100%;\n}\n\n.as-flexicon-button:hover .as-flexicon-button-content {\n    background-color: rgba(0, 0, 0, 0.1);\n}\n\n.as-flexicon-button:active {\n    -webkit-box-shadow: inset 0 0.2em 0.25em rgba(0, 0, 0, 0.125);\n    box-shadow: inset 0 0.2em 0.25em rgba(0, 0, 0, 0.125);\n}\n\n\n.as-flexicon-button-content {\n    display: table-row;\n}\n\n\n.as-flexicon-button-icon-container,\n.as-flexicon-button-text-container {\n    display: table-cell;\n    box-sizing: content-box;\n    vertical-align: middle;\n    text-align: center;\n}\n\n.as-flexicon-button-icon-container:empty,\n.as-flexicon-button-text-container:empty {\n    display: none;\n}\n\n.as-flexicon-button-icon-container {\n    width: 2em;\n    background-color: rgba(0, 0, 0, 0.0893617021);\n    color: rgb(146, 146, 146);\n}\n\n\n.as-flexicon-button-icon-container > span,\n.as-flexicon-button-icon-container > i,\n.as-flexicon-button-icon-container > svg,\n.as-flexicon-button-icon-container > img {\n    font-size: 1em;\n}\n\n.as-flexicon-button-text-container {\n    padding-left: 0.357em;\n    padding-right: 0.357em;\n    box-sizing: border-box;\n    min-width: 2em;\n}\n\n\n.as-flexicon-button-icon-container + .as-flexicon-button-text-container {\n    border-left: solid 1px #bfbfbf;\n}\n\n.as-flexicon-button-icon-container:empty + .as-flexicon-button-text-container {\n    border-left: none;\n    padding-left: 0.714em;\n    padding-right: 0.714em;\n}\n\n/*** theme  ***/\n\n.as-flexicon-button.primary {\n    border-color: #005bbd;\n    background-color: #007bff;\n    color: white;\n}\n\n.as-flexicon-button.primary .as-flexicon-button-icon-container {\n    color: white;\n}\n\n.as-flexicon-button.primary .as-flexicon-button-text-container {\n    border-color: #005bbd;\n}\n\n\n.as-flexicon-button.secondary {\n    border-color: #4e555a;\n    background-color: #6d767e;\n    color: white;\n}\n\n.as-flexicon-button.secondary .as-flexicon-button-icon-container {\n    color: white;\n}\n\n.as-flexicon-button.secondary .as-flexicon-button-text-container {\n    border-left-color: #4e555a;\n}\n\n\n.as-flexicon-button.success {\n    border-color: #1e7b34;\n    background-color: #29a847;\n    color: white;\n}\n\n.as-flexicon-button.success .as-flexicon-button-icon-container {\n    color: white;\n}\n\n.as-flexicon-button.success .as-flexicon-button-text-container {\n    border-left-color: #1e7b34;\n}\n\n\n.as-flexicon-button.danger {\n    border-color: #b21f2e;\n    background-color: #dc3848;\n    color: white;\n}\n\n.as-flexicon-button.danger .as-flexicon-button-icon-container {\n    color: white;\n}\n\n.as-flexicon-button.danger .as-flexicon-button-text-container {\n    border-left-color: #b21f2e;\n}\n\n.as-flexicon-button.warning {\n    border-color: #9e7700;\n    background-color: #e0a800;\n    color: black;\n}\n\n.as-flexicon-button.warning .as-flexicon-button-icon-container {\n    color: white;\n}\n\n.as-flexicon-button.warning .as-flexicon-button-text-container {\n    border-left-color: #9e7700;\n}\n\n.as-flexicon-button.info {\n    border-color: #117888;\n    background-color: #17a2b8;\n    color: white;\n}\n\n.as-flexicon-button.info .as-flexicon-button-icon-container {\n    color: white;\n}\n\n.as-flexicon-button.info .as-flexicon-button-text-container {\n    border-left-color: #117888;\n}\n\n.as-flexicon-button.light {\n    border-color: #c9d1d9;\n    background-color: #f8f9fa;\n    color: #212529;\n}\n\n.as-flexicon-button.light .as-flexicon-button-icon-container {\n    color: white;\n}\n\n.as-flexicon-button.light .as-flexicon-button-text-container {\n    border-left-color: #c9d1d9;\n}\n\n.as-flexicon-button.dark {\n    border-color: #171a1c;\n    background-color: #343a40;\n    color: white;\n}\n\n.as-flexicon-button.dark .as-flexicon-button-icon-container {\n    color: white;\n}\n\n.as-flexicon-button.dark .as-flexicon-button-text-container {\n    border-left-color: #171a1c;\n}\n\n.as-flexicon-button.link {\n    border-color: transparent;\n    background-color: transparent;\n    color: #007bff;\n}\n\n.as-flexicon-button.link .as-flexicon-button-icon-container {\n    color: #007bff;\n    background: transparent;\n}\n\n.as-flexicon-button.link .as-flexicon-button-text-container {\n    border-left-color: transparent;\n}\n\n.as-flexicon-button.link:hover .as-flexicon-button-text-container {\n    text-decoration: underline;\n}", ""]);



/***/ }),
/* 158 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(159);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 159 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-flexicon-input-icon-ctn > span,\n.as-flexicon-input-icon-ctn > i,\n.as-flexicon-input-icon-ctn > svg,\n.as-flexicon-input-icon-ctn > img {\n    font-size: 1em;\n    line-height: 1;\n}\n\n.as-flexicon-input {\n    position: relative;\n    border: 1px solid #dddddd;\n    display: inline-block;\n    vertical-align: middle;\n    height: 2em;\n    font-size: 14px;\n    box-sizing: border-box;\n    border-radius: 3px;\n    text-align: left;\n    white-space: nowrap;\n}\n\n.as-flexicon-input::before {\n    content: \"\";\n    width: 0;\n    height: 100%;\n    display: inline-block;\n    vertical-align: middle;\n}\n\n\n.as-flexicon-input-icon-ctn:empty {\n    display: none;\n}\n\n\n.as-flexicon-input:not(.as-flexicon-input-has-icon) input{\n    padding-left: 0.3em;\n}\n\n.as-flexicon-input-icon-ctn {\n    display: inline-block;\n    vertical-align: middle;\n    /*text-align: center;*/\n    font-size: 1.2em;\n    width: 1.25em;\n    text-align: center;\n}\n\n.as-flexicon-input-unit-ctn {\n    width: 1.5em;\n    display: inline-block;\n    vertical-align: middle;\n    text-align: center;\n}\n\n.as-flexicon-input-unit-ctn:empty {\n    display: none;\n}\n\n\n.as-flexicon-input input {\n    border: none;\n    font-size: 1em;\n    outline: none;\n    height: 100%;\n    background-color: transparent;\n    box-sizing: border-box;\n    width: 100%;\n    font-family: inherit;\n    padding-left: 0;\n    padding-right: 0;\n    display: inline-block;\n    vertical-align: middle;\n}\n\n\n.as-flexicon-input.as-flexicon-input-has-icon input,\n.as-flexicon-input.as-flexicon-input-has-unit input {\n    width: calc(100% - 1.5em);\n}\n\n.as-flexicon-input.as-flexicon-input-has-unit input{\n    text-align: right;\n}\n\n\n.as-flexicon-input.as-flexicon-input-has-icon.as-flexicon-input-has-unit input {\n    width: calc(100% - 3em);\n}", ""]);



/***/ }),
/* 160 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(161);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 161 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-frame{\n    \n}", ""]);



/***/ }),
/* 162 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(163);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 163 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-frame-view {\n    position: relative;\n}\n\n\n.absol-frame-view-frame-container {\n    position: absolute;\n    left: 0;\n    right: 0;\n    top: 0;\n    bottom: 0;\n}\n\n\n.absol-frame-view-frame-container:not(.absol-active) {\n    z-index: -100;\n    visibility: hidden;\n    opacity: 0;\n}\n\n.absol-frame-view-frame-container:not(.absol-active) *,\n.absol-frame-view-frame-container:not(.absol-active) {\n    pointer-events: none;\n    user-select: none;\n    -webkit-user-select: none;\n    -moz-user-select: none;\n}\n\n\n.absol-frame-view-frame-container > div {\n    width: 100%;\n    height: 100%;\n}", ""]);



/***/ }),
/* 164 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-tabbar {\n    white-space: normal;\n    height: 2em;\n    white-space: nowrap;\n}\n\n\n.absol-tabbar .absol-hscroller-viewport {\n    overflow-y: hidden;\n}\n\n.absol-tabbar .absol-tabbar-button {\n    height: 100%;\n}\n\n/* .absol-tabbar .absol-scrollbar-container {\n    height: 5px;\n} */\n\n.absol-tabbar .absol-scrollbar-container.horizontal {\n    bottom: -2px;\n}\n\n.absol-tabbar .absol-scrollbar-container {\n    opacity: 0;\n    transition: opacity 0.2s;\n    background: rgba(169, 169, 169, 0.1);\n}\n\n.absol-tabbar:hover .absol-scrollbar-container,\n.absol-tabbar:active .absol-scrollbar-container {\n    opacity: 1;\n}\n\n.absol-tabbar .absol-scrollbar-button {\n    background-color: rgba(33, 33, 40, 0.1);\n}\n\n.absol-tabbar .absol-scrollbar-button:hover {\n    background-color: rgba(33, 33, 40, 0.3);\n}\n\n\n.absol-tabbar .absol-scrollbar-button:active,\n.absol-tabbar .absol-hscrollbar.absol-active .absol-scrollbar-button {\n    background-color: rgba(47, 47, 55, 0.4);\n\n}\n\n\n.absol-tabbar-button {\n    padding-left: 1em;\n    padding-right: 1em;\n    background-color: rgb(45, 45, 45);\n    color: rgb(200, 200, 200);\n    margin-right: 1px;\n    border: none;\n    outline: none;\n    font-size: 1em;\n    white-space: nowrap;\n}\n\n\n.as-tab-bar-button-ext-icon-ctn:empty {\n    display: none\n}\n\n.as-tab-bar-button-ext-icon-ctn{\n    display: inline-block;\n    vertical-align: middle;\n    padding-right: 0.35em;\n    margin-left: -0.5em;\n}\n\n.absol-tabbar-button-text{\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.as-tab-bar-button-ext-icon-ctn span{\n    font-size: 1.2em;\n}\n\n\n\n.absol-tabbar .absol-tabbar-button-active {\n    background-color: rgb(30, 30, 30);\n    color: rgb(250, 250, 252);\n}\n\n.absol-tabbar-button-text,\n.absol-tabbar-button-icon-container > span {\n    display: inline;\n    vertical-align: middle;\n    font-size: 1em;\n}\n\n.absol-tabbar-button .absol-tabbar-button-close,\n.absol-tabbar-button .absol-tabbar-button-close-circle {\n    visibility: hidden;\n    color: rgb(190, 190, 190);\n}\n\n.absol-tabbar-button-icon-container {\n    display: inline-block;\n    vertical-align: middle;\n    margin-left: 0.5em;\n}\n\n\n.absol-tabbar-button:hover .absol-tabbar-button-close,\n.absol-tabbar-button-active .absol-tabbar-button-close,\n.absol-tabbar-button:hover .absol-tabbar-button-close-circle,\n.absol-tabbar-button-active .absol-tabbar-button-close-circle {\n    visibility: visible;\n    color: red;\n}\n\n.absol-tabbar-button-active .absol-tabbar-button-modified-flag {\n    color: lightblue;\n}\n\n.absol-tabbar-button-modified-flag {\n    color: mediumaquamarine;\n}\n\n.absol-tabbar-button:not(.absol-tabbar-button-modified) .absol-tabbar-button-modified-flag,\n.absol-tabbar-button.absol-tabbar-button-modified:not(.active) .absol-tabbar-button-icon-container:hover .absol-tabbar-button-modified-flag,\n.absol-tabbar-button.absol-tabbar-button-modified .absol-tabbar-button-icon-container:not(:hover) .absol-tabbar-button-close,\n.absol-tabbar-button:not(.absol-tabbar-button-modified) .absol-tabbar-button-icon-container:not(:hover) .absol-tabbar-button-close-circle,\n.absol-tabbar-button:not(.absol-tabbar-button-modified) .absol-tabbar-button-icon-container:hover .absol-tabbar-button-close,\n.absol-tabbar-button.absol-tabbar-button-modified .absol-tabbar-button-close-circle,\n.absol-tabbar-button.absol-tabbar-button-modified .absol-tabbar-button-icon-container:not(:hover) .absol-tabbar-button-close {\n    display: none;\n}\n\n\n.absol-button-range {\n}\n\n\n.absol-tabview {\n    position: relative;\n}\n\n\n.absol-tabview-container {\n    position: absolute;\n    top: 2em;\n    left: 0;\n    right: 0;\n    bottom: 0;\n    overflow: auto;\n}\n\n\n.absol-tabview-container.absol-tabview-container-hidden {\n    z-index: -9999;\n    visibility: hidden;\n    opacity: 0;\n\n}\n\n.absol-tabview-container.absol-tabview-container-hidden *,\n.absol-tabview-container.absol-tabview-container-hidden {\n    pointer-events: none;\n    user-select: none;\n    -webkit-user-select: none;\n    -moz-user-select: none;\n}\n\n\n.absol-tabview-container > div,\n.absol-tabview-container > pre {\n    width: 100%;\n    height: 100%;\n    box-sizing: border-box;\n}\n\n.absol-tabview-container > pre {\n    margin: 0;\n}\n\n.absol-tabview .absol-tabbar-button {\n    border-radius: 10px 10px 0 0;\n    height: 2em;\n    box-sizing: border-box;\n    border: solid 1px #ccc;\n    background-color: white;\n    color: black;\n    padding-left: 1em;\n    padding-right: 0.357em;\n    margin-right: 0.357em;\n}\n\n.absol-tabview .absol-tabbar {\n    height: 2em;\n    overflow-y: hidden;\n    border-bottom: 1px solid #ccc;\n    box-sizing: border-box;\n}\n\n.absol-tabview .absol-tabbar-button-active {\n    background-color: #5bc0de;\n    border-color: #46b8da;\n    color: white;\n}\n\n/* .absol-tabview .absol-tabbar-button-close {\n    color: rgb(170, 170, 170);\n    line-height: 1.5em;\n    margin-left: 1em;\n    font-size: 1.3em;\n} */\n\n.absol-tabview .absol-tabbar-button-close:hover {\n    color: red;\n}\n\n\n/************** Mini version - like window form ***********************/\n\n.absol-tabview.xp-tiny .absol-tabbar {\n    height: 22px;\n    border-bottom: none;\n}\n\n.absol-tabview.xp-tiny .absol-tabbar-button {\n    height: 20px;\n    padding-left: 5px;\n    padding-right: 5px;\n    border-radius: 0;\n    margin: 0;\n    vertical-align: bottom;\n    margin-top: 2px;\n    background-color: rgb(242, 242, 242);\n    color: black;\n    position: relative;\n}\n\n.absol-tabview.xp-tiny::before {\n    content: \"\";\n    position: absolute;\n    top: 18px;\n    z-index: 0;\n    left: 0;\n    right: 0;\n    height: 4px;\n    border-bottom: solid 1px #ccc;\n    box-sizing: border-box;\n}\n\n.absol-tabview.xp-tiny .absol-tabbar-button.absol-tabbar-button-active {\n    height: 22px;\n    margin-top: 0;\n    background-color: white;\n    border-top-color: #ccc;\n    border-left-color: #ccc;\n    border-right-color: #ccc;\n    border-bottom-color: white;\n}\n\n\n.absol-hscroller.absol-tabbar.disabled .absol-scrollbar-container {\n    visibility: hidden;\n}\n\n.absol-tabview.absol-tabview.xp-tiny .absol-tabbar-button-close {\n    line-height: 18px;\n}\n\n.absol-tabview.xp-tiny .absol-tabbar-button-icon-container {\n    display: none;\n}\n\n.absol-tabview.xp-tiny .absol-tabview-container {\n    top: 22px;\n}\n\n.absol-tabview.xp-tiny .absol-tab-absol {\n    border-left: solid 1px #ccc;\n    border-right: solid 1px #ccc;\n    border-bottom: solid 1px #ccc;\n    box-sizing: border-box;\n}\n\n\n.absol-tabview.as-without-close-button > .absol-tabbar .absol-tabbar-button .absol-tabbar-button-icon-container {\n    display: none;\n}\n\n.absol-tabview.as-without-close-button > .absol-tabbar .absol-tabbar-button {\n    padding-right: 1em;\n}\n\n/************************ Like Metro theme *********************/\n\n.absol-tabview.metro-flat > .absol-tabbar .absol-tabbar-button {\n    border-radius: 0;\n    margin-right: 0;\n    margin-left: 0;\n    border-left: none;\n    border-top: none;\n    border-bottom: none;\n    border-right: solid 1px rgba(169, 169, 169, 0.3);\n    font-size: 1em;\n}\n\n.absol-tabview.metro-flat > .absol-tabbar {\n    box-shadow: 0px -1px 0px 0px #ccc;\n}\n", ""]);



/***/ }),
/* 165 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(166);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 166 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-single-page {\n    position: relative;\n}\n\n\n.absol-single-page-header {\n    box-sizing: border-box;\n    z-index: 2;\n    display: block;\n}\n\n.absol-single-page-footer {\n    position: absolute;\n    left: 0;\n    right: 0;\n    bottom: 0;\n    box-sizing: border-box;\n}\n\n\n.absol-single-page-scroller-viewport {\n    min-height: 100%;\n    display: block;\n    position: relative;\n    box-sizing: border-box;\n}\n\n.absol-single-page-scroller {\n    position: absolute;\n    left: 0;\n    right: 0;\n    top: 0;\n    bottom: 0;\n    overflow-y: auto;\n}\n\n.absol-single-page.as-viewport-full > .absol-single-page-scroller > .absol-single-page-scroller-viewport {\n    height: 100%;\n    width: 100%;\n    overflow: hidden;\n}\n\n.absol-single-page.as-no-scroll > .absol-single-page-scroller {\n    overflow: hidden;\n}", ""]);



/***/ }),
/* 167 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(168);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 168 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-hexa-section-label {\n    position: relative;\n    -webkit-print-color-adjust: exact;\n    /*friendly print*/\n}\n\n.as-hexa-section-label-text {\n    position: relative;\n    display: inline-block;\n    vertical-align: middle;\n    font-size: 1em;\n    padding-right: 2.5em;\n    color: white;\n    font-weight: bold;\n    z-index: 2;\n}\n\n@media print {\n    .as-hexa-section-label-text {\n        color: white !important;\n    }\n\n    .as-hexa-section-label-index {\n        color: rgb(237, 147, 54) !important;\n    }\n}\n\n\n.as-hexa-section-label-index {\n    position: relative;\n    display: inline-block;\n    vertical-align: middle;\n    text-align: center;\n    color: rgb(237, 147, 54);\n    font-weight: 900;\n    z-index: 2;\n}\n\n.as-hexa-section-label-background {\n    position: absolute;\n    top: 0;\n    left: 0;\n    bottom: 0;\n    z-index: 1;\n}\n\n.as-hexa-section-label-background>svg {\n    display: block;\n}\n\n.as-hexa-section-label-index-box {\n    stroke: rgb(251, 186, 130);\n    fill: white;\n    stroke-width: 2.5;\n}\n\n.as-hexa-section-label-text-box {\n    fill: rgb(237, 147, 54);\n    stroke: none;\n}", ""]);



/***/ }),
/* 169 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(170);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 170 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, "/*margin for border size*/\n.as-vruler {\n    position: relative;\n    width: 1.5em;\n    border: solid 1px black;\n    overflow: hidden;\n    font-family: courier, \"courier new\", monospace;\n    box-sizing: border-box;\n}\n\n\n.as-vruler-line {\n    position: absolute;\n    right: 0;\n    width: 25%;\n    border-top: solid 1px rgb(17, 48, 43);\n    box-sizing: border-box;\n\n}\n\n.as-vruler-line.major {\n    width: 50%;\n    border-top: solid 1px rgb(5, 20, 18);\n}\n\n.as-vruler-major-number {\n    position: absolute;\n    text-align: center;\n    width:  5em;\n    pointer-events: none;\n    font-size: 0.7em;\n    right: calc(52% - 2em);\n    height: 1em;\n    transform-origin: center;\n    \n    -webkit-transform:rotate(90deg);\n    -moz-transform:rotate(90deg);\n    -o-transform: rotate(90deg);\n    -ms-transform:rotate(90deg);\n    transform: rotate(-90deg);\n}", ""]);



/***/ }),
/* 171 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(172);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 172 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, "/*margin for border size*/\n.as-hruler {\n    position: relative;\n    height: 1.5em;\n    border: solid 1px black;\n    overflow: hidden;\n    font-family: courier, \"courier new\", monospace;\n    box-sizing: border-box;\n}\n\n\n.as-hruler-line {\n    position: absolute;\n    bottom: 0;\n    height: 25%;\n    border-left: solid 1px rgb(17, 48, 43);\n    box-sizing: border-box;\n}\n\n.as-hruler-line.major {\n    height: 50%;\n    border-left: solid 1px rgb(5, 20, 18);\n}\n\n.as-hruler-major-number{\n    position: absolute;\n    text-align: center;\n    width: 5em;\n    pointer-events: none;\n    font-size: 0.7em;\n    bottom: 50%;\n} ", ""]);



/***/ }),
/* 173 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(174);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 174 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-linear-color-bar {\n    position: relative;\n    height: 2em;\n}\n\n.as-linear-color-background {\n    position: absolute;\n    top: 0;\n    left: 0;\n    right: 0;\n    bottom: 0;\n    display: block;\n}\n\n.as-linear-color-value-text {\n    position: absolute;\n    top: 0;\n    font-weight: 900;\n    white-space: nowrap;\n}\n\n.as-linear-color-min-value-text,\n.as-linear-color-max-value-text {\n    position: absolute;\n    bottom: 0;\n    white-space: nowrap;\n    font-weight: bold;\n}\n\n\n\n.as-linear-color-min-value-text {\n    left: 0;\n}\n\n.as-linear-color-rect {\n    stroke: none;\n}\n\n\n.as-linear-color-value-arrow {\n    fill: rgb(244, 124, 32);\n    stroke: rgb(244, 124, 32);\n}\n\n.as-linear-color-split-line {\n    stroke: white;\n}", ""]);



/***/ }),
/* 175 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(176);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 176 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".vmedia-no-show {\n    position: fixed;\n    top: 0;\n    left: 0;\n    width: 1;\n    height: 1;\n    z-index: -100000;\n    opacity: 0;\n}\n\n.vmedia-no-select,\n.vmedia-no-select * {\n    -webkit-user-select: none;\n    -moz-user-select: none;\n    -ms-user-select: none;\n    user-select: none;\n}\n\ncoccocgrammar {\n    display: none;\n}\n\n.vmedia-media-input {\n    box-sizing: border-box;\n    border: solid 1px rgba(0, 0, 0, 0.1)\n}\n\n\n.vmedia-media-input-text-container {\n    position: relative;\n    min-height: 2.5em;\n}\n\n.vmedia-media-input-text-container-editor:focus {\n    outline: none;\n}\n\n.vmedia-media-input-text-container-editor img {\n    display: none;\n}\n\n.vmedia-media-input-text-container-editor * {\n    font-family: inherit;\n    font-size: inherit;\n    font-weight: inherit;\n    text-decoration: inherit;\n    color: inherit;\n    background: none;\n    padding: 0;\n    margin: 0;\n    white-space: pre;\n}\n\n.vmedia-media-input-text-container-editor {\n    min-height: 2em;\n    padding-left: 0.5em;\n    padding-top: 0.25em;\n    padding-bottom: 0.25em;\n    margin-right: 0.5em;\n    box-sizing: border-box;\n    max-height: 6.66666666em;\n    overflow-x: hidden;\n    overflow-y: auto;\n}\n\n.vmedia-media-input-imagepreview-container {\n    white-space: normal;\n}\n\n.vmedia-media-input:not(.dragover) .vmedia-media-input-dropover {\n    display: none;\n}\n\n.vmedia-media-input-dropover {\n    display: inline-block;\n    width: 7em;\n    height: 7em;\n}\n\n.vmedia-media-input-dropover>svg {\n    width: 7em;\n    height: 7em;\n}\n\n.vmedia-media-input-imagepreview-container .vmedia-media-input-filepreview,\n.vmedia-media-input-imagepreview-container .vmedia-media-input-imagepreview {\n    margin: 0.3em;\n    vertical-align: middle;\n}\n\n.vmedia-media-input-filepreview,\n.vmedia-media-input-imagepreview {\n    position: relative;\n    display: inline-block;\n}\n\n.vmedia-media-input-imagepreview img {\n    height: 2.5em;\n    width: auto;\n}\n\n.vmedia-media-input-filepreview svg.attachment {\n    height: 2em;\n    width: 2em;\n}\n\n.vmedia-media-input-filepreview svg.times,\n.vmedia-media-input-imagepreview svg.times {\n    position: absolute;\n    top: 0.1em;\n    right: 0.1em;\n    width: 1em;\n    height: 1em;\n    fill: rgba(69, 69, 69, 0.6);\n}\n\n.vmedia-media-input-filepreview svg.times:hover,\n.vmedia-media-input-imagepreview svg.times:hover {\n    fill: rgba(144, 144, 144, 0.6);\n}\n\n.vmedia-media-input-filepreview svg.times:active,\n.vmedia-media-input-imagepreview svg.times:active {\n    fill: rgba(220, 220, 240, 0.6);\n}\n\n.vmedia-media-input-plug-button-container {\n    position: absolute;\n    left: 0.25em;\n    bottom: 0.25em;\n    top: 0.25em;\n}\n\n.vmedia-media-input-plug-button-container svg {\n    height: 1.5em;\n    width: 1.5em;\n    vertical-align: middle;\n    transition: transform .22s cubic-bezier(.5, 0, .4, 1);\n}\n\n\n.vmedia-media-input-plug-button-container svg path {\n    fill: rgba(66, 133, 244, 0.7);\n    transition: fill .22s cubic-bezier(.5, 0, .4, 1);\n}\n\n.vmedia-media-input.show-plugin .vmedia-media-input-plug-button svg path {\n    fill: rgba(134, 142, 153, 0.75);\n}\n\n\n\n.vmedia-media-input-plug-button {\n    padding: 0;\n    height: 100%;\n    width: 2em;\n    border: none;\n    background: transparent;\n    outline: none;\n\n}\n\n\n.vmedia-media-input-plugin-content-container {\n    position: absolute;\n    bottom: calc(1px + 100%);\n    opacity: 1;\n    transition: opacity .22s cubic-bezier(.5, 0, .4, 1);\n    background-color: white;\n    box-sizing: border-box;\n    border: solid 1px rgba(0, 0, 0, 0.1);\n    z-index: 20;\n    background: white;\n}\n\n.vmedia-media-input-plugin-content-container:empty{\n    display: none;\n}\n\n\n\n.vmedia-media-input-tool-container {\n    position: relative;\n    display: block;\n    height: 1.5em;\n    /* background: red;     */\n}\n\n\n\n.vmedia-media-input-tool-container-left {\n    position: absolute;\n    left: 0;\n    top: 0;\n    bottom: 0;\n}\n\n.vmedia-media-input-tool-container-right {\n    position: absolute;\n    right: 0;\n    top: 0;\n    bottom: 0;\n}\n\n.vmedia-media-input-tool-container button {\n    width: 2.5em;\n    height: 100%;\n    font-size: 1em;\n    margin-left: 0.1em;\n    margin-right: 0.1em;\n    border: none;\n    background-color: transparent;\n    border-radius: 0.4em;\n}\n\n.vmedia-media-input-text-container-editor {\n    scrollbar-width: thin;\n}\n\n.vmedia-media-input-text-container-editor::-webkit-scrollbar {\n    width: 7px;\n}\n\n\n\n.vmedia-media-input-text-container-editor::-webkit-scrollbar-track {\n    background: rgb(240, 240, 240);\n}\n\n.vmedia-media-input-text-container-editor::-webkit-scrollbar-thumb {\n    background: rgb(205, 205, 205);\n}\n\n.vmedia-media-input-tool-container button svg {\n    height: 1.25em;\n    width: 1.25em;\n}\n\n.vmedia-media-input-tool-container button:hover {\n    background-color: rgba(91, 192, 222, 0.1);\n}\n\n.vmedia-media-input-tool-container button:active {\n    background-color: rgba(91, 192, 222, 0.4);\n}\n\n.vmedia-media-input-tool-container button svg.send {\n    fill: rgba(66, 133, 244, 0.7);\n}\n\n.vmedia-media-input-tool-container button svg.add-file,\n.vmedia-media-input-tool-container button svg.add-image {\n    fill: rgba(66, 66, 66, 0.5);\n}\n\n.vmedia-media-input-tool-container button .mdi{\n    font-size:1.2em; \n}\n\n.vmedia-media-input-tool-container button:focus {\n    outline: none;\n}\n\n.vmedia-media-input-tool-container button{\n    vertical-align: middle;\n}\n\n.vmedia-media-input-plugin-content-container.blur{\n    visibility: hidden;\n}", ""]);



/***/ }),
/* 177 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(178);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 178 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-conversation-box {\n    display: flex;\n    flex-direction: column;\n}\n\n.as-conversation-box-message-ctn {\n    flex-grow: 1;\n}\n\n.as-conversation-box-input-ctn {\n    /** empty**/\n}\n\n.as-message-input {\n    position: relative;\n    box-sizing: border-box;\n    padding-top: 5px;\n    padding-bottom: 5px;\n    padding-left: 5px;\n    overflow: visible;\n    --plugin-buttons-width: 0px;\n    font-size: var(--as-input-font-size);\n    font-family: var(--as-input-font-family);\n}\n\n.as-message-input * {\n    font: inherit;\n}\n\n\n.as-message-input-plugin-btn {\n    width: 40px;\n    height: 40px;\n    padding: 0;\n    border: none;\n    color: rgb(122, 122, 122);\n    background-color: rgb(241, 241, 241);\n    outline: none;\n    border-radius: 50%;\n    display: inline-block;\n    vertical-align: middle;\n}\n\n\n.as-message-input-plugin-btn:active {\n    background-color: rgb(212, 212, 212);\n}\n\n.as-message-input-plugin-btn:hover {\n    background-color: rgb(235, 235, 235);\n\n}\n\n\n.as-message-input-plugin-btn span {\n    font-size: 24px;\n}\n\n\n.as-message-input-right {\n    position: absolute;\n    bottom: 10px;\n    right: 5px;\n    z-index: 0;\n    white-space: nowrap;\n}\n\n.as-message-input-right .as-message-input-plugin-btn {\n    margin-left: 10px;\n}\n\n\n.as-message-input-emoji-btn-ctn {\n    position: absolute;\n    left: 5px;\n    bottom: 5px;\n}\n\n\n.as-message-input-pre-ctn {\n    position: relative;\n    width: calc(100% - 55px - var(--plugin-buttons-width));\n    border-radius: 25px;\n    box-sizing: border-box;\n    transition: width 0.1s;\n    padding: 10px 20px 10px 50px;\n    background-color: rgb(241, 241, 244);\n}\n\n\n.as-message-input-pre-ctn::after {\n    display: inline-block;\n    content: \"\";\n    height: 30px;\n    vertical-align: middle;\n}\n\n\n.as-message-input.as-has-text .as-message-input-pre-ctn,\n.as-message-input.as-has-quote .as-message-input-pre-ctn,\n.as-message-input.as-has-attachment .as-message-input-pre-ctn {\n    width: calc(100% - 55px);\n}\n\n\n.as-message-input-pre {\n    display: inline-block;\n    width: calc(100% - 2px);\n    max-height: 6.5em;\n    box-sizing: border-box;\n    font-family: inherit;\n    font-size: inherit;\n    outline: none;\n    vertical-align: middle;\n    margin: 0;\n    white-space: pre-wrap;\n    overflow-x: hidden;\n    overflow-y: auto;\n    line-height: 1.5;\n    border: none;\n}\n\n.as-message-input-pre:before {\n    content: \"\";\n    line-height: 30px;\n    display: inline;\n    vertical-align: middle;\n}\n\n.as-message-input-camera-caller,\n.as-message-input-camera-microphone {\n    display: none;\n}\n\n.as-message-input-emoji-picker-ctn {\n    position: absolute;\n    bottom: 100%;\n    left: 0;\n    right: 0;\n    user-select: none;\n    -webkit-user-select: none;\n    background-color: white;\n}\n\n\n.as-message-input-plugin-btn.as-message-input-plugin-send {\n    color: white;\n    background: linear-gradient(135deg, rgb(0, 120, 212), rgb(0, 188, 242));\n    transform: scale(1);\n    transition: scale 0.1s;\n}\n\n.as-message-input-plugin-btn.as-message-input-plugin-send span {\n    font-size: 20px;\n}\n\n.as-message-input-plugin-btn.as-message-input-plugin-send:hover {\n    background: linear-gradient(135deg, rgb(0, 140, 212), rgb(0, 208, 252));\n}\n\n.as-message-input-plugin-btn.as-message-input-plugin-send:active {\n    transform: scale(0.9);\n}\n\n\n.as-message-input:not(.as-text-changed):not(.as-has-attachment):not(.as-has-quote) .as-message-input-plugin-send,\n.as-message-input:not(.as-has-text):not(.as-has-attachment):not(.as-has-quote) .as-message-input-plugin-send,\n.as-message-input:not(.as-mode-edit) .as-message-input-plugin-cancel,\n.as-message-input.as-mode-edit.as-text-changed.as-has-text .as-message-input-plugin-cancel,\n.as-message-input:not(.as-has-attachment):not(.as-drag-hover) .as-message-input-attachment-ctn,\n.as-message-input.as-auto-send .as-message-input-attachment-ctn,\n.as-message-input.as-mode-edit .as-message-input-plugin-file,\n.as-message-input.as-has-text .as-message-input-plugin-file,\n.as-message-input.as-has-quote .as-message-input-plugin-file,\n.as-message-input:not(.as-has-quote) .as-message-quote-box {\n    display: none;\n}\n\n.as-message-input .as-message-quote-box {\n    border-bottom: 1px solid #ddd;\n}\n\n.as-message-quote-box {\n    position: relative;\n\n}\n\n.as-message-input.as-has-attachment .as-message-quote-box {\n    margin-bottom: 5px;\n}\n\n.as-message-quote-remove-btn {\n    position: absolute;\n    color: rgb(43, 44, 51);\n    right: -7px;\n    top: 5px;\n    width: 20px;\n    height: 20px;\n    padding: 0;\n    background: transparent;\n    border: none;\n    border-radius: 50%;\n    font-size: 16px;\n    outline: none;\n}\n\n.as-message-quote-remove-btn:hover {\n    color: rgb(143, 144, 151);\n}\n\n.as-message-quote-box {\n    user-select: none;\n    -webkit-user-select: none;\n}\n\n.as-message-quote-box:not(.as-removable) .as-message-quote-remove-btn {\n    display: none;\n}\n\n\n.as-message-quote-box > div {\n    display: inline-block;\n    vertical-align: top;\n}\n\n.as-message-quote-box:not(.as-has-img):not(.as-has-file) .as-message-quote-img {\n    display: none;\n}\n\n.as-message-quote-img {\n    width: 40px;\n    height: 40px;\n    padding: 5px;\n    box-sizing: border-box;\n    background-size: cover;\n    background-origin: border-box;\n    background-position: center;\n    background-repeat: no-repeat;\n}\n\n.as-message-quote-sym {\n    width: 25px;\n}\n\n.as-message-quote-sym > span {\n    font-size: 25px;\n    color: rgb(169, 169, 172);\n}\n\n.as-message-quote-content {\n    font-family: \"Helvetica Neue\", Arial, Helvetica, sans-serif;\n    width: calc(100% - 26px);\n    box-sizing: border-box;\n    padding-left: 20px;\n}\n\n.as-message-quote-box.as-has-img .as-message-quote-content,\n.as-message-quote-box.as-has-file .as-message-quote-content {\n    width: calc(100% - 66px);\n    padding-left: 5px;\n}\n\n.as-message-quote-box.as-has-file .as-message-quote-img {\n    background-origin: padding-box;\n    background-size: contain;\n}\n\n.as-message-quote-text {\n    font-size: 1.14em;\n    line-height: 1.75;\n    font-style: italic;\n    color: rgb(43, 44, 51);\n    max-width: 100%;\n    word-break: break-word;\n    white-space: pre-wrap;\n}\n\n.as-message-quote-box.as-shorten-text .as-message-quote-text {\n    word-break: normal;\n\n    overflow: hidden;\n    white-space: nowrap;\n    text-overflow: ellipsis;\n}\n\n.as-message-quote-text .as-emoji {\n    width: 20px;\n    height: 20px;\n}\n\n.as-message-quote-desc {\n    font-size: 0.85em;\n    color: rgb(80, 80, 88);\n}\n\n.as-message-input-attachment-ctn {\n    border-bottom: 1px solid #ddd;\n    max-height: 170px;\n    overflow-y: auto;\n}\n\n\n.as-message-input-attach-preview {\n    display: inline-block;\n    position: relative;\n    width: 135px;\n    height: 135px;\n    vertical-align: middle;\n    margin-right: 5px;\n    margin-bottom: 5px;\n    border-radius: 10px;\n    background-color: white;\n    overflow: hidden;\n}\n\n.as-message-input-attach-preview-image {\n    min-width: 20px;\n    image-orientation: from-image;\n    width: 100%;\n    height: 100%;\n    background-size: cover;\n    background-position: center center;\n    background-repeat: no-repeat;\n}\n\n\n.as-message-input-attach-preview-file {\n    max-width: 50%;\n    max-height: 50%;\n    margin-left: 10px;\n    margin-top: 10px;\n}\n\n.as-message-input-attach-preview-close-btn {\n    position: absolute;\n    right: 10px;\n    top: 10px;\n    width: 18px;\n    height: 18px;\n    border-radius: 50%;\n    text-align: center;\n    border: 1px solid white;\n    outline: none;\n    padding: 0;\n    color: white;\n    -webkit-box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.64);\n    -moz-box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.64);\n    box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.64);\n    background-color: rgba(100, 100, 100, 0.5);\n}\n\n.as-message-input-attach-preview-close-btn span {\n    font-size: 14px;\n}\n\n.as-message-input-attach-preview-close-btn:hover {\n    background-color: rgba(255, 255, 255, 0.5);\n    color: rgb(200, 200, 200);\n}\n\n.as-message-input-attach-preview-close-btn:active {\n    background-color: rgba(255, 255, 255, 0.7);\n    color: rgb(255, 255, 255);\n}\n\n\n.as-message-input:not(.as-drag-hover) .as-message-input-attachment-add-btn-drop,\n.as-message-input.as-drag-hover .as-message-input-attachment-add-btn-plus {\n    display: none;\n}\n\n\n.as-message-input-attach-preview-info {\n    position: absolute;\n    left: 10px;\n    bottom: 10px;\n    right: 10px;\n    max-height: calc(100% - 20px);\n    text-shadow: 0px 1px 3px white;\n    color: black;\n    font-size: 14px;\n    font-family: Arial, Helvetica, sans-serif;\n}\n\n.as-message-input-attach-preview-name {\n    overflow: hidden;\n    text-overflow: ellipsis;\n}\n\n.as-message-input-attach-preview-size {\n    color: #42494c;\n}\n\n.as-message-input-attachment-add-btn {\n    display: inline-block;\n    vertical-align: middle;\n    height: 135px;\n    width: 60px;\n    border: none;\n    border-radius: 10px;\n    padding: 0;\n    background-color: rgb(196, 196, 200);\n    color: white;\n    font-size: 50px;\n    outline: none;\n    margin-bottom: 10px;\n}\n\n.as-message-input-attachment-add-btn:hover {\n    background-color: rgb(169, 169, 169)\n\n}\n\n.as-message-input-attachment-add-btn:active {\n    background-color: rgb(138, 141, 145)\n}\n\n.as-message-input-external-tools-popup {\n    position: absolute;\n    left: 0;\n    max-width: 100%;\n    bottom: 100%;\n    background-color: white;\n}\n\nimg.as-emoji {\n    vertical-align: bottom;\n}\n\nspan.as-emoji-text {\n    position: absolute;\n    color: transparent;\n    width: 20px;\n    opacity: 0;\n}", ""]);



/***/ }),
/* 179 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(180);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 180 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-number-input {\n    text-align: right;\n    display: inline-block;\n    vertical-align: middle;\n    position: relative;\n    min-width: calc(1em + 2px);\n    height: calc(2em + 2px);\n    border: solid 1px #d6d6d6;\n    font-size: 14px;\n    box-sizing: border-box;\n    width: 4em;\n}\n\n.absol-number-input-button-up-container {\n    top: 0;\n}\n\n.absol-number-input-button-down-container {\n    bottom: 0;\n}\n\n.absol-number-input-button-up-container,\n.absol-number-input-button-down-container {\n    right: 0;\n    position: absolute;\n    height: 1em;\n    width: 1em;\n    max-height: 50%;\n}\n\n.absol-number-input-button-up-container > button,\n.absol-number-input-button-down-container > button {\n    width: 100%;\n    height: 100%;\n    line-height: 1;\n    padding: 0;\n    border: none;\n    box-sizing: border-box;\n    outline: none;\n    color: rgb(101, 101, 101);\n    background-color: transparent;\n}\n\n.absol-number-input-button-up-container > button:active,\n.absol-number-input-button-down-container > button:active {\n    color: black;\n    background-color: rgba(101, 101, 101, 0.3);\n}\n\n.absol-number-input-text-container {\n    left: 0em;\n    right: 1.2em;\n    top: 0;\n    bottom: 0;\n    position: absolute;\n}\n\n\n.absol-number-input-text-container > input[type=\"text\"] {\n    border: none;\n    outline: none;\n    width: 100%;\n    height: 100%;\n    text-align: right;\n    padding: 0 0.2em;\n    box-sizing: border-box;\n}\n\n.absol-number-input.absol-disabled {\n    pointer-events: none;\n    color: var(--as-disabled-text-color);\n}\n\n.absol-number-input.absol-disabled input {\n    background-color: var(--as-disabled-background-color);\n}\n\n.absol-number-input.absol-disabled .absol-number-input-button-up-container,\n.absol-number-input.absol-disabled .absol-number-input-button-down-container {\n    opacity: 0.3;\n}", ""]);



/***/ }),
/* 181 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(182);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 182 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-onscreen-window {\n    z-index: 1002;\n    position: fixed;\n    left: 10px;\n    top: 10px;\n    width: 12em;\n    height: 5em;\n    /*default size*/\n    /* min-width: 12em;\n    min-height: 1.4em; */\n}\n\n.absol-onscreen-window-content {\n    position: relative;\n    width: 100%;\n    height: 100%;\n    background: white;\n    -webkit-box-shadow: 2px 2px 17px -1px rgba(0, 0, 0, 0.54);\n    -moz-box-shadow: 2px 2px 17px -1px rgba(0, 0, 0, 0.54);\n    box-shadow: 2px 2px 17px -1px rgba(0, 0, 0, 0.54);\n}\n\n.absol-onscreen-window-head-bar {\n    height: 1.4em;\n    position: relative;\n    background-color: rgba(169, 169, 169, 0.15);\n    padding: 0.2em;\n    box-sizing: border-box;\n}\n\n.absol-onscreen-window-head-bar-icon{\n    margin-right: 0.2em;\n    font-size: inherit;\n}\n\nspan.absol-onscreen-window-head-bar-icon {\n    line-height: 1.2em;\n}\n\nsvg.absol-onscreen-window-head-bar-icon{\n    width: 1.2em;\n    height: 1.2em;\n}\n\nspan.absol-onscreen-window-head-bar-title {\n    line-height: 1.2em;\n    font-size: 1em;\n    color: rgb(33, 33, 34);\n}\n\n.absol-onscreen-window-head-bar-buttons {\n    position: absolute;\n    right: 0.1em;\n    top: 0.1em;\n    bottom: 0.1em;\n}\n\n.absol-onscreen-window-head-bar-buttons>button {\n    height: 100%;\n    width: 1em;\n    font-size: 1em;\n    padding: 0;\n    margin: 0 0 0 0.1em;\n    border: none;\n    color: rgb(169, 169, 169);\n    outline: none;\n}\n\n.absol-onscreen-window-head-bar-buttons>button:hover {\n    color: rgb(103, 103, 103);\n}\n\n.absol-onscreen-window-head-bar-buttons>button:active {\n    color: rgb(33, 33, 34);\n}\n\n.absol-onscreen-window-head-bar-buttons>button:hover>.mdi-close {\n    color: rgb(255, 59, 59);\n}\n\n.absol-onscreen-window-head-bar-buttons>button>span {\n    vertical-align: middle;\n}\n\n.absol-onscreen-window-body-container {\n    position: absolute;\n    left: 0;\n    right: 0;\n    top: 1.4em;\n    bottom: 0;\n}\n\n\n.absol-onscreen-window-moving-modal {\n    position: fixed;\n    left: 1px;\n    right: 1px;\n    top: 1px;\n    bottom: 1px;\n    z-index: 100006;\n}\n\n.absol-onscreen-window-resizer {\n    position: absolute;\n}\n\n.absol-onscreen-window-resizer.absol-onscreen-window-resize-bottom {\n    bottom: -3px;\n    height: 6px;\n    left: 3px;\n    right: 3px;\n    z-index: 3;\n}\n\n.absol-onscreen-window-resizer.absol-onscreen-window-resize-top {\n    top: -3px;\n    height: 6px;\n    left: 3px;\n    right: 3px;\n    z-index: 3;\n}\n\n.absol-onscreen-window-resizer.absol-onscreen-window-resize-left {\n    left: -3px;\n    top: 3px;\n    bottom: 3px;\n    width: 6px;\n    cursor: ew-resize;\n}\n\n.absol-onscreen-window-resizer.absol-onscreen-window-resize-right {\n    right: -3px;\n    top: 3px;\n    bottom: 3px;\n    width: 6px;\n    cursor: ew-resize;\n}\n\n.absol-onscreen-window-resizer.absol-onscreen-window-resize-bottom-right {\n    width: 6px;\n    height: 6px;\n    right: -3px;\n    bottom: -3px;\n}\n\n.absol-onscreen-window-resizer.absol-onscreen-window-resize-bottom-left {\n    width: 6px;\n    height: 6px;\n    left: -3px;\n    bottom: -3px;\n}\n\n.absol-onscreen-window-resizer.absol-onscreen-window-resize-top-left {\n    width: 6px;\n    height: 6px;\n    left: -3px;\n    top: -3px;\n}\n\n.absol-onscreen-window-resizer.absol-onscreen-window-resize-top-right {\n    width: 6px;\n    height: 6px;\n    right: -3px;\n    top: -3px;\n}\n\n\n.absol-onscreen-window-resize-top,\n.absol-onscreen-window-resize-bottom {\n    cursor: ns-resize;\n\n}\n\n.absol-onscreen-window-resize-left,\n.absol-onscreen-window-resize-right {\n    cursor: ew-resize;\n\n}\n\n\n.absol-onscreen-window-resize-bottom-right {\n    cursor: se-resize;\n}\n\n.absol-onscreen-window-resize-bottom-left {\n    cursor: sw-resize;\n}\n\n.absol-onscreen-window-resize-top-left {\n    cursor: nw-resize;\n}\n\n.absol-onscreen-window-resize-top-right {\n    cursor: ne-resize;\n}", ""]);



/***/ }),
/* 183 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(184);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 184 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-page-selector{\n    white-space: normal;\n    user-select: none;\n    -webkit-user-select: none;\n    -moz-user-select: none;\n}\n\n.absol-page-selector > ul{\n    margin-bottom: 0px;\n    margin-top: 0;\n}\n\n.absol-page-number-buttons{\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.absol-page-number-input > label{\n    font-weight: 100;\n}\n\n.absol-page-number-buttons > li.page-previous, \n.absol-page-number-buttons > li.page-next,\n.absol-page-number-buttons > li.page-first,\n.absol-page-number-buttons > li.page-last\n{\n    display: inline-block;\n    height: 30px;\n    padding-left: 10px;\n    padding-right: 10px;\n    text-align: center;\n    transition: all .3s linear;\n    background-color: transparent;\n    cursor: pointer;\n}\n\n.absol-page-number-buttons > li.absol-page-number{\n    display: inline-block;\n    height: 30px;\n    width: 40px;\n    text-align: center;\n    transition: all .3s linear;\n    background-color: transparent;\n    cursor: pointer;\n}\n\n\n.absol-page-number-buttons > li.absol-page-number.active{\n    box-shadow:  0 2px 5px 0 rgba(0,0,0,.16), 0 2px 10px 0 rgba(0,0,0,.12);\n    background-color: #4285f4;\n    border-radius:2px; \n    \n}\n\n.absol-page-number-buttons > li.absol-page-number.active > a{\n\tcolor: white;\n    \n}\n\n.absol-page-number-buttons > li> a{\n    line-height: 30px;\n    text-decoration:none;\n    outline: none;\n}\n\n.absol-page-number-buttons > li:not(.active):hover{\n    background-color: #eee;\n\n}\n\n.absol-page-selector .absol-page-number-input{\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.absol-page-selector .absol-page-number-input  input[type=\"text\"]{\n    width: 3em;\n    margin-left: 5px; \n    margin-right: 10px;\n    text-align: center;\n    height: 26px;\n    border: none;\n    border: solid 1px #ccc; \n    border-radius: 2px;\n\n}\n\n.absol-page-link {\n    color: #147af6;\n    cursor: pointer;\n    text-decoration: underline;\n}\n\n.absol-page-number {\n    color: #147af6;\n    cursor: pointer;\n}", ""]);



/***/ }),
/* 185 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(186);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 186 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-preinput {\n    margin: 0;\n    padding: 0;\n    white-space: pre-wrap;\n    -moz-user-modify: read-write;\n    -webkit-user-modify: read-write;\n    word-break: normal;\n}\npre.as-preinput{\n    word-break: normal;\n}\n\n\n.as-preinput img {\n    display: none;\n}", ""]);



/***/ }),
/* 187 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(188);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 188 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-progress-bar {\n    height: 1em;\n    background-color: #e9ecef;\n    border-radius: .25em;\n    box-sizing: border-box;\n    overflow: hidden;\n}\n\n\n.as-progress-bar-value {\n    height: 100%;\n    width: 0;\n    color: #fff;\n    text-align: center;\n    white-space: nowrap;\n    background-color: #007bff;\n    transition: width .6s ease;\n}\n\n.as-progress-bar.as-variant-success .as-progress-bar-value {\n    background-color: #28a745;\n}\n\n.as-progress-bar.as-variant-info .as-progress-bar-value {\n    background-color: #17a2b8;\n}\n\n.as-progress-bar.as-variant-warning .as-progress-bar-value {\n    background-color: #ffc107;\n}\n\n.as-progress-bar.as-variant-danger .as-progress-bar-value {\n    background-color: #dc3545;\n}\n\n\n.as-progress-bar.as-striped .as-progress-bar-value,\n.as-progress-bar.as-animated .as-progress-bar-value {\n    background-image: linear-gradient(45deg, hsla(0, 0%, 100%, .15) 25%, transparent 0, transparent 50%, hsla(0, 0%, 100%, .15) 0, hsla(0, 0%, 100%, .15) 75%, transparent 0, transparent);\n    background-size: 1.33333em 1.33333em;\n}\n\n@keyframes as-progress-bar-stripes {\n    0% {\n        background-position: 1.33333em 0\n    }\n\n    to {\n        background-position: 0 0\n    }\n}\n\n.as-progress-bar.as-animated .as-progress-bar-value {\n    animation: as-progress-bar-stripes 1s linear infinite;\n}", ""]);



/***/ }),
/* 189 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(190);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 190 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-quick-list-button {\n    box-sizing: border-box;\n    height: calc(2em + 2px);\n    font-size: 14px;\n}\n\n.as-quick-list-button .as-flexicon-button-text-container {\n    border-right: solid 1px #bfbfbf;\n}\n\n\n.as-quick-list-button-follower .absol-selectlist {\n    max-height: calc(100vh - 20px);\n    overflow-y: auto;\n    border: solid 1px rgb(100, 100, 255);\n    box-sizing: border-box;\n    background-color: white;\n    display: inline-block;\n    vertical-align: top;\n    -webkit-box-shadow: 2px 2px 6px 0px rgba(0, 0, 90, 0.55);\n    -moz-box-shadow: 2px 2px 6px 0px rgba(0, 0, 90, 0.55);\n    box-shadow: 2px 2px 6px 0px rgba(0, 0, 90, 0.55);\n}", ""]);



/***/ }),
/* 191 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-selectlist {\n    font-family: \"Helvetica Neue\", Arial, Helvetica, sans-serif;\n}\n\n.absol-selectlist * {\n    box-sizing: border-box;\n}\n\n.absol-selectlist .absol-selectlist-item:hover {\n    background-color: #efefef;\n}\n\n.absol-selectlist .absol-selectlist-item {\n    height: 20px;\n    font-size: 14px;\n    cursor: pointer;\n}\n\n.absol-selectlist-item.as-selected {\n    background-color: #dfdfdf;\n}\n\n\n.absol-selectlist:not(.as-searching)>.absol-selectlist-item.as-last-in-group:not(:last-child) {\n    border-bottom: 1px solid #dddddd;\n}\n\n.absol-selectlist-item>span {\n    line-height: 20px;\n    white-space: pre;\n    padding-left: var(--as-input-horizontal-padding);\n    padding-right: var(--as-input-horizontal-padding);\n    -webkit-user-select: none;\n    -moz-user-select: none;\n    -ms-user-select: none;\n    user-select: none;\n}\n\n.absol-selectlist-item {\n    position: relative;\n    box-sizing: border-box;\n}\n\n.absol-selectlist-item-desc-container {\n    position: absolute;\n    right: 0.3em;\n    top: 0;\n    bottom: 0;\n}\n\n.absol-selectlist-item-desc {\n    font-style: italic;\n    line-height: 20px;\n    white-space: nowrap;\n    color: rgb(37, 37, 37);\n}\n\n.absol-selectlist-item-desc:empty {\n    display: none;\n}\n\n\n", ""]);



/***/ }),
/* 192 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(193);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 193 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-checkbox-button{\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.as-checkbox-button .absol-checkbox-icon{\n    display: block;\n}", ""]);



/***/ }),
/* 194 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(195);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 195 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-quick-path {\n    position: relative;\n    box-sizing: border-box;\n    user-select: none;\n    -webkit-user-select: none;\n    -ms-user-select: none;\n    -moz-user-select: none;\n    min-height: 1.5em;\n}\n\n.absol-quick-path button {\n    outline: none;\n    color: rgb(69, 69, 69);\n    height: 1.5em;\n}\n\n.absol-quick-path button:hover {\n    color: black;\n}\n\n.absol-quick-path .toggler-ico path {\n    fill: rgb(104, 104, 104);\n}\n\n.dark .absol-quick-path button {\n    color: rgb(200, 200, 200);\n}\n\n\n.dark .absol-quick-path button:hover {\n    color: white;\n}\n\n.dark .absol-quick-path .toggler-ico path {\n    fill: rgb(169, 169, 169);\n}\n\n\n\n.absol-quick-path-btn:focus span {\n    text-decoration: underline;\n}\n\n/* \n.absol-quick-path-btn .toggler-ico path {\n    fill: rgb(104, 104, 104);\n} */\n", ""]);



/***/ }),
/* 196 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(197);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 197 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-radio-button {\n    display: inline;\n    cursor: pointer;\n    white-space: nowrap;\n}\n\n.absol-radio-button input {\n    display: none;\n}\n\n\n.absol-radio-button > svg {\n    display: inline-block;\n    vertical-align: middle;\n    width: calc(1em + 4px);\n    height: calc(1em + 4px);\n}\n\n.absol-radio-button > svg .bound {\n    stroke: #929292;\n    fill: white;\n}\n\n.absol-radio-button:hover > svg .bound {\n    fill: #d6d6d6;\n    stroke: black;\n}\n\n.absol-radio-icon .border {\n}\n\n.absol-radio-button .dot {\n    transition: opacity 0.07s;\n    opacity: 0;\n    fill: #606060;\n}\n\n.absol-radio-button:hover .dot {\n    transition: opacity 0.07s;\n    opacity: 0;\n    fill: black;\n}\n\n.absol-radio-button.checked .dot {\n    opacity: 1;\n    transition: opacity 0.1s;\n}\n\n\n\n.absol-radio-button > span:last-child {\n    display: none;\n}\n\n\n.absol-radio-button.disabled {\n    cursor: default;\n}\n\n.absol-radio-button.disabled:hover .dot,\n.absol-radio-button.disabled .dot {\n    fill: #929292;\n}\n\n.absol-radio-button.disabled .bound,\n.absol-radio-button.disabled:hover .bound {\n    stroke: #929292;\n    fill: #ebebe4;\n}\n\n\n.absol-radio .standar-alone {\n    display: inline-block;\n}\n\n.absol-radio > span:not(:last-child) {\n    padding-right: 0.3em;\n}\n\n.absol-radio span:last-child {\n    padding-left: 0.3em;\n}\n\ninput:checked ~ .absol-radio-icon .dot {\n    opacity: 1;\n}", ""]);



/***/ }),
/* 198 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(199);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 199 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-radio {\n    display: inline;\n    cursor: pointer;\n    white-space: nowrap;\n}\n\n.absol-radio input {\n    display: none;\n}\n\n.absol-radio > span {\n    white-space: pre;\n    cursor: inherit;\n    vertical-align: middle;\n    margin: 0;\n    font-size: inherit;\n}\n\n.absol-radio > span:empty {\n    display: none;\n}\n\n.absol-radio > svg {\n    display: inline-block;\n    vertical-align: middle;\n    width: calc(1em + 4px);\n    height: calc(1em + 4px);\n}\n\n.absol-radio > svg .bound {\n    stroke: #929292;\n    fill: white;\n}\n\n.absol-radio:hover > svg .bound {\n    fill: #d6d6d6;\n    stroke: black;\n}\n\n/* \n.absol-radio>svg .bound {\n    fill: none;\n} */\n\n.absol-radio-icon .border {\n}\n\n.absol-radio .dot {\n    transition: opacity 0.07s;\n    opacity: 0;\n    fill: #606060;\n}\n\n.absol-radio:hover .dot {\n    transition: opacity 0.07s;\n    opacity: 0;\n    fill: black;\n}\n\n.absol-radio.checked .dot {\n    opacity: 1;\n    transition: opacity 0.1s;\n}\n\n.absol-radio:not(.right) > span.absol-radio-left-label {\n    display: none;\n}\n\n.absol-radio.right > span.absol-radio-right-label {\n    display: none;\n}\n\nspan.absol-radio-left-label {\n    padding-right: 0.3em;\n}\n\nspan.absol-radio-right-label {\n    padding-left: 0.3em;\n}\n\n\n\n\n.absol-radio.disabled {\n    cursor: default;\n}\n\n.absol-radio.disabled{\n    color: #777;\n}\n\n.absol-radio.disabled:hover .dot,\n.absol-radio.disabled .dot {\n    fill: #929292;\n}\n\n.absol-radio.disabled .bound,\n.absol-radio.disabled:hover .bound {\n    stroke: #929292;\n    fill: #ebebe4;\n}\n\n\n.absol-radio .standar-alone {\n    display: inline-block;\n}\n\ninput:checked ~ .absol-radio-icon .dot {\n    opacity: 1;\n}", ""]);



/***/ }),
/* 200 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(201);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 201 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-resize-box {\n    position: absolute;\n    /*or fixed*/\n    z-index: 1;\n    box-sizing: border-box;\n    opacity: 0.5;\n    pointer-events: none;\n}\n\n.as-resize-box-body {\n    margin: -1px;\n    width: calc(100% + 2px);\n    height: calc(100% + 2px);\n    position: relative;\n    box-sizing: border-box;\n    border: solid 2px rgb(32, 150, 218);\n}\n\n.as-resize-box.as-can-move .as-resize-box-body {\n    cursor: move;\n    pointer-events: all;\n}\n\n.as-resize-box.as-can-click .as-resize-box-body {\n    pointer-events: all;\n}\n\n.as-resize-box.as-can-move .as-resize-box-dot,\n.as-resize-box.as-can-resize .as-resize-box-dot.right,\n.as-resize-box.as-can-resize .as-resize-box-dot.bottom,\n.as-resize-box.as-can-resize .as-resize-box-dot.right-bottom {\n    display: unset;\n\n}\n\n.as-resize-box-dot {\n    position: absolute;\n    width: 0.6em;\n    height: 0.6em;\n    background: rgb(32, 150, 218);\n    display: none;\n    pointer-events: all;\n}\n\n.as-resize-box-dot.left-top {\n    top: calc(-0.3em - 1px);\n    left: calc(-0.3em - 1px);\n    cursor: nw-resize;\n}\n\n.as-resize-box-dot.left-bottom {\n    bottom: calc(-0.3em - 1px);\n    left: calc(-0.3em - 1px);\n    cursor: sw-resize;\n}\n\n.as-resize-box-dot.left {\n    top: calc(50% - 0.3em);\n    left: calc(-0.3em - 1px);\n    cursor: w-resize;\n}\n\n.as-resize-box-dot.top {\n    top: calc(-0.3em - 1px);\n    left: calc(50% - 0.3em);\n    cursor: n-resize;\n}\n\n.as-resize-box-dot.bottom {\n    bottom: calc(-0.3em - 1px);\n    left: calc(50% - 0.3em);\n    cursor: s-resize;\n}\n\n.as-resize-box-dot.right-top {\n    top: calc(-0.3em - 1px);\n    right: calc(-0.3em - 1px);\n    cursor: ne-resize;\n}\n\n.as-resize-box-dot.right-bottom {\n    bottom: calc(-0.3em - 1px);\n    right: calc(-0.3em - 1px);\n    cursor: se-resize;\n}\n\n\n.as-resize-box-dot.right {\n    top: calc(50% - 0.3em);\n    right: calc(-0.3em - 1px);\n    cursor: e-resize;\n}\n\n.as-resize-box-overiding .as-resize-box-dot,\n.as-resize-box-overiding .as-resize-box-body {\n    cursor: unset;\n}\n\n.as-resize-box-overiding.body {\n    cursor: move !important;\n}\n\n\n.as-resize-box-overiding.left-top {\n    cursor: nw-resize !important;\n}\n\n.as-resize-box-overiding.left-bottom {\n    cursor: sw-resize !important;\n}\n\n.as-resize-box-overiding.left {\n    cursor: w-resize !important;\n}\n\n.as-resize-box-overiding.top {\n    cursor: n-resize !important;\n}\n\n.as-resize-box-overiding.bottom {\n    cursor: s-resize !important;\n}\n\n.as-resize-box-overiding.right-top {\n    cursor: ne-resize !important;\n}\n\n.as-resize-box-overiding.right-bottom {\n    cursor: se-resize !important;\n}\n\n\n.as-resize-box-overiding.right {\n    cursor: e-resize !important;\n}", ""]);



/***/ }),
/* 202 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(203);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 203 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-search-text-input {\n    position: relative;\n    height: 2em;\n    border-radius: 0.3em;\n    border: solid 1px #a9a9a9;\n    font-size: 14px;\n    background-color: white;\n}\n\n.absol-search-text-input.focus {\n    outline: solid 1px rgba(30, 30, 255, 0.4);\n}\n\n.absol-search-text-input-container {\n    position: absolute;\n    left: 0;\n    top: 0;\n    bottom: 0;\n    right: 2em;\n}\n\n.absol-search-text-button-container {\n    position: absolute;\n    top: 0;\n    right: 0;\n    width: 2em;\n    bottom: 0em;\n}\n\n.absol-search-text-button-container button {\n    width: 100%;\n    height: 100%;\n    outline: none;\n    border: none;\n    background: transparent;\n    padding: 0;\n    font-size: 1em;\n}\n\n.absol-search-text-button-container button>svg {\n    height: 1.14285714286em;\n    width: 1.14285714286em;\n    fill: rgb(132, 132, 132);\n}\n\n.absol-search-text-input-container input {\n    width: 100%;\n    height: 100%;\n    font-size: 1em;\n    box-sizing: border-box;\n    outline: none;\n    border: none;\n    background-color: transparent;\n    padding-left: 0.6em;\n}\n\n.absol-search-text-input:not(.searching) svg.times{\n    display: none;\n}\n\n.absol-search-text-input.searching svg.find{\n    display: none;\n}\n\n.absol-search-text-input-container input::-webkit-search-cancel-button{\n    display: none;\n}", ""]);



/***/ }),
/* 204 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(205);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 205 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ":root {\n    --select-box-item-height: 20px;\n    --select-box-item-font-size: 14px;\n    --select-box-item-border-radius: 9px;\n    --select-box-item-close-opacity: 0;\n    --select-box-min-height: 30px;\n    --select-box-focus-item-color: rgb(208, 145, 239);\n}\n\n.absol-selectbox {\n    --list-min-width: 40px;\n    display: inline-block;\n    vertical-align: middle;\n    position: relative;\n    min-height: var(--select-box-min-height);\n    min-width: var(--list-min-width);\n    border: solid 1px #d6d6d6;\n    border-radius: 3px;\n    box-sizing: border-box;\n    padding-right: 20px;\n    overflow-y: auto;\n    outline: none;\n    background-color: white;\n}\n\n.absol-selectbox:not(.as-disable-click-to-focus) {\n    cursor: copy;\n}\n\n.absol-selectbox.as-disabled {\n    pointer-events: none;\n    background-color: var(--as-disabled-background-color);\n}\n\n.absol-selectbox.as-disabled .absol-selectbox-item {\n    opacity: 0.7;\n}\n\n.absol-selectbox {\n    white-space: normal;\n}\n\n.absol-selectbox .absol-selectbox-item {\n    margin: calc((var(--select-box-min-height) - 2px - var(--select-box-item-height)) / 2) 2px;\n}\n\n.absol-selectbox-item {\n    font-family: Arial, Helvetica, sans-serif;\n    display: inline-block;\n    position: relative;\n    font-size: var(--select-box-item-font-size);\n    height: var(--select-box-item-height);\n    box-sizing: border-box;\n    border-radius: var(--select-box-item-border-radius);\n    overflow: hidden;\n    background-color: #5bc0de;\n    border-color: #46b8da;\n    vertical-align: top;\n    white-space: normal;\n    -webkit-user-select: none;\n    -moz-user-select: none;\n    -ms-user-select: none;\n    user-select: none;\n    color: black;\n    cursor: pointer;\n}\n\n\n.absol-selectbox-item.as-theme-confirmed {\n    background-color: rgb(145, 228, 251);\n}\n\n.absol-selectbox-item.as-theme-declined {\n    background-color: rgb(255, 138, 138)\n}\n\n.absol-selectbox-item.as-theme-waiting {\n    background-color: rgb(255, 227, 174);\n    color: black;\n}\n\n.absol-selectbox-item-text {\n    height: var(--select-box-item-height);\n    padding-right: calc(var(--select-box-item-height) + 5px);\n    padding-left: 5px;\n    font-size: inherit;\n    white-space: nowrap;\n}\n\n.absol-selectbox-item-text:hover {\n    background-color: rgba(0, 0, 0, 0.0893617021);\n}\n\n.absol-selectbox-item-text span {\n    display: inline-block;\n    vertical-align: middle;\n    white-space: nowrap;\n}\n\n.absol-selectbox-item-close {\n    position: absolute;\n    right: 0;\n    top: 0;\n    bottom: 0;\n    width: var(--select-box-item-height);\n    text-align: center;\n    -webkit-user-select: none;\n    -moz-user-select: none;\n    -ms-user-select: none;\n    user-select: none;\n    cursor: pointer;\n    background-color: rgba(0, 0, 0, var(--select-box-item-close-opacity));\n    white-space: nowrap;\n}\n\n.absol-selectbox-item-close::after,\n.absol-selectbox-item-text::before {\n    content: \"\";\n    display: inline-block;\n    vertical-align: middle;\n    height: 100%;\n}\n\n.absol-selectbox-item-close span {\n    font-size: 1.25em;\n    display: inline-block;\n    vertical-align: middle;\n}\n\n\n.absol-selectbox.as-item-focusable .absol-selectbox-item.as-active {\n    background-color: var(--select-box-focus-item-color);\n}", ""]);



/***/ }),
/* 206 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-selectmenu-anchor-container {\n    /* position: fixed; */\n\n    /* top: 0; */\n    /* left: 0; */\n    width: 0;\n    height: 0;\n    overflow: visible;\n}\n\n.absol-selectmenu-anchor {\n    position: relative;\n}\n\n.absol-selectmenu-anchor-content-container {\n    position: absolute;\n    z-index: 1002;\n    top: 0;\n    left: 0;\n}\n\n.absol-selectmenu-anchor-content-container .absol-bscroller {\n    max-height: calc(100vh - 50px);\n}\n\n\n.absol-selectmenu-anchor.absol-disabled .absol-selectmenu-anchor-content-container {\n    visibility: hidden;\n    top: -100000px;\n    left: -10000px;\n    z-index: -1000;\n    opacity: 0;\n}\n\n\n.absol-selectmenu-dropdown-box {\n    border: solid 1px rgb(100, 100, 255);\n    box-sizing: border-box;\n    background-color: white;\n    display: inline-block;\n    vertical-align: top;\n    -webkit-box-shadow: 2px 2px 6px 0px rgba(0, 0, 90, 0.55);\n    -moz-box-shadow: 2px 2px 6px 0px rgba(0, 0, 90, 0.55);\n    box-shadow: 2px 2px 6px 0px rgba(0, 0, 90, 0.55);\n}\n\n.absol-selectmenu-dropdown-box > .as-bscroller {\n    overflow-y: auto;\n}\n\n.absol-selectmenu-dropdown-box .absol-search-text-input {\n    margin: 0.2em;\n}\n\n\n.absol-selectmenu.absol-hidden {\n    display: none !important;\n}\n\n.absol-selectmenu-render-space {\n    position: fixed;\n    top: 0;\n    left: 0;\n    z-index: -1000;\n    visibility: hidden;\n    font-size: 14px;\n}\n\n.absol-selectmenu-render-space > div {\n    display: inline-block;\n}\n\n\n.absol-selectmenu.as-disabled,\n.as-select-menu.as-disabled\n{\n    pointer-events: none;\n    background-color: var(--as-disabled-background-color);\n    color: var(--as-disabled-text-color);\n}\n\n.absol-selectmenu {\n    display: inline-block;\n    vertical-align: middle;\n    position: relative;\n    height: 30px;\n    min-width: 30px;\n    border: solid 1px #d6d6d6;\n    border-radius: 2px;\n    box-sizing: border-box;\n    cursor: pointer;\n    font-size: 14px;\n    outline: none;\n    font-family: \"Helvetica Neue\", Arial, Helvetica, sans-serif;\n    background-color: white;\n}\n\n/* .absol-selectmenu:hover {\n    border: solid 1px black;\n} */\n\n.absol-selectmenu-btn {\n    position: absolute;\n    top: 0;\n    bottom: 0;\n    right: 0;\n    width: 30px;\n    border: none;\n    background: transparent;\n    z-index: 2;\n    pointer-events: none;\n}\n\n.absol-selectmenu-btn:focus {\n    outline: none;\n}\n\n.absol-selectmenu-btn svg.dropdown {\n    width: 10px;\n    height: 10px;\n    fill: #929292;\n}\n\n.absol-selectmenu:hover svg.dropdown {\n    width: 10px;\n    height: 10px;\n    fill: black;\n}\n\n.absol-selectmenu-holder-item {\n    position: absolute;\n    left: 0;\n    right: 0;\n    top: 0;\n    bottom: 0;\n    /*1px for border*/\n    white-space: nowrap;\n}\n\n.absol-selectmenu-holder-item::before{\n    content: \"\";\n    height: 100%;\n    display: inline-block;\n    vertical-align: middle;\n}\n\n\n.absol-selectmenu-holder-item>.absol-selectlist-item{\n    display: inline-block;\n    width: 100%;\n    vertical-align: middle;\n}\n\n.absol-selectmenu .absol-selectlist-item span {\n    padding-right: 28px;\n}\n\n.absol-selectmenu .absol-scroll-button {\n    background-color: rgba(0, 0, 0, 0.1);\n    border-radius: 3px;\n}\n\n.absol-selectmenu .absol-scroll-button:hover {\n    background-color: rgba(0, 0, 0, 0.2);\n}\n\n.absol-scroll-bar-v-container {\n    width: 10px;\n}\n\n.absol-selectmenu .absol-search-text-input {\n    margin: 4px;\n}\n\n.absol-selectmenu-render-space .absol-selectlist-item span {\n    padding-right: 0;\n}\n\n\n.absol-selectmenu .absol-selectlist-item-desc-container {\n    right: 30px;\n}\n\n\n.absol-selectmenu-dropdown-box .absol-bscroller {\n    overflow-y: auto;\n}\n\n\n.as-select-anchor {\n    position: fixed;\n    z-index: 1000001;\n}\n\n\n.as-select-anchor.as-hidden {\n    left: 0;\n    top: 0;\n    z-index: -1000;\n    visibility: hidden;\n    opacity: 0;\n}\n\n\n.as-select-menu {\n    --select-list-estimate-width: 0px;\n    --select-list-desc-width: 0px;\n    width: calc(var(--select-list-estimate-width) + 32px);\n    min-width: calc(var(--select-list-estimate-width) + 32px);\n}", ""]);



/***/ }),
/* 207 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(208);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 208 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-select-list-box {\n    --select-list-estimate-width: 0;\n    --max-height: calc(100vh - 80px);\n    position: fixed;\n    top: 10px;\n    left: 10px;\n    width: calc(var(--select-list-estimate-width) + 2px + 5px + 7px);\n    font-size: 14px;\n    font-family: Arial, Helvetica, sans-serif;\n    border: solid 1px rgb(100, 100, 255);\n    box-sizing: border-box;\n    background-color: white;\n    display: inline-block;\n    vertical-align: top;\n    -webkit-box-shadow: 2px 2px 6px 0px rgba(0, 0, 90, 0.55);\n    -moz-box-shadow: 2px 2px 6px 0px rgba(0, 0, 90, 0.55);\n    box-shadow: 2px 2px 6px 0px rgba(0, 0, 90, 0.55);\n    outline: none;\n}\n\n\ndiv.absol-follower.as-select-list-box {\n    z-index: 4000000;\n}\n\n.as-select-list-box .as-select-list-box {\n    min-width: 100%;\n}\n\n.as-select-list-box-search-ctn {\n    position: absolute;\n    left: 0;\n    right: 0;\n}\n\n.as-select-list-box.as-enable-search.as-anchor-6 .as-select-list-box-search-ctn,\n.as-select-list-box.as-enable-search.as-anchor-5 .as-select-list-box-search-ctn {\n    bottom: 0;\n}\n\n.as-select-list-box.as-enable-search.as-anchor-6,\n.as-select-list-box.as-enable-search.as-anchor-5 {\n    padding-bottom: 38px;\n}\n\n.as-select-list-box.as-enable-search.as-anchor-1,\n.as-select-list-box.as-enable-search.as-anchor-2 {\n    padding-top: 38px;\n}\n\n.as-select-list-box.as-enable-search.as-anchor-1 .as-select-list-box-search-ctn,\n.as-select-list-box.as-enable-search.as-anchor-2 .as-select-list-box-search-ctn {\n    top: 0;\n}\n\n.as-select-list-box-scroller {\n    overflow-y: auto;\n    overflow-x: visible;\n}\n\n.as-select-list-box .as-select-list-box-scroller {\n    max-height: var(--max-height);\n}\n\n.as-select-list-box.as-enable-search .as-select-list-box-scroller {\n    max-height: calc(var(--max-height) - 38px);\n}\n\n.as-select-list-box-content {\n    position: relative;\n}\n\n.as-select-list-box-page {\n    position: absolute;\n    left: 0;\n    right: 0;\n    top: 0;\n}\n\n.as-select-list-box .absol-selectlist-item {\n    cursor: default;\n}\n\n.as-select-list-box-search-ctn {\n    display: none;\n    padding: 5px;\n}\n\n\n.as-select-list-box.as-enable-search .as-select-list-box-search-ctn {\n    display: block;\n}\n\n.as-select-list-box:not(.as-searching) .as-last-in-group {\n    border-bottom: 1px solid #dddddd;\n}\n\n.as-select-list-box .as-last-in-group span {\n    line-height: 19px;\n}\n\n\n.as-select-list-box .absol-selectlist-item:hover {\n    background-color: #efefef;\n}\n\n.as-select-list-box.as-value-hidden .absol-selectlist-item.as-selected {\n    color: #aaaaaa;\n}\n\n.as-select-list-box.as-value-hidden .absol-selectlist-item.as-selected.as-is-leaft {\n    display: none;\n}", ""]);



/***/ }),
/* 209 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-select-table-render-space {\n    position: fixed;\n    top: 0;\n    left: 0;\n    z-index: -1000;\n    visibility: hidden;\n    font-size: 14px;\n}\n\n.absol-select-table {\n    border: solid 1px #a9a9a9;\n    min-width: 26em;\n    overflow: hidden;\n}\n\n.absol-select-table-header {\n    display: block;\n    position: relative;\n    box-sizing: content-box;\n    height: 2.2857142857em;\n}\n\n.absol-select-table-searchtextinput-container {\n    position: absolute;\n    left: 0.14285714285em;\n    top: 0.14285714285em;\n    height: 2em;\n    right: 10em;\n    /* background-color: cyan; */\n}\n\n.absol-select-table.disable-move-all .absol-select-table-buttons-container {\n    display: none;\n}\n\n.absol-select-table.disable-move-all .absol-select-table-searchtextinput-container {\n    right: 0.14285714285em !important;\n}\n\n.absol-select-table-buttons-container {\n    position: absolute;\n    right: 0.14285714285em;\n    top: 0.14285714285em;\n    width: 10.7142857143em;\n    height: 2em;\n    white-space: nowrap;\n}\n\n.absol-select-table-buttons-container>button {\n    height: 2em;\n    font-size: 1em;\n    background-color: transparent;\n    border: none;\n    padding: 0 0.5em;\n    margin: 0;\n    text-decoration: underline;\n    cursor: pointer;\n}\n\n.absol-select-table-buttons-container>button:focus {\n    outline: none;\n}\n\n.absol-select-table-buttons-container>button:hover {\n    color: #a9a9a9;\n}\n\n.absol-select-table-buttons-container>button:active {\n    color: #a9a9ff;\n}\n\n.absol-select-table-body {\n    margin: 0.14285714285em;\n    white-space: nowrap;\n}\n\n.absol-select-table-items-scroller {\n    width: 50%;\n    display: inline-block;\n    box-sizing: border-box;\n    vertical-align: top;\n    overflow-y: auto;\n}\n\n.absol-select-table-items-scroller .absol-scroll-button {\n    background-color: rgba(1, 1, 30, 0.1);\n}\n\n.absol-select-table-items-scroller .absol-scroll-bar-v-container {\n    width: 0.69em;\n}\n\n.absol-select-table-selected-search-items-container,\n.absol-select-table-nonselected-search-items-container,\n.absol-select-table.searching .absol-select-table-selected-items-container,\n.absol-select-table.searching .absol-select-table-nonselected-items-container {\n    display: none;\n}\n\n.absol-select-table.searching .absol-select-table-selected-search-items-container,\n.absol-select-table.searching .absol-select-table-nonselected-search-items-container {\n    display: block;\n    padding-right: 0.7em;\n}\n\n.absol-select-table-nonselected-items-container,\n.absol-select-table-selected-items-container {\n    padding-right: 0.7em;\n}\n\n.absol-select-table-nonselected-items-container>.absol-select-table-item,\n.absol-select-table-selected-items-container>.absol-select-table-item,\n.absol-select-table-nonselected-search-items-container>.absol-select-table-item,\n.absol-select-table-selected-search-items-container>.absol-select-table-item {\n    margin: 0.14285714285em;\n}\n\n.absol-select-table-item {\n    display: block;\n    line-height: 2em;\n    min-height: 2em;\n    position: relative;\n    background-color: rgba(169, 169, 169, 0.05);\n    border: solid 1px rgb(235, 235, 235);\n    border-radius: 0.2em;\n    overflow: hidden;\n    -webkit-user-select: none;\n    /* Safari 3.1+ */\n    -moz-user-select: none;\n    /* Firefox 2+ */\n    -ms-user-select: none;\n    /* IE 10+ */\n    user-select: none;\n    /* Standard syntax */\n    padding-left: 0.69em;\n    padding-right: 1.8em;\n    box-sizing: border-box;\n}\n\n.absol-select-table-item:hover {\n    background-color: rgba(169, 169, 169, 0.1);\n}\n\n.absol-select-table-item-right-container {\n    right: 0.3em;\n    bottom: 0.3em;\n    top: 0.3em;\n    padding: 0.2em;\n    width: 1.4em;\n    position: absolute;\n    border-radius: 0.2em;\n    box-sizing: border-box;\n ;\n}\n\n.absol-select-table-item-right-container:hover {\n    background-color: rgba(169, 169, 169, 0.3);\n}\n\nspan.absol-select-table-item-text {\n    white-space: normal;\n    \n}\n\n.absol-select-table-item-right-container-table{\n    display: table;\n    width: 100%;\n    height: 100%;\n}\n.absol-select-table-item-right-container-cell{\n    display: table-cell;\n    vertical-align: middle;\n}\n\n.absol-select-table-item-right-container svg {\n    width: 1em;\n    height: 1em;\n    display: none;\n}\n\n/* clearfix\n.absol-select-table-none-nonselected-items-container::after,\n.absol-select-table-none-selected-items-container::after {\n    content: \"\";\n    display:table;\n    clear: both;\n} */\n\n.absol-select-table-selected-items-container .absol-select-table-item-right-container svg.sub-icon,\n.absol-select-table-selected-search-items-container .absol-select-table-item-right-container svg.sub-icon {\n    display: block;\n    stroke: rgb(243, 61, 61);\n    fill: rgb(226, 100, 100);\n}\n\n.absol-select-table-nonselected-items-container .absol-select-table-item-right-container svg.add-icon,\n.absol-select-table-nonselected-search-items-container .absol-select-table-item-right-container svg.add-icon {\n    display: block;\n    fill: rgb(100, 226, 167);\n    stroke: rgb(61, 185, 243);\n}\n\n.absol-select-table.portrait {}", ""]);



/***/ }),
/* 210 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(211);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 211 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-span-input {\n    white-space: pre;\n}\n\n.absol-span-input:focus {\n    outline-color: rgba(30, 150, 255, 0.3);\n    outline-width: 1px;\n}\n\n.absol-span-input:empty::before {\n    content: \" \";\n    display: inline;\n    white-space: pre;\n}\n\n.absol-span-input.absol-span-input-empty-minus:empty::before {\n    content: \"-\";\n}", ""]);



/***/ }),
/* 212 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(213);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 213 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-static-tabbar {\n    position: relative;\n}\n\n.absol-static-tabbar-button {\n    height: 2em;\n    background-color: transparent;\n    border: none;\n    font-size: 1em;\n    padding-left: 0.5em;\n    padding-right: 0.5em;\n    color: rgb(104, 104, 104);\n}\n\n.absol-static-tabbar-button:hover {\n    color: rgb(30, 30, 55);\n}\n\n.absol-static-tabbar-button.active {\n    color: black;\n}\n\n.absol-static-tabbar-button:focus {\n    outline: none;\n}\n\n.absol-static-tabbar-button>span {\n    font-size: 0.7em;\n}\n\n.absol-static-tabbar-hline {\n    border-bottom: solid 1px rgb(127, 127, 128);\n    height: 100%;\n}\n\n.absol-static-tabbar-active-box {\n    position: absolute;\n    bottom: 0;\n    top: 0;\n    left: 0;\n    width: 0;\n    transition: left 0.15s, width 0.15s;\n    padding-left: 0.5em;\n    padding-right: 0.5em;\n    box-sizing: border-box;\n    /* z-index: 1; */\n}\n\n.absol-static-tabbar.dark .absol-static-tabbar-hline{\n    border-bottom-color: white;\n}\n\n.absol-static-tabbar.dark .absol-static-tabbar-button.active{\n    color: white;\n}\n\n.absol-static-tabbar.dark .absol-static-tabbar-button {\n    color: rgb(204, 204, 204);\n}", ""]);



/***/ }),
/* 214 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(215);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 215 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-switch {\n    position: relative;\n    display: inline-block;\n    width: 2.2em;\n    height: 1.2em;\n    vertical-align: middle;\n}\n\n.absol-switch input {\n    opacity: 0;\n    width: 0;\n    height: 0;\n}\n\n.absol-switch-slider {\n    position: absolute;\n    cursor: pointer;\n    top: 0;\n    left: 0;\n    right: 0;\n    bottom: 0;\n    background-color: #ccc;\n    -webkit-transition: .4s;\n    transition: .4s;\n    border-radius: 0.6em;\n}\n\n.absol-switch-slider:before {\n    position: absolute;\n    content: \"\";\n    height: 1em;\n    width: 1em;\n    left: 0.1em;\n    bottom: 0.1em;\n    background-color: white;\n    -webkit-transition: .4s;\n    transition: .4s;\n    border-radius: 0.5em;\n}\n\ninput:checked+.absol-switch-slider {\n    background-color: #2196F3;\n}\n\ninput:focus+.absol-switch-slider {\n    box-shadow: 0 0 1px #2196F3;\n}\n\ninput:checked+.absol-switch-slider:before {\n    -webkit-transform: translateX(1em);\n    -ms-transform: translateX(1em);\n    transform: translateX(1em);\n}\n\n/* Rounded absol-switch-sliders */\n.absol-switch.square .absol-switch-slider {\n    border-radius: 0;\n}\n\n.absol-switch.square .absol-switch-slider:before {\n    border-radius: 0;\n}\n\n.absol-switch.disabled {\n    pointer-events: none;\n}\n\n.absol-switch.disabled .absol-switch-slider:before{\n    background-color: rgb(234, 234, 234);\n}\n\n.absol-switch.disabled input:checked+.absol-switch-slider {\n    background-color: rgb(141, 188, 226);\n}\n\n.absol-switch.disabled .absol-switch-slider {\n    background-color: rgb(171, 171, 171);\n}\n\n", ""]);



/***/ }),
/* 216 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(217);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 217 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-table-scroller {\n    position: relative;\n    overflow: hidden;\n}\n\n.absol-table-scroller-render-space {\n    position: fixed;\n    overflow: scroll;\n    left: 0;\n    top: 0;\n    max-width: calc(99vw - 30px);\n    max-height: calc(99vh - 30px);\n    opacity: 0;\n    z-index: -1000;\n    visibility: hidden;\n}\n\n\n.absol-table-scroller-viewport {\n    box-sizing: border-box;\n    overflow: scroll;\n    width: calc(100% + 17px);\n    height: calc(100% + 17px);\n}\n\n.absol-table-scroller-fixed-viewport {\n    position: absolute;\n    left: 0;\n    top: 0;\n    z-index: 10;\n    overflow: hidden;\n    /*pointer-events: none;*/\n}\n\n.absol-table-scroller-fixed-viewport>table>thead,\n.absol-table-scroller-fixed-viewport>table {\n    border-top-color: transparent !important;\n}\n\n.absol-table-scroller-fixed-hidden {\n    visibility: hidden !important;\n    opacity: 0 !important;\n    border-color: transparent !important;\n\n}\n\n.absol-table-scroller-header-hscroller {\n    position: absolute;\n    left: 0;\n    top: 0;\n    right: 0;\n    z-index: 9;\n    overflow: hidden;\n    /*pointer-events: none;*/\n}\n\n.absol-table-scroller-header-hscroller-viewport {\n    max-width: 100%;\n    overflow-x: scroll;\n    margin-bottom: -17px;/*default*/\n}\n\n.absol-table-scroller-header-hscroller-viewport table {\n    table-layout: fixed;\n}\n\n\n.absol-table-scroller-left-vscroller {\n    position: absolute;\n    top: 0;\n    left: 0;\n    bottom: 0;\n    z-index: 7;\n    /* width: 200px; */\n    overflow-x: hidden;\n    /*pointer-events: none;*/\n}\n\n.absol-table-scroller-left-vscroller-viewport {\n    max-height: 100%;\n    overflow-y: scroll;\n    min-width: calc(100% + 19px);\n    overflow-x: hidden;\n}\n\n\n.absol-table-scroller-head-line,\n.absol-table-scroller-left-line {\n    z-index: 30;\n    /*pointer-events: none;*/\n    position: absolute;\n}\n\n.absol-table-scroller-head-line {\n    left: 0;\n    width: calc(100% - 6px);\n    border-bottom: solid 2px rgb(169, 169, 170);\n    width: 100%;\n}\n\n.absol-table-scroller-left-line {\n    top: 0;\n    border-right: solid 2px rgb(169, 169, 170);\n    height: calc(100% - 6px);\n    height: 100%;\n}\n\n\n.absol-table-scroller.scroll-v .absol-table-scroller-head-line {\n    width: 100%;\n}\n\n.absol-table-scroller.scroll-h .absol-table-scroller-left-line {\n    height: 100%;\n}\n\n\n.absol-table-scroller:not(.scroll-v) .absol-table-scroller-head-line {\n    display: none;\n}\n\n.absol-table-scroller:not(.scroll-h) .absol-table-scroller-left-line {\n    display: none;\n}\n\n\n\n.absol-table-scroller-vscrollbar-container {\n    position: absolute;\n    top: 0;\n    right: 0;\n    width: 8px;\n    bottom: 0;\n    z-index: 31;\n}\n\n.absol-table-scroller-vscrollbar-container .absol-scrollbar-button {\n    left: 1px;\n    right: 1px;\n}\n\n\n.absol-table-scroller-vscrollbar-container>div,\n.absol-table-scroller-hscrollbar-container>div {\n    width: 100%;\n    height: 100%;\n}\n\n.absol-table-scroller-hscrollbar-container {\n    position: absolute;\n    left: 0;\n    right: 0;\n    height: 12px;\n    bottom: 0;\n    z-index: 31;\n}\n\n\n.absol-table-scroller-hscrollbar-container .absol-scrollbar-button {\n    top: 1px;\n    bottom: 1px;\n}\n\n\n.absol-table-scroller:not(.scroll-v) .absol-table-scroller-vscrollbar-container {\n    display: none;\n}\n\n.absol-table-scroller:not(.scroll-h) .absol-table-scroller-hscrollbar-container {\n    display: none;\n}\n\n\n.absol-table-scroller.scroll-h .absol-table-scroller-vscrollbar-container {\n    bottom: 12px;\n}\n\n.absol-table-scroller.scroll-v .absol-table-scroller-hscrollbar-container {\n    right: 8px;\n}\n\n.absol-table-scroller-fixed-table{\n    table-layout: fixed;\n    box-sizing: border-box;\n\n}\n\n.absol-table-scroller-fixed-table *,\n.absol-table-scroller-header-hscroller *{\n    box-sizing: border-box;\n}", ""]);



/***/ }),
/* 218 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(219);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 219 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-table-vscroller {\n    position: relative;\n}\n\n.absol-table-vscroller-head {\n    position: absolute;\n    z-index: 2;\n    width: 300px;\n    height: 20px;\n    top: 0;\n    left: 0;\n}\n\n.absol-table-vscroller-head-line{\n    position: absolute;\n    left: 0;\n    z-index: 3;\n    pointer-events: none;\n    border-bottom:solid 2px rgb(169, 169, 170); \n    width: 100%;\n}\n\n.absol-table-vscroller.scroll-v .absol-table-vscroller-head-line{\n    width: calc(100% - 7px);\n}\n\n.absol-table-vscroller-viewport {\n    max-height: 100%;\n    padding-bottom: 1px;\n    padding-top: 1px;\n    overflow-y: auto;\n}\n\n.absol-table-vscroller-viewport > table{\n    box-sizing: border-box;\n    width: 100%;\n}", ""]);



/***/ }),
/* 220 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(221);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 221 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-textarea2{\n    overflow: hidden;\n    resize: none;\n    box-sizing: border-box;\n    height: 1.425em;\n} ", ""]);



/***/ }),
/* 222 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(223);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 223 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-text-clipboard {\n    opacity: 0;\n    font-size: 1px;\n    height: 1px;\n    width: 1px;\n}", ""]);



/***/ }),
/* 224 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(225);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 225 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".ac-time-input {\n    box-sizing: border-box;\n    height: calc(2em + 2px);\n    width: 9em;\n    border: solid 1px #d6d6d6;\n    border-radius: 2px;\n    font-size: 14px;\n    outline: none;\n    font-family: \"Helvetica Neue\", Arial, Helvetica, sans-serif;\n    display: inline-block;\n    vertical-align: middle;\n    background-color: white;\n    position: relative;\n}\n\n.ac-time-input.as-disabled {\n    color: rgb(102, 102, 102);\n    pointer-events: none;\n}\n\n.ac-time-input.as-must-not-null .as-time-input-clear-btn {\n    display: none;\n}\n\n.ac-time-input input {\n    font: inherit;\n    outline: none;\n    width: calc(100% - 30px);\n    height: 100%;\n    border: none;\n    display: block;\n    padding: 0 0 0 var(--as-input-horizontal-padding);\n    -webkit-user-select: auto;\n    user-select: auto;\n    -webkit-user-drag: none;\n    color: inherit;\n}\n\n.as-time-input-icon-btn {\n    border-right: none;\n    border-top: none;\n    border-bottom: none;\n    border-left: 1px solid #ddd;\n    position: absolute;\n    top: 0;\n    bottom: 0;\n    right: 0;\n    width: calc(2em + 1px);\n    box-sizing: border-box;\n    background-color: rgba(169, 169, 169, 0.1);\n    cursor: pointer;\n    border-radius: 0;\n    font-size: inherit;\n    color: inherit;\n}\n\n\n.as-time-input-icon-btn > span {\n    font-size: 1.14em;\n}\n\n\n.as-time-input-icon-btn:hover {\n    background-color: rgba(169, 169, 169, 0.25);\n}\n\n.as-time-input-icon-btn:active {\n    background-color: rgba(169, 169, 169, 0.5);\n}\n\n\n.as-time-input-icon-btn.as-disabled {\n    color: rgb(102, 102, 102);\n    pointer-events: none;\n}\n\n\n.as-time-input-clear-btn {\n    font-size: inherit;\n    position: absolute;\n    right: calc(2em + 2px);\n    height: 2em;\n    top: calc(50% - 1em);\n    box-sizing: border-box;\n    background-color: transparent;\n    border: none;\n    color: #bbb;\n    visibility: hidden;\n}\n\n\n.ac-time-input.as-value-null .as-time-input-clear-btn {\n    display: none;\n}\n\n.as-time-input-clear-btn:hover {\n    color: rgb(132, 132, 132);\n}\n\n.as-time-input-clear-btn:active {\n    color: #525555;\n}\n\ninput:focus + .as-time-input-clear-btn,\n.ac-time-input .as-time-input-clear-btn {\n    visibility: visible;\n}\n\n\n/*.ac-time-input-picker-ctn {*/\n/*    position: fixed;*/\n/*}*/\n\n/*.ac-time-input > span {*/\n/*    font-size: 1em;*/\n/*    line-height: 2em;*/\n/*}*/\n\n/*.ac-time-input-picker-ctn-hidden {*/\n/*    z-index: -1000;*/\n/*    opacity: 0;*/\n/*    visibility: hidden;*/\n/*}*/\n\n/*.ac-time-input-picker-ctn-hidden:not(.absol-follower) {*/\n/*    transition: all 0.1s;*/\n/*}*/\n\n/*.ac-time-input.as-disabled {*/\n/*    color: rgb(102, 102, 102);*/\n/*    pointer-events: none;*/\n/*}*/", ""]);



/***/ }),
/* 226 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(227);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 227 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".ac-time-picker {\n    /*like chrome-calender*/\n    display: inline-block;\n    font-family: Arial;\n    font-size: 14px;\n    padding: 0.6em;\n    border: solid 1px rgb(191, 191, 191);\n    box-shadow: 1px 1px 2px rgb(240, 240, 240);\n    z-index: 100;\n    touch-action: manipulation;\n    user-select: none;\n    background-color: rgb(255, 255, 255);\n    white-space: initial;\n}\n\n\n@media screen and (orientation: portrait) {\n    .ac-time-picker.ac-time-picker-touch {\n        font-size: 5vw;\n    }\n}\n\n@media screen and (orientation: landscape) {\n    .ac-time-picker.ac-time-picker-touch {\n        font-size: 4vh;\n    }\n}\n\n\n.ac-time-picker:not(.ac-time-picker-clock-mode) .ac-time-picker-set-clock,\n.ac-time-picker:not(.ac-time-picker-clock-mode) .ac-time-picker-keyboard-btn,\n.ac-time-picker:not(.ac-time-picker-touch) .ac-time-picker-keyboard-btn,\n.ac-time-picker:not(.ac-time-picker-time-mode) .ac-time-picker-set-time,\n.ac-time-picker:not(.ac-time-picker-time-mode) .ac-time-picker-clock-btn {\n    display: none;\n}\n\n.ac-time-picker-set-clock-header {\n    font-size: 2.8em;\n    text-align: center;\n    min-width: 4.28571428571em;\n    font-weight: bold;\n\n}\n\n.ac-time-picker-set-clock-header > span {\n    font-size: inherit;\n}\n\n.ac-time-picker-clock {\n    width: 12em;\n    height: 12em;\n}\n\n.ac-time-picker-clock-hour-pm {\n    fill: rgb(20, 20, 20);\n    font-size: 0.7em;\n}\n\n\n.ac-time-picker-clock-hour-am {\n    fill: black;\n    font-size: 0.8em;\n}\n\n.ac-time-picker-clock-minute {\n    fill: black;\n    font-size: 0.8em;\n}\n\n\n.ac-time-picker-clock-center,\n.ac-time-picker-clock-select-circle {\n    fill: rgb(115, 166, 248);\n}\n\n.ac-time-picker-clock-select-center {\n    fill: white;\n}\n\n.ac-time-picker-clock-select-line {\n    stroke-width: 1;\n    stroke: rgb(115, 166, 248);\n}\n\n\n.ac-time-picker-hour,\n.ac-time-picker-minute {\n    outline: none;\n}\n\n.ac-time-picker-edit-hour .ac-time-picker-hour,\n.ac-time-picker-edit-minute .ac-time-picker-minute {\n    color: rgb(62, 125, 189);\n}\n\n.ac-time-picker:not(.ac-time-picker-edit-hour) .ac-time-picker-clock-hour-ctn,\n.ac-time-picker:not(.ac-time-picker-edit-minute) .ac-time-picker-clock-minute-ctn {\n    visibility: hidden;\n}\n\n.ac-time-picker:not(.ac-time-picker-edit-hour):not(.ac-time-picker-edit-minute) .ac-time-picker-clock {\n    display: none;\n}\n\n.ac-time-picker-hour:empty::before,\n.ac-time-picker-minute:empty::before {\n    content: \"0\";\n    display: inline;\n}\n\n.ac-time-picker-footer {\n    display: block;\n    position: relative;\n    min-height: 1.5em;\n    min-width: 12em;\n}\n\n.ac-time-picker-footer-right {\n    position: absolute;\n    right: 0;\n    top: 0;\n}\n\n.ac-time-picker-footer button {\n    font-size: 1em;\n    height: 1.5em;\n    padding-top: 0;\n    padding-bottom: 0;\n    border: none;\n    background-color: transparent;\n    outline: none;\n    padding-left: 0.3em;\n    padding-right: 0.3em;\n}\n\n.ac-time-picker-footer button:hover,\n.ac-time-picker-footer button:focus {\n    background-color: rgba(170, 170, 170, 0.3);\n}\n\n.ac-time-picker-footer > button {\n    margin-right: 1em;\n}\n\n.ac-time-picker-footer-right > button {\n    margin-left: 1em;\n}\n\n\n.ac-time-picker-footer button .mdi {\n    font-size: 1.3em;\n}\n\n\n/* .ac-time-picker:not(.ac-time-picker-touch) .ac-time-picker-keyboard-btn {\n    display: none;\n} */\n\n/* keyboard-outline */\n\n.ac-time-picker-set-time-header {\n    font-size: 1.4em;\n    font-weight: bold;\n    margin-bottom: 1em;\n}\n\n.ac-time-picker-set-time-label {\n    font-size: 1em;\n    font-weight: bold;\n    margin-bottom: 0.3em;\n}\n\n.ac-time-picker-set-time-input-group {\n    margin-bottom: 0.3em;\n    font-size: 1em;\n    white-space: nowrap;\n}\n\n.ac-time-picker-set-time-input-hm > input {\n    height: 1.2em;\n    line-height: 1.2em;\n    width: 2em;\n    text-align: center;\n    font-size: 1em;\n    border-top: none;\n    border-left: none;\n    border-right: none;\n    border-bottom: 1px solid rgb(70, 70, 72);\n    outline: none;\n}\n\n.ac-time-picker-set-time-input-label-hm {\n    font-size: 1em;\n    white-space: nowrap;\n\n}\n\n.ac-time-picker-set-time-input-label-hm span {\n    display: inline-block;\n    vertical-align: middle;\n    font-size: 1em;\n\n}\n\n\n.ac-time-picker-set-time-input-label-hm > span:first-child {\n    width: 2em;\n}", ""]);



/***/ }),
/* 228 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(229);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 229 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ":root {\n    --tool-tip-arrow-pos: 50%;\n    --tool-tip-background-color: gray;\n    --tool-tip-text-color: white;\n}\n\n.absol-tooltip {\n    margin: 0;\n    position: relative;\n    box-sizing: border-box;\n    display: inline-block;\n    color: var(--tool-tip-text-color);\n}\n\n.absol-tooltip-content {\n    display: block;\n    border-radius: 0.25em;\n    background-color: var(--tool-tip-background-color);\n    padding: 0.25em 0.5em;\n    font-size: inherit;\n}\n\n\n.absol-tooltip-arrow {\n    width: 0;\n    height: 0;\n    position: absolute;\n    box-sizing: content-box;\n    font-size: inherit;\n}\n\n.absol-tooltip.top .absol-tooltip-arrow {\n    border-left: 0.4em solid transparent;\n    border-right: 0.3em solid transparent;\n\n    border-top: 0.3em solid var(--tool-tip-background-color);\n    bottom: 0;\n    left: calc(var(--tool-tip-arrow-pos) - 0.3em);\n}\n\n\n.absol-tooltip.top {\n    padding-bottom: 0.3em;\n}\n\n\n.absol-tooltip.bottom .absol-tooltip-arrow {\n    border-left: 0.3em solid transparent;\n    border-right: 0.4em solid transparent;\n    border-bottom: 0.3em solid var(--tool-tip-background-color);\n\n    top: 0;\n    left: calc(var(--tool-tip-arrow-pos) - 0.3em);\n}\n\n.absol-tooltip.bottom {\n    padding-top: 0.3em;\n}\n\n\n.absol-tooltip.left .absol-tooltip-arrow {\n    border-top: 0.3em solid transparent;\n    border-bottom: 0.4em solid transparent;\n    border-left: 0.4em solid var(--tool-tip-background-color);\n\n    right: 0;\n    top: calc(var(--tool-tip-arrow-pos) - 0.3em);\n}\n\n.absol-tooltip.left {\n    padding-right: 0.4em;\n}\n\n\n.absol-tooltip.right .absol-tooltip-arrow {\n    border-top: 0.4em solid transparent;\n    border-bottom: 0.4em solid transparent;\n    border-right: 0.4em solid var(--tool-tip-background-color);\n\n    left: 0;\n    top: calc(var(--tool-tip-arrow-pos) - 0.3em);\n}\n\n.absol-tooltip.ne .absol-tooltip-arrow {\n    border-top: 0.3em solid transparent;\n    border-bottom: 0.4em solid transparent;\n    border-left: 0.4em solid var(--tool-tip-background-color);\n    bottom: -0.3em;\n    left: 0;\n}\n\n.absol-tooltip.nw .absol-tooltip-arrow {\n    border-top: 0.3em solid transparent;\n    border-bottom: 0.4em solid transparent;\n    border-right: 0.4em solid var(--tool-tip-background-color);\n    bottom: -0.3em;\n    right: 0;\n}\n\n.absol-tooltip.se .absol-tooltip-arrow {\n    border-top: 0.3em solid transparent;\n    border-bottom: 0.4em solid transparent;\n    border-left: 0.4em solid var(--tool-tip-background-color);\n    top: -0.3em;\n    left: 0;\n}\n\n.absol-tooltip.sw .absol-tooltip-arrow {\n    border-top: 0.3em solid transparent;\n    border-bottom: 0.4em solid transparent;\n    border-right: 0.4em solid var(--tool-tip-background-color);\n    top: -0.25em;\n    right: 0;\n}\n\n.absol-tooltip.right {\n    padding-left: 0.4em;\n}\n\n\n.absol-tooltip-root {\n    position: relative;\n    width: 0;\n    height: 0;\n}\n\n.absol-tooltip-root-holder {\n    position: fixed;\n    z-index: 100000000;\n    left: 0;\n    top: 0;\n}", ""]);



/***/ }),
/* 230 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-tree-list {}\n\n.absol-tree-list-item {}\n\n.absol-tree-list-item-parent:hover {\n    background: #efefef;\n    cursor: pointer;\n}\n\n.absol-tree-list-item-parent {\n    padding-left: 0.3em;\n    padding-right: 0.6em;\n    position: relative;\n}\n\n.absol-tree-list-item.active>.absol-tree-list-item-parent {\n    background: #dfdfdf;\n}\n\n.absol-tree-list-item-parent>span {\n    line-height: 20px;\n    white-space: nowrap;\n}\n\n.absol-tree-list-item-child {}\n\n.absol-tree-list-item>.absol-tree-list-item-child:empty {\n    display: none;\n}\n\n.absol-tree-list-item-desc-container {\n    right: 0.3em;\n    top: 0;\n    bottom: 0;\n    position: absolute;\n}\n\n.absol-tree-list-item-desc {\n    font-style: italic;\n    line-height: 20px;\n    white-space: nowrap;\n    margin-left: 1em;\n    color: rgb(37, 37, 37);\n}\n\n.absol-tree-list-item-desc:empty {\n    display: none;\n}", ""]);



/***/ }),
/* 231 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(232);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 232 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-selecttreemenu  .absol-tree-list-item-desc-container{\n    right: 30px;\n}\n\n\n.absol-selectmenu-holder-item .absol-tree-list-item-parent:hover {\n    background-color: transparent;\n}", ""]);



/***/ }),
/* 233 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(234);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 234 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-width-height-resizer {\n    position: relative;\n    box-sizing: border-box;\n}\n\n.absol-width-height-resizer-anchor-bot-right {\n    cursor: nwse-resize;\n    position: absolute;\n    z-index: 1;\n    right: 0;\n    bottom: 0;\n    height: 13px;\n    width: 13px;\n    background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA0AAAANCAYAAABy6+R8AAAACXBIWXMAAA7EAAAOxAGVKw4bAAAAQUlEQVQoz2NgIBGkpaX9Z2IgA9BWU1pa2n+S/UGSZnRFBDVhU4BXEy4bcGrC5ySsmgj5AUMTMZ4mOehhmhjJ0QkA9TYwPsqIBKMAAAAASUVORK5CYII=');\n}\n\n.absol-width-height-resizer-anchor-bot-left {\n    cursor: nesw-resize;\n    position: absolute;\n    z-index: 1;\n    left: 0;\n    bottom: 0;\n    height: 13px;\n    width: 13px;\n    background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA0AAAANCAYAAABy6+R8AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAABCSURBVChTY0hLS/vPQCJggtIkAco0keRMZMVEa0RXSJRGbIoIaoQpIMlGZEmiNRJSiFUjNkGCGrGaRAAwkq6JgQEAnaEwPtyU/MEAAAAASUVORK5CYII=');\n}\n\n.absol-width-height-resizer-anchor-top-right {\n    cursor: nesw-resize;\n    position: absolute;\n    z-index: 1;\n    right: 0;\n    top: 0;\n    height: 13px;\n    width: 13px;\n    background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA0AAAANCAYAAABy6+R8AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAABMSURBVChTY0xLS/vPQGsAsoQJygYDdFuJdgUhjTgNwqcQpyYQwKURryYQwKaAoCYQwGUjQYCskGhNIABTTJImGABpQolcYgEZmhgYAEPpMD56IPESAAAAAElFTkSuQmCC')\n}\n\n.absol-width-height-resizer-anchor-top-left {\n    cursor: nwse-resize;\n    position: absolute;\n    z-index: 1;\n    top: 0;\n    left: 0;\n    height: 13px;\n    width: 13px;\n    background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA0AAAANCAYAAABy6+R8AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAABNSURBVChTnZFbCgAgCAStw3r/GxQLClaSj/kJckcFBzMvqtKRprwHd6OncRRwN7GfKQFoIS0Ar/gVQGmCYkMpAWgwLYBSWHCPG9GQiDbsRTA+Srvt5gAAAABJRU5ErkJggg==');\n}\n\n.absol-width-height-resizer-content {\n    width: 100%;\n    height: 100%;\n    overflow: auto;\n}\n\n/* .absol-width-height-resizer */", ""]);



/***/ }),
/* 235 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(236);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 236 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-modal {\n    position: fixed;\n    left: 0;\n    right: 0;\n    top: 0;\n    bottom: 0;\n    z-index: 1000;\n    white-space: nowrap;\n}\n\n.as-modal.as-hidden {\n    z-index: -1000;\n    visibility: hidden;\n    opacity: 0;\n}\n\n.as-modal.as-center {\n    text-align: center;\n}\n\n\n.as-modal.as-middle::before {\n    content: \"\";\n    display: inline-block;\n    vertical-align: middle;\n    height: 100%;\n    width: 0;\n}\n\n.as-modal > .as-modal-content {\n    display: inline-block;\n    text-align: initial;\n    white-space: initial;\n}\n\n/*for content*/\n.as-modal.as-middle > .as-modal-content {\n    vertical-align: middle;\n}\n\n.as-loading-cube-modal {\n    background-color: rgba(169, 169, 169, 0.3);\n}\n\n\n.as-loading-cube-modal {\n    z-index: 1000000;\n    background-color: rgba(169, 169, 169, 0.3);\n}\n.as-loading-cube-modal > .as-modal-content{\n    background-color: white;\n    border-radius: 4px;\n    padding: 10px;\n    -webkit-box-shadow: 2px 2px 9px 0px rgba(20, 20, 20, 1);\n    -moz-box-shadow: 2px 2px 9px 0px rgba(20, 20, 20, 1);\n    box-shadow: 2px 2px 9px 0px rgba(20, 20, 20, 1);\n    display: inline-block;\n}\n.as-loading-cube-modal > .as-modal-content > svg {\n    width: 5em;\n    height: 5em;\n}\n", ""]);



/***/ }),
/* 237 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(238);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 238 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-trackbar {\n    height: 1.2em;\n    min-width: 7em;\n    display: inline-block;\n    vertical-align: middle;\n    -webkit-touch-callout: none;\n    -webkit-user-select: none;\n    -khtml-user-select: none;\n    -moz-user-select: none;\n    -ms-user-select: none;\n    user-select: none;\n    padding: 0 0.6em;\n    box-sizing: border-box;\n}\n\n.absol-trackbar-line {\n    display: block;\n    position: relative;\n    margin-top: 0.4em;\n    height: 0.4em;\n    background-color: rgb(200, 200, 200);\n    -webkit-box-shadow: 0 0 0.2em 0.1em rgb(160, 160, 160) inset;\n    -moz-box-shadow: 0 0 0.2em 0.1em rgb(160, 160, 160) inset;\n    box-shadow: 0 0 0.2em 0.1em rgb(160, 160, 160) inset;\n    border-radius: 0.15em;\n    cursor: pointer;\n}\n\n.absol-trackbar-button {\n    position: absolute;\n    z-index: 1;\n    top: -0.4em;\n    /* bottom: -0.4em; */\n    height: 1.2em;\n    left: 0;\n    margin-left: -0.6em;\n    width: 1.2em;\n    background: rgb(245, 245, 245);\n    cursor: pointer;\n    border-radius: 50%;\n    border: solid 1px rgb(139, 139, 139);\n}\n\n.absol-trackbar.as-disabled {\n    pointer-events: none;\n}\n\n.absol-trackbar.as-disabled .absol-trackbar-button {\n    background: rgb(225, 225, 225);\n    border: solid 1px rgb(200, 200, 200);\n}\n\n.absol-trackbar.as-disabled .absol-trackbar-line {\n    background-color: rgb(220, 220, 220);\n    -webkit-box-shadow: 0 0 0.2em 0.1em rgb(200, 200, 200) inset;\n    -moz-box-shadow: 0 0 0.2em 0.1em rgb(200, 200, 200) inset;\n    box-shadow: 0 0 0.2em 0.1em rgb(200, 200, 200) inset;\n}", ""]);



/***/ }),
/* 239 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(240);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 240 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-trackbar-input {\n    box-sizing: border-box;\n    display: inline-block;\n    white-space: nowrap;\n    position: relative;\n    min-width: 13.5em;\n    height: 2em;\n    --input-width: 4em;\n}\n\n.absol-trackbar-input::after {\n    content: \"\";\n    vertical-align: middle;\n    height: 100%;\n}\n\n.absol-trackbar-input > .absol-trackbar {\n    display: inline-block;\n    vertical-align: middle;\n    width: calc(100% - var(--input-width) - 5px);\n}\n\n\n.absol-trackbar-input > .as-flexicon-input {\n    width: var(--input-width);\n    vertical-align: middle;\n    height: 2em;\n    box-sizing: border-box;\n    margin-left: 5px;\n}\n\n.absol-trackbar-input.as-disabled {\n    pointer-events: none;\n    color: #777777;\n\n}\n\n.absol-trackbar-input input {\n    color: inherit;\n}\n", ""]);



/***/ }),
/* 241 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(242);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 242 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-button-range-wrapper {\n    border-top: 1px solid rgb(209, 209, 213);\n    border-bottom: 1px solid rgb(209, 209, 213);\n}\n\n.as-button-range {\n    position: relative;\n    overflow-y: hidden;\n    height: var(--height);\n    box-sizing: border-box;\n    font-family: Arial, Helvetica, sans-serif;\n    --underline-left: 0;\n    --underline-width: 0;\n    --height: 2em;\n}\n\n.as-button-range-scroller {\n    font-size: inherit;\n    height: calc(var(--height) + 17px);\n    box-sizing: border-box;\n    overflow-x: scroll;\n    position: absolute;\n    top: 0;\n    left: 0.5em;\n    right: 0.5em;\n    white-space: nowrap;\n}\n\n.as-button-range-scroller::after {\n    content: \"\";\n    position: absolute;\n    left: var(--underline-left);\n    width: var(--underline-width);\n    height: 0.2em;\n    top: calc(var(--height) - 0.2em);\n    background-color: rgb(0, 106, 255);\n    transition: left 0.2s, width 0.2s;\n}\n\n.as-button-range-left-ctn,\n.as-button-range-right-ctn {\n    position: absolute;\n    top: 0;\n    bottom: 0;\n}\n\n.as-button-range-right-ctn::after,\n.as-button-range-left-ctn::before {\n    content: \"\";\n    height: 100%;\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.as-button-range-left-ctn {\n    left: 0;\n}\n\n.as-button-range-right-ctn {\n    right: 0;\n}\n\n.as-button-range-right-btn,\n.as-button-range-left-btn {\n    font-size: inherit;\n    padding: 0;\n    margin: 0;\n    display: inline-block;\n    vertical-align: middle;\n    border: none;\n    outline: none;\n    color: rgb(0, 106, 266);\n    background-color: rgba(255, 255, 255, 0.5);\n    border-radius: 0.5em;\n    overflow: hidden;\n}\n\n.as-button-range-left-btn {\n    -webkit-box-shadow: 1em 2px 1.5em -1em rgba(255, 255, 255, 0.62);\n    -moz-box-shadow: 1em 2px 1.5em -1em rgba(255, 255, 255, 0.62);\n    box-shadow: 1em 2px 1.5em -1em rgba(255, 255, 255, 0.62);\n}\n\n.as-button-range-right-btn {\n    -webkit-box-shadow: -1em 2px 1.5em -1em rgba(255, 255, 255, 0.62);\n    -moz-box-shadow: -1em 2px 1.5em -1em rgba(255, 255, 255, 0.62);\n    box-shadow: -1em 2px 1.5em -1em rgba(255, 255, 255, 0.62);\n}\n\n.as-button-range-right-btn polygon,\n.as-button-range-left-btn polygon {\n    fill: #2488FF;\n}\n\n.as-button-range-right-btn:disabled,\n.as-button-range-left-btn:disabled {\n    display: none;\n}\n\n.as-button-range-left-btn > svg,\n.as-button-range-right-btn > svg {\n    width: 1.25em;\n    height: 1.25em;\n    margin-left: -0.25em;\n    margin-right: -0.25em;\n    vertical-align: middle;\n}\n\n\n.as-button-range-item {\n    outline: none;\n    font-size: inherit;\n    padding: 0 0.5em;\n    margin: 0;\n    height: var(--height);\n    border: none;\n    background-color: transparent;\n    color: black;\n}\n\n.as-button-range-item.as-active {\n    color: rgb(87, 157, 255);\n}", ""]);



/***/ }),
/* 243 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(244);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 244 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-drop-zone {\n}", ""]);



/***/ }),
/* 245 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(246);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 246 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, "label.as-radio-input {\n    display: inline-block;\n    position: relative;\n    width: calc(1em + 2px);\n    height: calc(1em + 2px);\n    cursor: pointer;\n    font-size: inherit;\n    box-sizing: border-box;\n    overflow: hidden;\n    vertical-align: middle;\n    border-radius: 50%;\n    border: 1px solid var(--candy-border-color);\n    text-align: center;\n    background-color: white;\n    text-align: center;\n    white-space: nowrap;\n}\n\nlabel.as-radio-input:hover {\n    background-color: var(--candy-hover-background-color);\n}\n\nlabel.as-radio-input::after{\n    content: \"\";\n    display: inline-block;\n    vertical-align: middle;\n    height: 100%;\n}\n\n.as-radio-input .as-radio-input-check-mark {\n    display: inline-block;\n    vertical-align: middle;\n    width: 0.5em;\n    height: 0.5em;\n    background-color: #606060;\n    font-size: inherit;\n    border-radius: 50%;\n}\n\n.as-radio-input input.as-radio-input-value {\n    font-size: inherit;\n    position: absolute;\n    right: 100%;\n    top: 0;\n    opacity: 0.0;\n}\n\ninput.as-radio-input-value:not(:checked) ~ .as-radio-input-check-mark {\n    display: none;\n}\n\n\nlabel.as-radio-input.as-disabled,\nlabel.as-radio-input.as-disabled:hover {\n    border-color: #929292;\n    background-color: #ebebe4;\n}", ""]);



/***/ }),
/* 247 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(248);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 248 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-onscreen-widget {\n    --client-width: 0px;\n    --client-height: 0px;\n    --cx: 0.9;\n    --cy: 0.9;\n    position: fixed;\n    z-index: 1000000;\n    left: calc((100vw - var(--client-width) - 4px) * var(--cx) + 2px);\n    top: calc((100vh - var(--client-height) - 4px) * var(--cy) + 2px);\n    touch-action: none;\n    user-select: none;\n}\n\n.as-onscreen-widget.as-size-loading {\n    visibility: hidden;\n}", ""]);



/***/ }),
/* 249 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(250);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 250 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-ribbon-split-button {\n    display: inline-block;\n    vertical-align: middle;\n    height: 30px;\n    font-family: Arial, Helvetica, sans-serif;\n    box-sizing: border-box;\n}\n\n.as-ribbon-split-button div,\n.as-ribbon-split-button span,\n.as-ribbon-split-button button {\n    font-weight: inherit;\n    font-size: inherit;\n}\n\n\n.as-ribbon-split-button-content {\n    height: 100%;\n}\n\n.as-ribbon-split-button-content > button {\n    font-family: inherit;\n    border-radius: 0;\n    background-color: transparent;\n    height: 100%;\n    margin-right: 0;\n    outline: none;\n    box-sizing: border-box;\n    border-style: solid;\n    border-color: transparent;\n    vertical-align: middle;\n}\n\n\n.as-ribbon-split-button-content > button:hover {\n    background-color: rgba(169, 168, 169, 0.15);\n}\n\n.as-ribbon-split-button-content > button:active {\n    background-color: rgba(169, 168, 169, 0.3);\n}\n\n\n.as-ribbon-split-button-primary {\n    font-size: inherit;\n    padding-left: 0.5em;\n    padding-right: 0;\n    border-width: 1px 0px 1px 1px;\n}\n\n.as-ribbon-split-button-extend {\n    color: rgb(37, 36, 35);\n    width: 16px;\n    padding: 0;\n    text-align: center;\n    font-size: 20px;\n    border-width: 1px 1px 1px 0px;\n}\n\n.as-ribbon-split-button-extend span:before {\n    margin-left: -3px;\n}\n\n\n.as-ribbon-split-button:active:hover .as-ribbon-split-button-content > button,\n.as-ribbon-split-button:active .as-ribbon-split-button-content > button {\n    border-color: rgba(169, 168, 169, 0.3);\n}\n\n.as-ribbon-split-button:hover .as-ribbon-split-button-content > button {\n    border-color: rgba(169, 168, 169, 0.15);\n}\n\n.as-ribbon-split-button-icon {\n    font-size: 1.2em;\n    margin-right: 0.5em;\n    display: inline-block;\n    vertical-align: middle;\n}\n\nimg.as-ribbon-split-button-icon,\nsvg.as-ribbon-split-button-icon {\n    width: 1.2em;\n    height: 1.2em;\n}\n\n.as-ribbon-split-button-text {\n    vertical-align: middle;\n    font-size: inherit;\n}\n\n.as-ribbon-split-button.as-no-dropdown .as-ribbon-split-button-extend {\n    display: none;\n}\n\n.as-ribbon-split-button.as-no-dropdown .as-ribbon-split-button-primary {\n    padding-right: 5px;\n    border-width: 1px 1px 1px 1px;\n}", ""]);



/***/ }),
/* 251 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(252);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 252 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-ribbon-button {\n    display: inline-block;\n    vertical-align: middle;\n    height: 30px;\n    padding-left: 0.5em;\n    padding-right: 0.5em;\n\n    font-family: Arial, Helvetica, sans-serif;\n    box-sizing: border-box;\n    border-radius: 0;\n    outline: none;\n    border-style: solid;\n    border-color: transparent;\n    border-width: 1px 1px 1px 1px;\n    background-color: transparent;\n}\n\n.as-ribbon-button div,\n.as-ribbon-button span {\n    font-weight: inherit;\n    font-size: inherit;\n}\n\n.as-ribbon-button:hover {\n    background-color: rgba(169, 168, 169, 0.15);\n}\n\n.as-ribbon-button:active {\n    background-color: rgba(169, 168, 169, 0.3);\n}\n\n\n\n.as-ribbon-split-button:active:hover .as-ribbon-split-button-content > button,\n.as-ribbon-split-button:active .as-ribbon-split-button-content > button {\n    border-color: rgba(169, 168, 169, 0.3);\n}\n\n.as-ribbon-split-button:hover .as-ribbon-split-button-content > button {\n    border-color: rgba(169, 168, 169, 0.15);\n}\n\n.as-ribbon-button-icon {\n    font-size: 1.2em;\n    margin-right: 0.5em;\n    display: inline-block;\n    vertical-align: middle;\n}\n\nimg.as-ribbon-button-icon,\nsvg.as-ribbon-button-icon {\n    width: 1.2em;\n    height: 1.2em;\n}\n\n.as-ribbon-button-text {\n    display: inline-block;\n    vertical-align: middle;\n    font-size: inherit;\n}\n\n.as-ribbon-button.as-no-dropdown .mdi.mdi-chevron-down {\n    display: none;\n}", ""]);



/***/ }),
/* 253 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(254);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 254 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-time-select-input {\n    display: inline-block;\n    position: relative;\n    height: 30px;\n    border: solid 1px #d6d6d6;\n    border-radius: 2px;\n    box-sizing: border-box;\n    cursor: pointer;\n    font-size: 14px;\n    outline: none;\n    font-family: \"Helvetica Neue\", Arial, Helvetica, sans-serif;\n    white-space: nowrap;\n    padding-right: 30px;\n    --list-min-width: unset;\n    width: calc(var(--list-min-width) + 30px);\n    min-width: calc(var(--list-min-width) + 30px);\n}\n\n.as-time-select-input.as-disabled {\n    pointer-events: none;\n    background-color: #ebebe4;\n}\n\n.as-time-select-input-text {\n    display: inline-block;\n    vertical-align: middle;\n    height: 100%;\n    width: 100%;\n    outline: none;\n    border: none;\n    box-sizing: border-box;\n    padding-left: 10px;\n    padding-right: 0;\n    background-color: transparent;\n}", ""]);



/***/ }),
/* 255 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(256);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 256 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-snackbar {\n    visibility: hidden;\n    min-width: 250px;\n    margin-left: -125px;\n    background-color: #333;\n    color: #fff;\n    text-align: center;\n    border-radius: 2px;\n    padding: 16px;\n    position: fixed;\n    z-index: 1;\n    left: 50%;\n    bottom: 0;\n    font-size: 17px;\n    opacity: 0;\n    transition: opacity 0.25s ease-in, bottom 0.25s ease-in;\n\n}\n\n.as-snackbar.as-show {\n    visibility: visible;\n    bottom: 30px;\n    opacity: 1;\n}\n\n.as-snackbar.as-hiding{\n    transition: opacity 0.5s ease-out, bottom 0.5s ease-out;\n    visibility: visible;\n    bottom: 0;\n    opacity: 0;\n}\n\n", ""]);



/***/ }),
/* 257 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(258);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 258 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ":root {\n    --multi-select-menu-max-height: 90px;\n}\n\n.as-multi-select-menu {\n    --list-min-width: 40px;\n    display: inline-block;\n    vertical-align: middle;\n    position: relative;\n    min-height: var(--select-box-min-height);\n    min-width: var(--list-min-width);\n    border: solid 1px #d6d6d6;\n    border-radius: 3px;\n    box-sizing: border-box;\n    outline: none;\n    background-color: white;\n    padding-right: 45px;\n}\n\n.as-multi-select-menu-item-ctn {\n    display: block;\n    max-height: var(--multi-select-menu-max-height);\n    overflow-y: auto;\n}\n\n\n.as-multi-select-menu-toggle-btn {\n    position: absolute;\n    right: 0;\n    top: 0;\n    bottom: 0;\n    width: 30px;\n    pointer-events: none;\n    border: none;\n    background-color: transparent;\n}\n\n.as-multi-select-menu-toggle-btn svg.dropdown {\n    width: 10px;\n    height: 10px;\n    fill: #929292;\n}\n\n.as-multi-select-menu:hover svg.dropdown {\n    fill: black;\n}\n\n.as-multi-select-menu.as-disable-click-to-focus .as-multi-select-menu-toggle-btn {\n    display: none;\n}\n\n.as-multi-select-menu .absol-selectbox-item {\n    margin: calc((var(--select-box-min-height) - 2px - var(--select-box-item-height)) / 2) 2px;\n}\n\n\n.as-multi-select-menu.as-item-focusable .absol-selectbox-item.as-active {\n    background-color: var(--select-box-focus-item-color);\n}\n\n.as-multi-select-menu.as-disabled {\n    pointer-events: none;\n    background-color: #ebebe4;\n}\n\n\n.as-multi-select-menu.as-multi-check-tree-leaf-menu {\n    min-width: calc(var(--select-list-estimate-width) + 14px);\n}\n", ""]);



/***/ }),
/* 259 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-countdown-clock {\n    width: 7em;\n    height: 7em;\n    border-radius: 50%;\n    position: relative;\n    display:inline-block;\n    font-family: Consolas;\n}\n\n.as-countdown-clock-border-wrapper{\n    pointer-events:none;\n    position: absolute;\n    box-sizing: border-box;\n    left: 0.2em;\n    right: 0.2em;\n    top: 0.2em;\n    bottom: 0.2em;\n    filter: drop-shadow(0 0px 1px rgb(100, 200, 255));\n}\n\n.as-countdown-clock-border {\n    width: 100%;\n    height: 100%;\n    border: solid 0.2em rgb(100, 200, 255);\n    border-radius: 50%;\n    object-fit: cover;\n}\n\n.as-countdown-clock-text {\n    position: absolute;\n    left: 50%;\n    top: 50%;\n    transform:translate(-50%, -50%);\n    font-size: 2em;\n}\n\n.as-countdown-clock div,\n.as-countdown-clock span\n{\n    font-family: inherit;\n}", ""]);



/***/ }),
/* 260 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(261);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 261 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-toast-list {\n    position: fixed;\n    z-index: 1100000000;\n    width: 355px;\n    max-height: calc(100vh - 20px);\n    overflow-y: auto;\n}\n\n.as-toast-list > .as-toast {\n    box-shadow: 1px 1px 3px 1px rgba(0, 0, 0, 0.35);\n}\n\n\n.as-toast-list.as-se {\n    bottom: 10px;\n    right: 10px;\n}\n\n.as-toast-list.as-sw {\n    bottom: 10px;\n    left: 10px;\n}\n\n.as-toast-list.as-ne {\n    top: 10px;\n    right: 10px;\n}\n\n.as-toast-list.as-nw {\n    top: 10px;\n    left: 10px;\n}\n\n\n.as-toast-list:empty {\n    visibility: hidden;\n}\n\n.as-toast-list.as-ne > .as-toast,\n.as-toast-list.as-nw > .as-toast {\n    margin-bottom: 5px;\n}\n\n.as-toast-list.as-se > .as-toast,\n.as-toast-list.as-sw > .as-toast {\n    margin-top: 5px;\n}\n\n\n.as-toast {\n    display: block;\n    max-width: 350px;\n    overflow: hidden;\n    background-color: white;\n    background-clip: padding-box;\n    border: 1px solid rgba(0, 0, 0, 0.1);\n    font-family: Roboto, sans-serif;\n    font-size: 14px;\n}\n\n.as-toast-header {\n    display: flex;\n    display: -ms-flex;\n    -ms-flex-align: center;\n    align-items: center;\n    padding: 0.25em 0.75em;\n    color: #6c757d;\n    background-clip: padding-box;\n    border-bottom: 1px solid rgba(0, 0, 0, 0.05);\n}\n\n.as-toast-header strong {\n    text-align: left;\n    margin-right: auto;\n}\n\n.as-toast-variant-color {\n    margin-right: 0.5em;\n    display: inline-block;\n    vertical-align: middle;\n    background-color: var(--variant-color-primary);\n    width: 1.25em;\n    height: 1.25em;\n}\n\n\n.as-toast-close-btn {\n    padding: 0;\n    background-color: transparent;\n    border: none;\n    outline: none;\n    color: inherit;\n    margin-left: 0.25em;\n    margin-bottom: 0.25em;\n}\n\n.as-toast-close-btn:hover {\n    color: black;\n}\n\n.as-toast-close-btn span {\n    font-size: 1.5em;\n    text-shadow: 0 1px 0 currentColor;\n}\n\n.as-toast-body {\n\n}\n\n.as-toast-message {\n    padding: 0.75em;\n}\n\n\n.as-toast.as-not-appeared {\n    opacity: 0;\n    transition: opacity 0.2s;\n}\n\n.as-toast.as-not-appeared.as-appearing {\n    opacity: 1;\n}\n\n.as-toast.as-appeared {\n    transition: opacity 0.5s;\n    opacity: 1;\n}\n\n.as-toast.as-disappearing {\n    opacity: 0;\n}\n\n.as-toast.as-variant-sticky-note {\n    background-color: #ffff88;\n}\n\n\n.as-toast.as-variant-sticky-note .as-toast-variant-color,\n.as-toast.as-variant-background .as-toast-variant-color {\n    display: none;\n}\n\n.as-toast.as-variant-sticky-note .as-toast-title {\n    color: #1e1ec8;\n}", ""]);



/***/ }),
/* 262 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(263);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 263 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ":root {\n    --variant-color-primary: #007bff;\n    --variant-color-secondary: #6c757d;\n    --variant-color-success: #28a745;\n    --variant-color-warning: #ffc107;\n    --variant-color-danger: #dc3545;\n    --variant-color-info: #17a2b8;\n    --variant-color-light: #f8f9fa;\n    --variant-color-dark: #343a40;\n    --variant-color-error: #ff4052;\n    --variant-color-link: #007bff;\n    --variant-color-note: #ffff88;\n\n\n    --variant-medium-contract-color-primary: #e2edd5;\n    --variant-medium-contract-color-secondary: #fca75b;\n    --variant-medium-contract-color-success: #fce8e8;\n    --variant-medium-contract-color-info: #fcf5e8;\n    --variant-medium-contract-color-warning: #5e5a75;\n    --variant-medium-contract-color-error:#e0dfce;\n    --variant-medium-contract-color-danger: #e5e8d5;\n    --variant-medium-contract-color-light: #7a5b3c;\n    --variant-medium-contract-color-dark: #bf7d3b;\n    --variant-medium-contract-color-link: #dde8c9;\n    --variant-medium-contract-color-note: #1e1ec8;\n}", ""]);



/***/ }),
/* 264 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(265);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 265 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-emoji-picker-tooltip {\n    --tool-tip-background-color: white;\n    filter: drop-shadow(2px 2px 4px rgba(0, 0, 0, 0.5));\n}\n\n.as-emoji-picker-tooltip .absol-tooltip-content {\n    display: block;\n    padding: 0;\n    box-sizing: border-box;\n    position: relative;\n    white-space: nowrap;\n    overflow: hidden;\n}\n\n.as-emoji-picker-tooltip-left-btn,\n.as-emoji-picker-tooltip-right-btn {\n    display: inline-block;\n    vertical-align: middle;\n    height: 60px;\n    width: 40px;\n    font-size: 25px;\n    padding: 0;\n    background-color: transparent;\n    border: none;\n    color: rgb(155, 155, 175);\n    outline: none;\n}\n\n.as-emoji-picker-tooltip-left-btn:hover,\n.as-emoji-picker-tooltip-right-btn:hover {\n    background-color: rgba(156, 156, 156, 0.15);\n}\n\n.as-emoji-picker-tooltip-left-btn:active,\n.as-emoji-picker-tooltip-right-btn:active {\n    background-color: rgba(0, 0, 0, 0.15);\n}\n\n.as-emoji-picker-tooltip-left-btn:disabled,\n.as-emoji-picker-tooltip-right-btn:disabled {\n    pointer-events: none;\n    color: rgb(230, 230, 235);\n}\n\n.as-emoji-picker-tooltip-scroller {\n    display: inline-block;\n    vertical-align: middle;\n    position: relative;\n    width: 360px;\n    height: 60px;\n    overflow: hidden;\n}\n\n.as-emoji-picker-tooltip-icon-list {\n    position: absolute;\n    top: 0;\n    bottom: 0;\n    left: 0;\n    white-space: nowrap;\n}\n\n\n.as-emoji-picker-tooltip:not(.as-scrolling) .as-emoji-picker-tooltip-icon-list {\n    transition: left 0.5s;\n}\n\n.as-emoji-picker-tooltip-icon-btn {\n    display: inline-block;\n    vertical-align: middle;\n    height: 60px;\n    width: 60px;\n    padding: 0;\n    border: none;\n    outline: none;\n    background-color: transparent;\n}\n\n\n.as-emoji-picker-tooltip-icon {\n    transition: width 0.3s, height 0.3s;\n    width: 35px;\n    height: 35px;\n}\n\n.as-emoji-picker-tooltip-icon-btn:hover .as-emoji-picker-tooltip-icon {\n    width: 45px;\n    height: 45px;\n}\n\n.as-emoji-picker-tooltip-remove-btn {\n    display: inline-block;\n    vertical-align: middle;\n    height: 60px;\n    width: 60px;\n    padding: 0;\n    border: none;\n    outline: none;\n    background-color: transparent;\n    font-size: 40px;\n    color: rgb(185, 185, 185);\n}\n\n.as-emoji-picker-tooltip-remove-btn:hover {\n    color: rgb(255, 30, 30);\n}\n\n\n.as-emoji-picker-tooltip:not(.as-mobile) .as-emoji-picker-tooltip-page-indicator {\n    display: none;\n}\n\n.as-emoji-picker-tooltip.as-mobile .as-emoji-picker-tooltip-right-btn,\n.as-emoji-picker-tooltip.as-mobile .as-emoji-picker-tooltip-left-btn {\n    display: none;\n}\n\n\n@media (max-width: 410px) and (min-width: 310px) {\n    .as-emoji-picker-tooltip-left-btn,\n    .as-emoji-picker-tooltip-right-btn {\n        height: 36px;\n        width: 24px;\n        font-size: 15px;\n    }\n\n    .as-emoji-picker-tooltip-scroller {\n        width: 216px;\n        height: 36px;\n    }\n\n    .as-emoji-picker-tooltip-icon-btn {\n        height: 36px;\n        width: 36px;\n    }\n\n\n    .as-emoji-picker-tooltip-icon {\n        width: 21px;\n        height: 21px;\n    }\n\n    .as-emoji-picker-tooltip-icon-btn:hover .as-emoji-picker-tooltip-icon {\n        width: 27px;\n        height: 27px;\n    }\n\n    .as-emoji-picker-tooltip-remove-btn {\n        height: 36px;\n        width: 36px;\n        font-size: 24px;\n    }\n}\n\n@media (max-width: 510px) and (min-width: 410px) {\n    .as-emoji-picker-tooltip-left-btn,\n    .as-emoji-picker-tooltip-right-btn {\n        height: 48px;\n        width: 32px;\n        font-size: 20px;\n    }\n\n\n    .as-emoji-picker-tooltip-scroller {\n        width: 288px;\n        height: 48px;\n    }\n\n\n    .as-emoji-picker-tooltip-icon-btn {\n        height: 48px;\n        width: 48px;\n    }\n\n\n    .as-emoji-picker-tooltip-icon {\n        width: 28px;\n        height: 28px;\n    }\n\n    .as-emoji-picker-tooltip-icon-btn:hover .as-emoji-picker-tooltip-icon {\n        width: 36px;\n        height: 36px;\n    }\n\n    .as-emoji-picker-tooltip-remove-btn {\n        height: 48px;\n        width: 48px;\n        font-size: 32px;\n    }\n}", ""]);



/***/ }),
/* 266 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(267);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 267 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-page-indicator {\n    text-align: center;\n    white-space: nowrap;\n}\n\n.as-page-indicator::before{\n    content: \"\";\n    display: inline-block;\n    vertical-align: middle;\n    height: 100%;\n}\n\n.as-page-indicator-item {\n    display: inline-block;\n    vertical-align: middle;\n    text-align: center;\n    font-size: inherit;\n    width: 1.5em;\n    padding: 0;\n    border: 0;\n    background-color: transparent;\n}\n\n\n\n.as-page-indicator-item::before {\n    content: \"\";\n    display: inline-block;\n    height: 0.5em;\n    width: 0.5em;\n    transition: width 0.25s, height 0.25s, color 0.25s;\n    border-radius: 50%;\n    background-color: rgb(196, 196, 196);\n    font-size: inherit;\n    vertical-align: middle;\n}\n\n.as-page-indicator-item.as-active::before{\n    width: 0.75em;\n    height: 0.75em;\n    background-color: var(--variant-color-primary);\n\n}", ""]);



/***/ }),
/* 268 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(269);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 269 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-emoji-counter {\n    display: inline-block;\n    vertical-align: middle;\n    color: rgb(38, 141, 145);\n    box-sizing: border-box;\n    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.2);\n    height: 30px;\n    text-align: center;\n    min-height: 30px;\n    padding: 0 8px;\n    border-radius: 15px;\n    font-size: 14px;\n    background-color: white;\n    outline: none;\n}\n\n.as-emoji-counter::before {\n    content: \"\";\n    display: inline-block;\n    vertical-align: middle;\n    height: 100%;\n}\n\n.as-emoji-counter-sprite {\n    display: inline-block;\n    vertical-align: middle;\n    width: 18px;\n    height: 18px;\n}\n\n.as-emoji-counter-num {\n    font-family: \"Helvetica Neue\", Arial, Helvetica, sans-serif;\n    margin-left: 0.2em;\n    display: inline-block;\n    vertical-align: middle;\n    font-size: inherit;\n    color: inherit;\n    cursor: default;\n}\n\n.as-emoji-counter-num:empty {\n    display: none;\n}\n\n.as-emoji-counter.as-zero {\n    background-color: rgba(220, 220, 220);\n}\n\n.as-emoji-counter + .as-emoji-counter {\n    margin-left: 0.3em;\n}", ""]);



/***/ }),
/* 270 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(271);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 271 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-emoji-user-list-tooltip {\n    --tool-tip-background-color: white;\n    filter: drop-shadow(2px 2px 4px rgba(0, 0, 0, 0.5));\n    text-align: left;\n}\n\n\n.as-emoji-user-list-tooltip-emoji {\n    position: absolute;\n    width: 60px;\n    height: 60px;\n    top: -30px;\n    left: calc(50% - 30px);\n    z-index: 2;\n\n}\n\n.as-emoji-user-list-tooltip .absol-tooltip-content {\n    min-height: 60px;\n    min-width: 120px;\n    padding-top: 25px;\n}\n\n.as-emoji-user-list-tooltip-user{\n    padding: 3px  10px 3px 0 ;\n}\n\n.as-emoji-user-list-tooltip-user.as-clickable{\n    cursor: pointer;\n}\n\n.as-emoji-user-list-tooltip-avatar {\n    width: 30px;\n    height: 30px;\n    border-radius: 50%;\n    background-size: cover;\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.as-emoji-user-list-tooltip-name {\n    display: inline-block;\n    vertical-align: middle;\n    margin-left: 10px;\n    color: rgb(70, 70, 72);\n    font-family: \"Helvetica Neue\", Arial, Helvetica, sans-serif;\n}", ""]);



/***/ }),
/* 272 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(273);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 273 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-rotated-text {\n\n}\n\n.as-rotated-text::after {\n    content: \"o\";\n    color: transparent;\n    display: inline;\n}\n\n.as-rotated-text-content {\n    transform: rotate(0deg);\n    transform-origin: 0.3em 50%;\n    display: block;\n    zoom: 1.001;\n}\n\n\n.as-rotated-text-anchor{\n    position: fixed;\n    z-index: 1000;\n}\n\n.as-rotated-text,.as-rotated-text-anchor,  .as-rotated-text-content{\n    font: inherit;\n}", ""]);



/***/ }),
/* 274 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(275);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 275 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-vertical-tree-diagram {\n    --node-name-max-width: 200px;\n}\n\n\n.as-vertical-tree-diagram-node {\n\n}\n\n.template-ctn {\n    display: none;\n}\n\n.as-vertical-tree-diagram-node, .as-vertical-tree-diagram-node * {\n    box-sizing: border-box;\n}\n\n.as-vertical-tree-diagram-node {\n    display: inline-block;\n    vertical-align: top;\n    position: relative;\n    background: white;\n}\n\n.as-vertical-tree-diagram-child-ctn > .as-vertical-tree-diagram-node:not(:first-child) {\n    margin-left: 10px;\n}\n\n.as-vertical-tree-diagram-node-name-ctn {\n    text-align: center;\n    padding-bottom: 9px;\n}\n\n.as-vertical-tree-diagram-node-name {\n    display: inline-block;\n    padding: 5px;\n    border: 1px solid #333;\n    position: relative;\n    white-space: normal;\n    max-width: var(--node-name-max-width);\n}\n\n.as-vertical-tree-diagram-node.as-has-child > .as-vertical-tree-diagram-node-name-ctn .as-vertical-tree-diagram-node-name::before {\n    content: \"\";\n    position: absolute;\n    height: 10px;\n    left: 50%;\n    top: 100%;\n    border-left: 1px solid #333;\n}\n\n.as-vertical-tree-diagram-node.as-has-child.as-has-1-child > .as-vertical-tree-diagram-node-name-ctn .as-vertical-tree-diagram-node-name::before {\n    height: 20px;\n}\n\n.as-vertical-tree-diagram-child-ctn {\n    padding-top: 10px;\n\n}\n\n.as-vertical-tree-diagram-node:not(.as-has-1-child) > .as-vertical-tree-diagram-child-ctn {\n    border-top: 1px solid #333;\n}\n\n.as-vertical-tree-diagram-node:not(.as-has-child) > .as-vertical-tree-diagram-child-ctn {\n    display: none;\n}\n\n.as-vertical-tree-diagram-child-ctn > .as-vertical-tree-diagram-node::before {\n    content: \"\";\n    position: absolute;\n    z-index: 1;\n    left: 50%;\n    bottom: 100%;\n    height: 10px;\n    border-left: 1px solid black;\n}\n\n.as-vertical-tree-diagram-node.as-has-1-child > .as-vertical-tree-diagram-child-ctn > .as-vertical-tree-diagram-node::before,\n.as-vertical-tree-diagram-node.as-has-1-child > .as-vertical-tree-diagram-child-ctn > .as-vertical-tree-diagram-node::after {\n    display: none;\n}\n\n\n.as-vertical-tree-diagram-child-ctn > .as-vertical-tree-diagram-node:last-child::before {\n    left: unset;\n    right: 50%;\n}\n\n\n.as-vertical-tree-diagram-child-ctn > .as-vertical-tree-diagram-node:first-child::after {\n    content: \"\";\n    position: absolute;\n    z-index: 2;\n    right: 50%;\n    left: 0;\n    bottom: 100%;\n    height: 11px;\n    background-color: white;\n}\n\n.as-vertical-tree-diagram-child-ctn > .as-vertical-tree-diagram-node:last-child::after {\n    content: \"\";\n    position: absolute;\n    z-index: 2;\n    left: 50%;\n    right: 0;\n    bottom: 100%;\n    height: 11px;\n    background-color: white;\n}\n\n.as-vertical-tree-diagram-child-ctn > .as-vertical-tree-diagram-node:first-child:last-child::after {\n    display: none;\n}", ""]);



/***/ }),
/* 276 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(277);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 277 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-token-field {\n    font-size: 14px;\n    border: 1px solid #dddddd;\n}\n\n.as-token-field-input-text {\n    font: inherit;\n    padding: 0;\n    box-sizing: border-box;\n    min-width: 60px;\n    border: none;\n    outline: none;\n    height: var(--select-box-item-height);\n    line-height: var(--select-box-item-height);\n    vertical-align: top;\n    margin-top: 2px;\n}\n\n.absol-selectbox-item.as-token-field-item {\n    font: inherit;\n    margin: 2px;\n    outline: none;\n}\n\n.as-token-field-item:focus {\n    background-color: var(--select-box-focus-item-color);\n}\n", ""]);



/***/ }),
/* 278 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(279);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 279 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-dv-exp-tree {\n\n}\n\n.as-dv-exp-tree > .absol-exp-node > .absol-exp-node-level {\n}\n\n.as-dv-exp-tree > .absol-exp-node > .absol-radio-button {\n    vertical-align: middle;\n    display: inline-block;\n    margin-right: 5px;\n    /*margin-left: 5px;*/\n}\n\n\n.as-dv-exp-tree:not(.as-has-radio) > .absol-exp-node > .absol-radio-button {\n    /*visibility: hidden;*/\n    display: none;\n}\n\n\n.as-dv-exp-tree > .absol-exp-node > .as-dv-exp-tree-index {\n    box-sizing: border-box;\n    padding: 0 0 0 0.5em;\n    margin-left: 0.5em;\n    outline: none;\n    height: 1.2em;\n    min-width: 3em;\n    box-shadow: 0 0  0 1px #dddddd;\n    display: inline-block;\n    vertical-align: middle;\n    background-color: white;\n}\n\n.as-dv-exp-tree > .absol-exp-node > .as-dv-exp-tree-index:hover{\n    box-shadow: 0 0  0 1px #aaaaaa;\n}\n\n.as-dv-exp-tree:not(.as-has-index-input) > .absol-exp-node > .as-dv-exp-tree-index {\n    display: none;\n}\n\n/*.as-dv-exp-tree>.absol-exp-node:not(.status-open):not(.status-close)>.toggler-ico{*/\n/*    display: none;*/\n/*}*/\n\n/*.as-dv-exp-tree .absol-exp-node-ext-icon{*/\n/*    display: none;*/\n/*}*/", ""]);



/***/ }),
/* 280 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(281);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 281 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-check-list-item {\n    padding-left: 0.35em;\n    height: 25px;\n    user-select: none;\n    -webkit-user-select: none;\n    -moz-user-select: none;\n}\n\n.as-check-list-item-checkbox {\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.absol-selectlist-item.as-check-list-item > span {\n    display: inline-block;\n    vertical-align: middle;\n    line-height: 25px;\n}\n\n.absol-selectlist-item.as-check-list-item .absol-selectlist-item-desc {\n    line-height: 25px;\n}", ""]);



/***/ }),
/* 282 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(283);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 283 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-check-list-box.as-select-list-box {\n    width: calc(var(--select-list-estimate-width) + 2px + 5px + 23px + 7px);\n}\n\n.as-check-list-box.as-select-list-box.as-enable-search .as-select-list-box-scroller {\n    max-height: calc(var(--max-height) - 38px - 29px);\n}\n\n.as-check-list-box.as-select-list-box .as-select-list-box-scroller {\n    max-height: calc(var(--max-height) - 29px);\n}\n\n\n.as-select-list-box-footer {\n    height: 29px;\n    border-top: 1px solid #dddddd;\n    box-sizing: border-box;\n    padding-left: 0.35em;\n    white-space: nowrap;\n    position: relative;\n}\n\n.as-select-list-box-footer > *,\n.as-select-list-box-footer::before,\n.as-select-list-box-footer-right::before,\n.as-select-list-box-footer-right > * {\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.as-select-list-box-footer-right::before,\n.as-select-list-box-footer::before {\n    content: \"\";\n    height: 100%;\n}\n\n.as-select-list-box-footer > *:not(:last-child) {\n    margin-right: 60px;\n}\n\n.as-select-list-box-footer .absol-checkbox-label.as-right {\n    padding-left: 0.35em;\n}\n\n.as-select-list-box-footer-right {\n    position: absolute;\n    right: 5px;\n    top: 0;\n    height: 100%;\n}\n\n.as-select-list-box-footer a {\n    cursor: pointer;\n}\n\n.as-select-list-box-footer a:hover {\n    color: #1da1ff;\n}", ""]);



/***/ }),
/* 284 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(285);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 285 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".ac-time-input.as-time-24-input {\n    width: 13em;\n}\n\n\n.as-chrome-time-24-picker .as-chrome-time-picker-h24 {\n    width: 120px;\n}\n\n.as-chrome-time-24-picker-tomorrow-text {\n    display: none;\n}\n\n.as-in-tomorrow.as-chrome-time-picker-btn .as-chrome-time-24-picker-tomorrow-text {\n    display: initial;\n}\n\n.as-chrome-time-24-picker .as-chrome-time-picker-btn:disabled {\n    pointer-events: none;\n}", ""]);



/***/ }),
/* 286 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(287);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 287 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-time-range-24-input {\n    white-space: nowrap;\n    display: inline-block;\n    min-width: 318px;\n}\n\n.as-time-range-24-input > div:first-child {\n    margin-right: 10px;\n}\n", ""]);



/***/ }),
/* 288 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(289);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 289 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-check-tree-item {\n    font-size: 14px;\n    font-family: \"Helvetica Neue\", Arial, Helvetica, sans-serif;\n    height: 28px;\n}\n\n.as-check-tree-item:focus {\n    background-color: unset;\n}\n\n.as-check-tree-item:hover:focus {\n    background-color: rgba(169, 169, 172, 0.1);\n}\n\n.as-check-tree-item .as-checkbox-input {\n    margin-right: 0.35em;\n}", ""]);



/***/ }),
/* 290 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(291);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 291 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-select-list-box-page > .as-check-tree-item {\n    width: 100%;\n}\n\n\n.as-check-tree-box.as-no-transition label.as-checkbox-input .minus ,\n.as-check-tree-box.as-no-transition label.as-checkbox-input .tick{\n    transition: none;\n}\n\n\n.as-check-tree-box.as-select-list-box.as-enable-search .as-select-list-box-scroller {\n    max-height: calc(var(--max-height) - 38px - 29px);\n}\n\n.as-check-tree-box.as-select-list-box .as-select-list-box-scroller {\n    max-height: calc(var(--max-height) - 29px);\n}\n", ""]);



/***/ }),
/* 292 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(293);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 293 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-cpu-viewer{\n    position: fixed;\n    bottom: 5px;\n    right: 5px;\n    box-sizing: border-box;\n    z-index: 1000000000;\n    border: 1px solid black;\n    display: inline-block;\n}\n\n.as-cpu-viewer canvas{\n    display: block;\n}", ""]);



/***/ }),
/* 294 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(295);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 295 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-file-input-box {\n    font-size: 14px;\n    position: relative;\n    width: 100px;\n    height: 100px;\n    box-sizing: border-box;\n    border: 1px solid #dddddd;\n    background-color: white;\n    font-family: Arial, Helvetica, sans-serif;\n    overflow: hidden;\n}\n\n.as-file-input-box-trigger:hover + .as-file-input-box-upload-overlay,\n.as-file-input-box-trigger.as-drag-over + .as-file-input-box-upload-overlay {\n    display: block;\n}\n\n.as-file-input-box-trigger input {\n    visibility: hidden;\n    opacity: 0;\n}\n\n.as-file-input-box-upload-overlay {\n    display: none;\n    pointer-events: none;\n    background-color: rgba(30, 30, 80, 0.3);\n    position: absolute;\n    left: 0;\n    right: 0;\n    top: 0;\n    bottom: 0;\n    z-index: 5;\n    overflow: hidden;\n    text-align: center;\n    white-space: nowrap;\n    font-size: 3em;\n    color: #b0fffb;\n}\n\n.as-file-input-box-upload-overlay::before,\n.as-file-input-box-upload-overlay > span {\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.as-file-input-box-upload-overlay::before {\n    content: \"\";\n    height: 100%;\n}\n\n\n.as-file-input-box-trigger {\n    position: absolute;\n    z-index: 2;\n    left: 0;\n    right: 0;\n    top: 0;\n    bottom: 0;\n    opacity: 0;\n}\n\n.as-file-input-box:not(.as-has-file-name) .as-file-input-box-file-name,\n.as-file-input-box:not(.as-has-file-name) .as-file-input-box-file-name + br,\n.as-file-input-box:not(.as-has-file-size) .as-file-input-box-file-size,\n.as-file-input-box:not(.as-has-value) .as-file-input-box-action-left,\n.as-file-input-box:not(.as-has-value) .as-file-input-box-action-right,\n.as-file-input-box:not(.as-downloadable) .as-file-input-box-action-right,\n.as-file-input-box:not(.as-removable) .as-file-input-box-action-left,\n.as-file-input-box:not(.as-allow-upload) .as-file-input-box-trigger {\n    display: none;\n}\n\n\n.as-file-input-box-background {\n    position: absolute;\n    z-index: 1;\n    left: 4%;\n    top: 4%;\n    right: 4%;\n    bottom: 4%;\n    background-size: contain;\n    background-repeat: no-repeat;\n    background-position: center;\n    overflow: hidden;\n}\n\n.as-file-input-box.as-allow-upload .as-file-input-box-background {\n    background-image: url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4NCjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+DQo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHZlcnNpb249IjEuMSIgIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0Ij4NCiAgIDxwYXRoIGZpbGw9IiNhYWFhYWEiIGQ9Ik0xMyw5SDE4LjVMMTMsMy41VjlNNiwySDE0TDIwLDhWMjBBMiwyIDAgMCwxIDE4LDIySDZDNC44OSwyMiA0LDIxLjEgNCwyMFY0QzQsMi44OSA0Ljg5LDIgNiwyTTExLDE1VjEySDlWMTVINlYxN0g5VjIwSDExVjE3SDE0VjE1SDExWiIgLz4NCjwvc3ZnPg==);\n}\n\n\n.as-file-input-box-info {\n    position: absolute;\n    bottom: 0;\n    left: 0;\n    right: 0;\n    padding: 2px;\n    z-index: 3;\n    overflow: hidden;\n    text-overflow: ellipsis;\n    background-color: rgba(255, 255, 255, 0.3);\n    pointer-events: none;\n    text-align: center;\n}\n\n.as-file-input-box-file-name {\n    font-size: inherit;\n    color: black;\n    text-shadow: 0 0 5px white;\n    white-space: nowrap;\n}\n\n.as-file-input-box-action-left,\n.as-file-input-box-action-right {\n    position: absolute;\n    z-index: 6;\n    top: 0;\n}\n\n\n.as-file-input-box-action-left {\n    left: 0;\n}\n\n\n.as-file-input-box-action-right {\n    right: 0;\n}\n\n.as-file-input-box button {\n    height: 2em;\n    width: 2em;\n    padding: 0;\n    border: none;\n    background-color: rgba(255, 255, 255, 0.3);\n    border-radius: 0;\n}\n\n.as-file-input-box button span {\n    font-size: 1.5em;\n}\n\n.as-file-input-box .mdi-close {\n    color: rgb(250, 100, 100);\n}\n\n.as-file-input-box .mdi-download {\n    color: rgb(100, 100, 250);\n}\n\n.as-file-input-box button:hover .mdi-close {\n    color: rgb(250, 50, 50);\n}\n\n.as-file-input-box button:hover .mdi-download {\n    color: rgb(50, 50, 250);\n}\n\n.as-file-input-box button:active .mdi-close {\n    color: rgb(250, 0, 0);\n}\n\n.as-file-input-box button:active .mdi-download {\n    color: rgb(0, 0, 250);\n}\n\n", ""]);



/***/ }),
/* 296 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(297);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 297 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-countdown-text {\n\n}\n", ""]);



/***/ }),
/* 298 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(299);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 299 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-message-dialog {\n    font-size: 14px;\n    font-family: \"Helvetica Neue\", Arial, Helvetica, sans-serif;\n    box-sizing: border-box;\n    background-color: white;\n    border-radius: 0.3em;\n    border: 1px solid #dddddd;\n    -webkit-box-shadow: 2px 2px 6px 0px rgba(0, 0, 90, 0.55);\n    -moz-box-shadow: 2px 2px 6px 0px rgba(0, 0, 90, 0.55);\n    box-shadow: 2px 2px 6px 0px rgba(0, 0, 90, 0.55);\n}\n\n.as-message-dialog-header {\n    padding: 5px 1em;\n    border-bottom: 1px solid #e9ecef;\n}\n\n.as-message-dialog-title {\n    font-size: 1.25em;\n    font-weight: 500;\n}\n\n.as-message-dialog-body {\n    padding: 1em;\n}\n\n.as-message-dialog-footer {\n    text-align: right;\n    padding: 5px 20px;\n    border-top: 1px solid #e9ecef;\n}\n\n.as-message-dialog-footer button {\n    height: 30px;\n    margin-left: 20px;\n}\n\n\n.as-message-dialog-footer button.as-flexicon-button .as-flexicon-button-text-container {\n    padding-left: 2em;\n    padding-right: 2em;\n}", ""]);



/***/ }),
/* 300 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-select-tree-leaf-item:not(.as-is-leaf) > .absol-exp-node > .absol-exp-node-name,\n.as-select-tree-leaf-item:not(.as-is-leaf) > .absol-exp-node > .absol-exp-node-ext-icon {\n    color: #888;\n}\n\n.as-select-tree-leaf-item:not(.as-is-leaf) > .absol-exp-node > .absol-exp-node-desc {\n    color: rgb(169, 169, 172)\n}\n\n.as-select-tree-leaf-item > .absol-exp-node:hover,\n.as-select-tree-leaf-item > .absol-exp-node:focus,\n.as-select-tree-leaf-item > .absol-exp-node:active {\n    background-color: transparent;\n}\n\n.as-select-tree-leaf-item.as-is-leaf > .absol-exp-node:hover {\n    background-color: #efefef;\n}\n\n.as-select-tree-leaf-item.as-selected>.absol-exp-node{\n    background-color: #dfdfdf;\n}\n", ""]);



/***/ }),
/* 301 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(302);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 302 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, "\n.as-file-list-input {\n    padding: 5px;\n    border: 1px solid #dddddd;\n    box-sizing: border-box;\n    overflow: auto;\n    --item-width: 100%;\n    --item-require-width: 300px;\n    position: relative;\n    min-height: 42px;\n}\n\n.as-file-list-input-upload-overlay {\n    position: absolute;\n    left: 0;\n    right: 0;\n    top: 0;\n    bottom: 0;\n    overflow: hidden;\n    text-align: center;\n    white-space: nowrap;\n    pointer-events: none;\n    background-color: rgba(30, 30, 80, 0.3);\n    color: #b0fffb;\n}\n\n.as-file-list-input-upload-overlay::before {\n    display: inline-block;\n    vertical-align: middle;\n    height: 100%;\n    content: \"\";\n}\n\n.as-file-list-input-upload-overlay > span {\n    font-size: 30px;\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.as-file-list-input:not(.as-drag-over) .as-file-list-input-upload-overlay,\n.as-file-list-input:not(.as-droppable) .as-file-list-input-upload-overlay,\n.as-file-list-input:not(.as-droppable) .as-file-list-drag-file-text,\n.as-file-list-input.as-read-only .as-file-list-input-upload-overlay {\n    display: none;\n}\n\n/*span.mdi.mdi-upload*/\n\n.as-file-list-input .as-file-input-box {\n    display: inline-block;\n    vertical-align: middle;\n    margin-right: 10px;\n}\n\n.as-file-list-input.as-read-only .as-file-list-input-add {\n    display: none;\n}\n\n.as-file-list-input-add {\n    border: none;\n    width: 50px;\n    border-radius: 5px;\n    background-color: rgba(235, 235, 235, 0.2);\n    height: 30px;\n    padding-bottom: 10px;\n    box-sizing: border-box;\n    display: inline-block;\n    overflow: hidden;\n    position: relative;\n    vertical-align: middle;\n    margin-right: 5px;\n}\n\n\n.as-file-list-input-add:hover {\n    background-color: rgb(235, 235, 235);\n}\n\n.as-file-list-input-add:active {\n    background-color: rgb(212, 212, 212);\n}\n\n\n.as-file-list-input-add input {\n    opacity: 0;\n    visibility: hidden;\n}\n\n.as-file-list-input-add-icon-ctn {\n    font-size: 1.5em;\n    text-align: center;\n    color: rgb(100, 100, 250);\n    position: absolute;\n    top: 0;\n    bottom: 0;\n    left: 0;\n    right: 0;\n    white-space: nowrap;\n    pointer-events: none;\n}\n\n.as-file-list-input-add-icon-ctn span {\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.as-file-list-input-add-icon-ctn::before {\n    content: \"\";\n    display: inline-block;\n    vertical-align: middle;\n    height: 100%;\n}\n\n.as-file-list-input.as-drag-over.as-droppable .as-file-list-input-add,\n.as-file-list-input.as-drag-over .as-file-list-drag-file-text {\n    visibility: hidden;\n}\n\n.as-file-list-item {\n    position: relative;\n    height: 30px;\n    font-size: 14px;\n    font-family: Arial, Helvetica, sans-serif;\n    width: calc(var(--item-width) - 5px);\n    padding-left: 32px;\n    white-space: nowrap;\n    box-sizing: border-box;\n    user-select: none;\n    -webkit-user-select: none;\n    -moz-user-select: none;\n}\n\n.as-file-list-item-icon {\n    position: absolute;\n    left: 0;\n    top: calc(50% - 15px);\n    bottom: 0;\n    width: 30px;\n    height: 30px;\n}\n\n\n.as-file-list-item-name {\n    color: rgb(89, 89, 95);\n    display: inline-block;\n    overflow-x: hidden;\n    vertical-align: middle;\n    width: 100%;\n    text-overflow: ellipsis;\n    white-space: nowrap;\n    font-weight: bold;\n}\n\n\n.as-file-list-item::before {\n    content: \"\";\n    display: inline-block;\n    height: 100%;\n    vertical-align: middle;\n}\n\n\n.as-file-list-input .as-file-list-item {\n    display: inline-block;\n    vertical-align: middle;\n    margin-bottom: 5px;\n    margin-right: 5px;\n}\n\n.as-file-list-input:not(.as-empty) .as-file-list-drag-file-text,\n.as-file-list-input.as-read-only .as-file-list-drag-file-text {\n    display: none;\n}\n\n\n.as-file-list-item:hover {\n    background-color: rgba(169, 169, 172, 0.1);\n}\n\n\n.as-file-list-item.as-active {\n    background-color: rgba(20, 185, 235, 0.3);\n}\n\n\n", ""]);



/***/ }),
/* 303 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(304);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 304 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-date-in-year-follower {\n    z-index: 900000000;\n}\n\n.as-date-in-year-picker {\n    font-size: 14px;\n    font-family: \"Helvetica Neue\", Arial, Helvetica, sans-serif;\n    width: 276px;\n    box-sizing: border-box;\n    border: 1px solid #dddddd;\n    display: inline-block;\n    padding: 10px 5px;\n    box-shadow: 1px 1px 2px rgb(240, 240, 240);\n    background-color: white;\n}\n\n\n.as-date-in-year-picker-table {\n    display: table;\n}\n\n.as-date-in-year-picker-row {\n    display: table-row;\n}\n\n\n.as-date-in-year-picker-row:first-child {\n    text-align: center;\n    line-height: 1.5;\n}\n\n.as-date-in-year-picker-cell {\n    display: table-cell;\n}\n\n\n.as-date-in-year-picker-cell:first-child {\n    padding-right: 10px;\n}\n\n\n.as-date-in-year-picker-month-col {\n    position: relative;\n    padding-top: 25px;\n    padding-bottom: 25px;\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.as-date-in-year-picker-month-viewport {\n    width: 50px;\n    overflow: hidden;\n\n}\n\n.as-date-in-year-picker-month-scroller {\n    width: 70px;\n    height: 112px;\n    overflow-y: scroll;\n    box-sizing: border-box;\n}\n\n\nbutton.as-date-in-year-picker-month {\n    font-size: inherit;\n    height: 28px;\n    width: 50px;\n    padding: 0;\n    border: none;\n    background-color: transparent;\n}\n\nbutton.as-date-in-year-picker-month:hover {\n    background-color: rgb(224, 245, 256);\n}\n\nbutton.as-date-in-year-picker-month.as-selected {\n    background-color: rgb(188, 205, 236);\n    border-radius: 3px;\n}\n\nbutton.as-date-in-year-picker-month > span {\n    font-size: 16px;\n}\n\n\n.as-chrome-time-picker-scroller-up:hover,\n.as-chrome-time-picker-scroller-down:hover {\n    background-color: rgba(169, 169, 169, 0.2);\n}\n\n\n.as-date-in-year-picker-month-btn {\n    position: absolute;\n    left: 0;\n    font-size: inherit;\n    height: 20px;\n    width: 50px;\n    padding: 0;\n    border: none;\n    background-color: transparent;\n    box-sizing: border-box;\n    border-radius: 3px;\n}\n\n.as-date-in-year-picker-month-btn.as-up {\n    top: 0;\n}\n\n.as-date-in-year-picker-month-btn.as-down {\n    bottom: 0;\n}\n\n\n.as-date-in-year-picker-month-btn:hover {\n    background-color: rgba(169, 169, 169, 0.2);\n}\n\n.as-date-in-year-picker-month-btn > span {\n    font-size: 1.5em;\n    user-select: none;\n    -moz-user-select: none;\n    -webkit-user-select: none;\n}\n\n\n.as-date-in-year-picker-days {\n    display: inline-table;\n    vertical-align: middle;\n    border: solid 1px rgb(190, 190, 190);\n}\n\n.as-date-in-year-picker-week {\n    display: table-row;\n}\n\n.as-date-in-year-picker-day {\n    display: table-cell;\n    text-align: right;\n    padding: 5px;\n    line-height: 20px;\n    font-size: inherit;\n    user-select: none;\n    -moz-user-select: none;\n    -webkit-user-select: none;\n}\n\n\n.as-date-in-year-picker-day:hover {\n    background-color: rgb(224, 245, 256);\n    cursor: default;\n}\n\n.as-date-in-year-picker-day.as-selected {\n    background-color: rgb(188, 205, 236);\n}\n\n\n.as-date-time-input.as-date-in-year-input {\n    width: calc(6em + 30px);\n}\n\n.as-date-in-year-input.as-must-not-null .as-time-input-clear-btn,\n.as-date-in-year-input.as-empty .as-time-input-clear-btn {\n    display: none;\n}\n\n\n.as-date-in-year-follower {\n    z-index: 1000000;\n}", ""]);



/***/ }),
/* 305 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(306);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 306 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-dual-select-box {\n    -webkit-box-shadow: 2px 2px 6px 0px rgba(0, 0, 90, 0.55);\n    -moz-box-shadow: 2px 2px 6px 0px rgba(0, 0, 90, 0.55);\n    box-shadow: 2px 2px 6px 0px rgba(0, 0, 90, 0.55);\n    --max-height: 70vh;\n    box-sizing: border-box;\n    --dual-list-estimate-width: 0;\n    width: var(--dual-list-estimate-width);\n    z-index: 10000000;\n    background-color: white;\n\n}\n\n.as-dual-select-box-search-ctn {\n    padding: 5px;\n    position: absolute;\n    left: 0;\n    right: 0;\n}\n\n.as-dual-select-box.as-enable-search.as-anchor-6 .as-dual-select-box-search-ctn,\n.as-dual-select-box.as-enable-search.as-anchor-5 .as-dual-select-box-search-ctn {\n    bottom: 0;\n}\n\n.as-dual-select-box.as-enable-search.as-anchor-6,\n.as-dual-select-box.as-enable-search.as-anchor-5 {\n    padding-bottom: 38px;\n}\n\n.as-dual-select-box.as-enable-search.as-anchor-1,\n.as-dual-select-box.as-enable-search.as-anchor-2 {\n    padding-top: 38px;\n}\n\n.as-dual-select-box.as-enable-search.as-anchor-1 .as-dual-select-box-search-ctn,\n.as-dual-select-box.as-enable-search.as-anchor-2 .as-dual-select-box-search-ctn {\n    top: 0;\n}\n\n\n.as-dual-select-box-list-ctn {\n    white-space: nowrap;\n    display: flex;\n    align-items: stretch;\n}\n\n.as-dual-select-box:not(.as-enable-search) .as-dual-select-box-search-ctn {\n    display: none;\n}\n\n.as-dual-select-box-list {\n    display: inline-block;\n    vertical-align: top;\n    max-height: calc(var(--max-height));\n    overflow-y: auto;\n    box-sizing: border-box;\n}\n\n.as-dual-select-box.as-enable-search .as-dual-select-box-list {\n    max-height: calc(var(--max-height) - 38px);\n}\n\n.as-dual-select-box-arrow-ctn {\n    display: inline-block;\n    vertical-align: top;\n}\n\n.as-dual-select-box-arrow-ctn::before,\n.as-dual-select-box-arrow-ctn span {\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.as-dual-select-box-arrow-ctn::before {\n    content: \"\";\n    height: 100%;\n}\n\n\n.as-dual-select-box-list:first-child {\n    border-right: solid 1px #dddddd;\n}\n\n\n.as-dual-select-box-list:last-child {\n    border-left: solid 1px #dddddd;\n    flex-grow: 1;\n}\n\n.as-dual-select-menu.absol-selectmenu {\n    min-width: calc(var(--dual-list-estimate-text-width) + 10px + 30px);\n    --dual-list-estimate-text-width: 20px;\n}", ""]);



/***/ }),
/* 307 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(308);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 308 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-toc-list {\n\n}\n\n.as-toc-list.as-searching .as-toc-list-body,\n.as-toc-list:not(.as-searching) .as-toc-list-searching {\n    display: none;\n}\n\n.as-toc-item {\n    font-size: 14px;\n    font-family: Arial, Helvetica, sans-serif;\n    display: flex;\n    height: 30px;\n    align-items: stretch;\n    --level: 0;\n}\n\n.as-toc-item:not(.as-status-close) .as-toc-item-toggle-ico-ctn .toggle-close,\n.as-toc-item:not(.as-status-open) .as-toc-item-toggle-ico-ctn .toggle-open {\n    display: none;\n}\n\n.as-toc-item.as-active {\n    background-color: var(--as-transparent-button-active-color);\n}\n\n\n.as-toc-item:hover {\n    background-color: var(--as-transparent-button-hover-color);\n}\n\n.as-toc-item > div {\n    white-space: nowrap;\n    width: 30px;\n}\n\n.as-toc-item > div::before,\n.as-toc-item > div > * {\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.as-toc-item > div::before {\n    content: \"\";\n    height: 100%;\n}\n\n.as-toc-item-name-ctn {\n    flex-grow: 1;\n\n}\n\n.as-toc-item-name {\n    user-select: none;\n    max-width: 100%;\n    overflow: hidden;\n    text-overflow: ellipsis;\n}\n\ndiv.as-toc-item-toggle-ico-ctn {\n    padding-left: calc(30px * var(--level));\n    box-sizing: content-box !important;\n}\n\n.as-toc-item-toggle-ico-ctn .toggler-ico {\n    width: 0.7em;\n    height: 0.7em;\n}\n\n.as-toc-item-toggle-ico-ctn .toggler-ico path {\n    fill: rgb(104, 104, 104);\n}\n\n.as-toc-item-ext-icon-ctn:empty {\n    display: none;\n}\n\n.as-toc-item-ext-icon-ctn > img,\n.as-toc-item-ext-icon-ctn > svg {\n    width: 20px;\n    height: 20px;\n}\n\n.as-toc-item-ext-icon-ctn > span {\n    font-size: 20px;\n}\n\n\n.as-toc-item-toggle-ico-ctn,\n.as-toc-item-check-ctn,\n.as-toc-item-quick-menu-ctn,\n.as-toc-item-ext-icon-ctn {\n    text-align: center;\n    width: 30px;\n}\n\n.as-toc-item-quick-menu-ctn span {\n    font-size: 20px;\n}\n\n.as-toc-item-quick-menu-ctn button {\n    border: none;\n    background-color: transparent;\n    padding: 0;\n    width: 24px;\n    height: 24px;\n}\n\n.as-toc-item-quick-menu-ctn button.as-quick-menu-attached {\n    background-color: var(--as-transparent-button-active-color);\n}\n\n.as-toc-item-quick-menu-ctn button:hover {\n    background-color: var(--icon-background-cover-hover);\n}\n\n.as-toc-item-name-ctn input {\n    font: inherit;\n    border: none;\n    /*background-color: transparent;*/\n    width: 8px;\n    padding-left: 2px;\n    padding-right: 2px;\n    margin-left: -2px;\n    margin-right: -2px;\n    outline: none;\n    box-sizing: content-box;\n    background-color: #5bc0de;\n    max-width: 100%;\n}\n\n.as-toc-item:not(.as-renaming) .as-toc-item-name-ctn input,\n.as-toc-item.as-renaming .as-toc-item-name {\n    display: none;\n}\n\n", ""]);



/***/ }),
/* 309 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(310);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 310 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, "\nspan.cke_button_icon.cke_button__as-variable-box-ico_icon {\n    background-size: cover;\n    background-image: url(\"data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgIi0vL1czQy8vRFREIFNWRyAxLjEvL0VOIiAiaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEuZHRkIj4KPHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB2ZXJzaW9uPSIxLjEiICB2aWV3Qm94PSIwIDAgMjQgMjQiPgogICAgPHBhdGggZmlsbD0iIzAwMDBmZiIgZD0iTTE5IDNINUMzLjkgMyAzIDMuOSAzIDVWMTlDMyAyMC4xIDMuOSAyMSA1IDIxSDE5QzIwLjEgMjEgMjEgMjAuMSAyMSAxOVY1QzIxIDMuOSAyMC4xIDMgMTkgM003LjQgMThDNS45IDE2LjUgNSAxNC4zIDUgMTJTNS45IDcuNSA3LjQgNkw5IDYuN0M3LjcgNy45IDcgOS45IDcgMTJTNy43IDE2LjEgOSAxNy4zTDcuNCAxOE0xMi43IDE1TDExLjkgMTNMMTAuNSAxNUg5TDExLjMgMTEuOUwxMCA5SDExLjNMMTIuMSAxMUwxMy41IDlIMTVMMTIuOCAxMkwxNC4xIDE1SDEyLjdNMTYuNiAxOEwxNSAxNy4zQzE2LjMgMTYgMTcgMTQuMSAxNyAxMlMxNi4zIDcuOSAxNSA2LjdMMTYuNiA2QzE4LjEgNy41IDE5IDkuNyAxOSAxMlMxOC4xIDE2LjUgMTYuNiAxOFoiIC8+Cjwvc3ZnPg==\");\n}\n\nspan.cke_button_icon.cke_button__as-expression-box-ico_icon {\n    background-size: cover;\n    background-image: url(\"data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPCFET0NUWVBFIHN2ZyBQVUJMSUMgIi0vL1czQy8vRFREIFNWRyAxLjEvL0VOIiAiaHR0cDovL3d3dy53My5vcmcvR3JhcGhpY3MvU1ZHLzEuMS9EVEQvc3ZnMTEuZHRkIj4KPHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB2ZXJzaW9uPSIxLjEiICB3aWR0aD0iMjQiIGhlaWdodD0iMjQiIHZpZXdCb3g9IjAgMCAyNCAyNCI+CiAgIDxwYXRoIGZpbGw9IiMwMDAwMDAiIGQ9Ik01LDNIN1Y1SDVWMTBBMiwyIDAgMCwxIDMsMTJBMiwyIDAgMCwxIDUsMTRWMTlIN1YyMUg1QzMuOTMsMjAuNzMgMywyMC4xIDMsMTlWMTVBMiwyIDAgMCwwIDEsMTNIMFYxMUgxQTIsMiAwIDAsMCAzLDlWNUEyLDIgMCAwLDEgNSwzTTE5LDNBMiwyIDAgMCwxIDIxLDVWOUEyLDIgMCAwLDAgMjMsMTFIMjRWMTNIMjNBMiwyIDAgMCwwIDIxLDE1VjE5QTIsMiAwIDAsMSAxOSwyMUgxN1YxOUgxOVYxNEEyLDIgMCAwLDEgMjEsMTJBMiwyIDAgMCwxIDE5LDEwVjVIMTdWM0gxOU0xMiwxNUExLDEgMCAwLDEgMTMsMTZBMSwxIDAgMCwxIDEyLDE3QTEsMSAwIDAsMSAxMSwxNkExLDEgMCAwLDEgMTIsMTVNOCwxNUExLDEgMCAwLDEgOSwxNkExLDEgMCAwLDEgOCwxN0ExLDEgMCAwLDEgNywxNkExLDEgMCAwLDEgOCwxNU0xNiwxNUExLDEgMCAwLDEgMTcsMTZBMSwxIDAgMCwxIDE2LDE3QTEsMSAwIDAsMSAxNSwxNkExLDEgMCAwLDEgMTYsMTVaIiAvPgo8L3N2Zz4=\");\n}\n\n\ndiv.as-ck-inline-short-text {\n    border: 1px solid #dddddd;\n    height: 30px;\n    line-height: 28px;\n    font-size: 14px;\n    font-family: Arial, Helvetica, sans-serif;\n    padding-left: var(--as-input-horizontal-padding);\n    padding-right: var(--as-input-horizontal-padding);\n    outline: none;\n    overflow: hidden;\n    white-space: nowrap;\n}\n\n.as-ck-inline-short-text p {\n    padding: 0;\n    margin: 0;\n}\n\n.as-ck-inline-short-text p::after {\n    content: \"\";\n}\n\n.as-ck-inline-short-text .cke_reset.cke_widget_drag_handler_container {\n    visibility: hidden;\n    opacity: 0;\n    display: none;\n}\n\n.cke.cke_browser_webkit {\n    z-index: 2000000 !important;\n}\n\n.cke.cke_browser_webkit.as-hidden {\n    opacity: 0;\n    visibility: hidden;\n    pointer-events: none;\n}", ""]);



/***/ }),
/* 311 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(312);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 312 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ":root {\n    --as-vertical-timeline-item-height: 65px;\n}\n\n.as-vertical-timeline {\n    display: inline-block;\n    color: white;\n    font-size: 14px;\n    font-family: Arial, Helvetica, sans-serif;\n    text-align: left;\n    padding: 5px;\n}\n\n.as-vertical-timeline-item {\n    height: var(--as-vertical-timeline-item-height);\n    white-space: nowrap;\n}\n\n.as-vertical-timeline-item.as-inactive {\n    color: rgba(200, 200, 200, 0.5);\n}\n\n.as-vertical-timeline-item.as-active .as-vertical-timeline-tile {\n    text-shadow: 1px 0 0 currentColor;\n}\n\n.as-vertical-timeline-item:not(:first-child) .as-vertical-timeline-icon-ctn::before {\n    content: \"\";\n    display: inline-block;\n    height: calc(var(--as-vertical-timeline-item-height) - 40px);\n    border-left: 2px solid currentColor;\n    position: absolute;\n    left: calc(50% - 1px);\n    bottom: calc(100% + 8px);\n}\n\n\n.as-vertical-timeline-icon-ctn {\n    display: inline-block;\n    margin-right: 20px;\n    position: relative;\n    vertical-align: middle;\n\n}\n\n.as-vertical-timeline-icon-ctn span {\n    font-size: 24px;\n}\n\n\n.as-vertical-timeline-tile {\n    display: inline-block;\n    vertical-align: middle;\n\n}\n\n\n/*//check-circle*/", ""]);



/***/ }),
/* 313 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(314);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 314 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, "\n.atr-click-icon-arrow {\n    fill: #04c7ff;\n    stroke: black;\n    stroke-width: 5;\n\n}\n\n.atr-click-icon-arrow {\n    animation:atr-click-arrow-anim 2s linear infinite;\n}\n\n.atr-click-icon-effect {\n    animation: atr-click-effect-anim 2s linear infinite;\n}\n\n@keyframes atr-click-effect-anim {\n    0%{\n        opacity: 0;\n    }\n    90%{\n        opacity: 0;\n    }\n    95%{\n        opacity: 1;\n    }\n    99%{\n        opacity: 1;\n    }\n    100%{\n        opacity: 0;\n    }\n}\n\n@keyframes atr-click-arrow-anim {\n    0%{\n        fill: #04c7ff;\n    }\n    90%{\n        fill: #04c7ff;\n    }\n    95%{\n        fill: #b6dbff;\n    }\n    99%{\n        fill: #b6dbff;\n    }\n    100%{\n        fill: #04c7ff;\n    }\n}", ""]);



/***/ }),
/* 315 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(316);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 316 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".atr-scroll-bar-icon {\n\n}\n\n.atr-scroll-bar-icon-bar,\n.atr-scroll-bar-icon-btn-down,\n.atr-scroll-bar-icon-btn-up {\n    animation-duration: 5s;\n    animation-iteration-count: infinite;\n}\n\n.atr-scroll-bar-icon.atr-down .atr-scroll-bar-icon-bar {\n    animation-name: atr-scroll-bar-icon-bar-down-anim;\n}\n\n.atr-scroll-bar-icon.atr-up .atr-scroll-bar-icon-bar {\n    animation-name: atr-scroll-bar-icon-bar-up-anim;\n}\n\n\n.atr-scroll-bar-icon.atr-down .atr-scroll-bar-icon-btn-down,\n.atr-scroll-bar-icon.atr-up .atr-scroll-bar-icon-btn-up {\n    animation-name: atr-scroll-bar-icon-btn-anim;\n}\n\n\n@keyframes atr-scroll-bar-icon-bar-down-anim {\n    0%, 10% {\n        transform: translateY(0px);\n    }\n    30%, 100% {\n        transform: translateY(100px);\n    }\n}\n\n@keyframes atr-scroll-bar-icon-bar-up-anim {\n    0%, 10% {\n        transform: translateY(30px);\n    }\n    30%, 100% {\n        transform: translateY(-70px);\n    }\n}\n\n@keyframes atr-scroll-bar-icon-btn-anim {\n    10%, 29% {\n        fill: red;\n    }\n    30%, 100% {\n        fill: black;\n    }\n}\n", ""]);



/***/ }),
/* 317 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(318);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 318 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".atr-blink-mask {\n    position: fixed;\n    background: #ffe807;\n    z-index: 1099999999;\n    pointer-events: none;\n    opacity: 0;\n    -webkit-box-shadow: 0px 0px 0px 2px rgba(255, 10, 10, 1);\n    -moz-box-shadow: 0px 0px 0px 2px rgba(255, 10, 10, 1);\n    box-shadow: 0px 0px 0px 2px rgba(255, 10, 10, 1);\n}\n\n.atr-blink-mask.as-anim {\n    animation-name: blink;\n    animation-duration: 1.6s;\n    animation-iteration-count: infinite;\n    /*animation-timing-function: linear;*/\n}\n\n\n.atr-blink-mask.as-transparent {\n    animation-name: none;\n    opacity: 0;\n}\n\n@keyframes blink {\n    0% {\n        opacity: 0;\n    }\n    12% {\n        opacity: 0.5;\n    }\n    25% {\n        opacity: 0;\n    }\n    37% {\n        opacity: 0.5;\n    }\n\n    50% {\n        opacity: 0;\n    }\n\n    100% {\n        opacity: 0;\n    }\n}", ""]);



/***/ }),
/* 319 */
/***/ (function(module, exports, __webpack_require__) {

/* WEBPACK VAR INJECTION */(function(global) {var scope = (typeof global !== "undefined" && global) ||
            (typeof self !== "undefined" && self) ||
            window;
var apply = Function.prototype.apply;

// DOM APIs, for completeness

exports.setTimeout = function() {
  return new Timeout(apply.call(setTimeout, scope, arguments), clearTimeout);
};
exports.setInterval = function() {
  return new Timeout(apply.call(setInterval, scope, arguments), clearInterval);
};
exports.clearTimeout =
exports.clearInterval = function(timeout) {
  if (timeout) {
    timeout.close();
  }
};

function Timeout(id, clearFn) {
  this._id = id;
  this._clearFn = clearFn;
}
Timeout.prototype.unref = Timeout.prototype.ref = function() {};
Timeout.prototype.close = function() {
  this._clearFn.call(scope, this._id);
};

// Does not start the time, just sets up the members needed.
exports.enroll = function(item, msecs) {
  clearTimeout(item._idleTimeoutId);
  item._idleTimeout = msecs;
};

exports.unenroll = function(item) {
  clearTimeout(item._idleTimeoutId);
  item._idleTimeout = -1;
};

exports._unrefActive = exports.active = function(item) {
  clearTimeout(item._idleTimeoutId);

  var msecs = item._idleTimeout;
  if (msecs >= 0) {
    item._idleTimeoutId = setTimeout(function onTimeout() {
      if (item._onTimeout)
        item._onTimeout();
    }, msecs);
  }
};

// setimmediate attaches itself to the global object
__webpack_require__(320);
// On some exotic environments, it's not clear which object `setimmediate` was
// able to install onto.  Search each possibility in the same order as the
// `setimmediate` library.
exports.setImmediate = (typeof self !== "undefined" && self.setImmediate) ||
                       (typeof global !== "undefined" && global.setImmediate) ||
                       (this && this.setImmediate);
exports.clearImmediate = (typeof self !== "undefined" && self.clearImmediate) ||
                         (typeof global !== "undefined" && global.clearImmediate) ||
                         (this && this.clearImmediate);

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(44)))

/***/ }),
/* 320 */
/***/ (function(module, exports, __webpack_require__) {

/* WEBPACK VAR INJECTION */(function(global, process) {(function (global, undefined) {
    "use strict";

    if (global.setImmediate) {
        return;
    }

    var nextHandle = 1; // Spec says greater than zero
    var tasksByHandle = {};
    var currentlyRunningATask = false;
    var doc = global.document;
    var registerImmediate;

    function setImmediate(callback) {
      // Callback can either be a function or a string
      if (typeof callback !== "function") {
        callback = new Function("" + callback);
      }
      // Copy function arguments
      var args = new Array(arguments.length - 1);
      for (var i = 0; i < args.length; i++) {
          args[i] = arguments[i + 1];
      }
      // Store and register the task
      var task = { callback: callback, args: args };
      tasksByHandle[nextHandle] = task;
      registerImmediate(nextHandle);
      return nextHandle++;
    }

    function clearImmediate(handle) {
        delete tasksByHandle[handle];
    }

    function run(task) {
        var callback = task.callback;
        var args = task.args;
        switch (args.length) {
        case 0:
            callback();
            break;
        case 1:
            callback(args[0]);
            break;
        case 2:
            callback(args[0], args[1]);
            break;
        case 3:
            callback(args[0], args[1], args[2]);
            break;
        default:
            callback.apply(undefined, args);
            break;
        }
    }

    function runIfPresent(handle) {
        // From the spec: "Wait until any invocations of this algorithm started before this one have completed."
        // So if we're currently running a task, we'll need to delay this invocation.
        if (currentlyRunningATask) {
            // Delay by doing a setTimeout. setImmediate was tried instead, but in Firefox 7 it generated a
            // "too much recursion" error.
            setTimeout(runIfPresent, 0, handle);
        } else {
            var task = tasksByHandle[handle];
            if (task) {
                currentlyRunningATask = true;
                try {
                    run(task);
                } finally {
                    clearImmediate(handle);
                    currentlyRunningATask = false;
                }
            }
        }
    }

    function installNextTickImplementation() {
        registerImmediate = function(handle) {
            process.nextTick(function () { runIfPresent(handle); });
        };
    }

    function canUsePostMessage() {
        // The test against `importScripts` prevents this implementation from being installed inside a web worker,
        // where `global.postMessage` means something completely different and can't be used for this purpose.
        if (global.postMessage && !global.importScripts) {
            var postMessageIsAsynchronous = true;
            var oldOnMessage = global.onmessage;
            global.onmessage = function() {
                postMessageIsAsynchronous = false;
            };
            global.postMessage("", "*");
            global.onmessage = oldOnMessage;
            return postMessageIsAsynchronous;
        }
    }

    function installPostMessageImplementation() {
        // Installs an event handler on `global` for the `message` event: see
        // * https://developer.mozilla.org/en/DOM/window.postMessage
        // * http://www.whatwg.org/specs/web-apps/current-work/multipage/comms.html#crossDocumentMessages

        var messagePrefix = "setImmediate$" + Math.random() + "$";
        var onGlobalMessage = function(event) {
            if (event.source === global &&
                typeof event.data === "string" &&
                event.data.indexOf(messagePrefix) === 0) {
                runIfPresent(+event.data.slice(messagePrefix.length));
            }
        };

        if (global.addEventListener) {
            global.addEventListener("message", onGlobalMessage, false);
        } else {
            global.attachEvent("onmessage", onGlobalMessage);
        }

        registerImmediate = function(handle) {
            global.postMessage(messagePrefix + handle, "*");
        };
    }

    function installMessageChannelImplementation() {
        var channel = new MessageChannel();
        channel.port1.onmessage = function(event) {
            var handle = event.data;
            runIfPresent(handle);
        };

        registerImmediate = function(handle) {
            channel.port2.postMessage(handle);
        };
    }

    function installReadyStateChangeImplementation() {
        var html = doc.documentElement;
        registerImmediate = function(handle) {
            // Create a <script> element; its readystatechange event will be fired asynchronously once it is inserted
            // into the document. Do so, thus queuing up the task. Remember to clean up once it's been called.
            var script = doc.createElement("script");
            script.onreadystatechange = function () {
                runIfPresent(handle);
                script.onreadystatechange = null;
                html.removeChild(script);
                script = null;
            };
            html.appendChild(script);
        };
    }

    function installSetTimeoutImplementation() {
        registerImmediate = function(handle) {
            setTimeout(runIfPresent, 0, handle);
        };
    }

    // If supported, we should attach to the prototype of global, since that is where setTimeout et al. live.
    var attachTo = Object.getPrototypeOf && Object.getPrototypeOf(global);
    attachTo = attachTo && attachTo.setTimeout ? attachTo : global;

    // Don't get fooled by e.g. browserify environments.
    if ({}.toString.call(global.process) === "[object process]") {
        // For Node.js before 0.9
        installNextTickImplementation();

    } else if (canUsePostMessage()) {
        // For non-IE10 modern browsers
        installPostMessageImplementation();

    } else if (global.MessageChannel) {
        // For web workers, where supported
        installMessageChannelImplementation();

    } else if (doc && "onreadystatechange" in doc.createElement("script")) {
        // For IE 6–8
        installReadyStateChangeImplementation();

    } else {
        // For older browsers
        installSetTimeoutImplementation();
    }

    attachTo.setImmediate = setImmediate;
    attachTo.clearImmediate = clearImmediate;
}(typeof self === "undefined" ? typeof global === "undefined" ? this : global : self));

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(44), __webpack_require__(99)))

/***/ }),
/* 321 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


exports.byteLength = byteLength
exports.toByteArray = toByteArray
exports.fromByteArray = fromByteArray

var lookup = []
var revLookup = []
var Arr = typeof Uint8Array !== 'undefined' ? Uint8Array : Array

var code = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'
for (var i = 0, len = code.length; i < len; ++i) {
  lookup[i] = code[i]
  revLookup[code.charCodeAt(i)] = i
}

// Support decoding URL-safe base64 strings, as Node.js does.
// See: https://en.wikipedia.org/wiki/Base64#URL_applications
revLookup['-'.charCodeAt(0)] = 62
revLookup['_'.charCodeAt(0)] = 63

function getLens (b64) {
  var len = b64.length

  if (len % 4 > 0) {
    throw new Error('Invalid string. Length must be a multiple of 4')
  }

  // Trim off extra bytes after placeholder bytes are found
  // See: https://github.com/beatgammit/base64-js/issues/42
  var validLen = b64.indexOf('=')
  if (validLen === -1) validLen = len

  var placeHoldersLen = validLen === len
    ? 0
    : 4 - (validLen % 4)

  return [validLen, placeHoldersLen]
}

// base64 is 4/3 + up to two characters of the original data
function byteLength (b64) {
  var lens = getLens(b64)
  var validLen = lens[0]
  var placeHoldersLen = lens[1]
  return ((validLen + placeHoldersLen) * 3 / 4) - placeHoldersLen
}

function _byteLength (b64, validLen, placeHoldersLen) {
  return ((validLen + placeHoldersLen) * 3 / 4) - placeHoldersLen
}

function toByteArray (b64) {
  var tmp
  var lens = getLens(b64)
  var validLen = lens[0]
  var placeHoldersLen = lens[1]

  var arr = new Arr(_byteLength(b64, validLen, placeHoldersLen))

  var curByte = 0

  // if there are placeholders, only get up to the last complete 4 chars
  var len = placeHoldersLen > 0
    ? validLen - 4
    : validLen

  var i
  for (i = 0; i < len; i += 4) {
    tmp =
      (revLookup[b64.charCodeAt(i)] << 18) |
      (revLookup[b64.charCodeAt(i + 1)] << 12) |
      (revLookup[b64.charCodeAt(i + 2)] << 6) |
      revLookup[b64.charCodeAt(i + 3)]
    arr[curByte++] = (tmp >> 16) & 0xFF
    arr[curByte++] = (tmp >> 8) & 0xFF
    arr[curByte++] = tmp & 0xFF
  }

  if (placeHoldersLen === 2) {
    tmp =
      (revLookup[b64.charCodeAt(i)] << 2) |
      (revLookup[b64.charCodeAt(i + 1)] >> 4)
    arr[curByte++] = tmp & 0xFF
  }

  if (placeHoldersLen === 1) {
    tmp =
      (revLookup[b64.charCodeAt(i)] << 10) |
      (revLookup[b64.charCodeAt(i + 1)] << 4) |
      (revLookup[b64.charCodeAt(i + 2)] >> 2)
    arr[curByte++] = (tmp >> 8) & 0xFF
    arr[curByte++] = tmp & 0xFF
  }

  return arr
}

function tripletToBase64 (num) {
  return lookup[num >> 18 & 0x3F] +
    lookup[num >> 12 & 0x3F] +
    lookup[num >> 6 & 0x3F] +
    lookup[num & 0x3F]
}

function encodeChunk (uint8, start, end) {
  var tmp
  var output = []
  for (var i = start; i < end; i += 3) {
    tmp =
      ((uint8[i] << 16) & 0xFF0000) +
      ((uint8[i + 1] << 8) & 0xFF00) +
      (uint8[i + 2] & 0xFF)
    output.push(tripletToBase64(tmp))
  }
  return output.join('')
}

function fromByteArray (uint8) {
  var tmp
  var len = uint8.length
  var extraBytes = len % 3 // if we have 1 byte left, pad 2 bytes
  var parts = []
  var maxChunkLength = 16383 // must be multiple of 3

  // go through the array every three bytes, we'll deal with trailing stuff later
  for (var i = 0, len2 = len - extraBytes; i < len2; i += maxChunkLength) {
    parts.push(encodeChunk(uint8, i, (i + maxChunkLength) > len2 ? len2 : (i + maxChunkLength)))
  }

  // pad the end with zeros, but make sure to not forget the extra bytes
  if (extraBytes === 1) {
    tmp = uint8[len - 1]
    parts.push(
      lookup[tmp >> 2] +
      lookup[(tmp << 4) & 0x3F] +
      '=='
    )
  } else if (extraBytes === 2) {
    tmp = (uint8[len - 2] << 8) + uint8[len - 1]
    parts.push(
      lookup[tmp >> 10] +
      lookup[(tmp >> 4) & 0x3F] +
      lookup[(tmp << 2) & 0x3F] +
      '='
    )
  }

  return parts.join('')
}


/***/ }),
/* 322 */
/***/ (function(module, exports) {

/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
exports.read = function (buffer, offset, isLE, mLen, nBytes) {
  var e, m
  var eLen = (nBytes * 8) - mLen - 1
  var eMax = (1 << eLen) - 1
  var eBias = eMax >> 1
  var nBits = -7
  var i = isLE ? (nBytes - 1) : 0
  var d = isLE ? -1 : 1
  var s = buffer[offset + i]

  i += d

  e = s & ((1 << (-nBits)) - 1)
  s >>= (-nBits)
  nBits += eLen
  for (; nBits > 0; e = (e * 256) + buffer[offset + i], i += d, nBits -= 8) {}

  m = e & ((1 << (-nBits)) - 1)
  e >>= (-nBits)
  nBits += mLen
  for (; nBits > 0; m = (m * 256) + buffer[offset + i], i += d, nBits -= 8) {}

  if (e === 0) {
    e = 1 - eBias
  } else if (e === eMax) {
    return m ? NaN : ((s ? -1 : 1) * Infinity)
  } else {
    m = m + Math.pow(2, mLen)
    e = e - eBias
  }
  return (s ? -1 : 1) * m * Math.pow(2, e - mLen)
}

exports.write = function (buffer, value, offset, isLE, mLen, nBytes) {
  var e, m, c
  var eLen = (nBytes * 8) - mLen - 1
  var eMax = (1 << eLen) - 1
  var eBias = eMax >> 1
  var rt = (mLen === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0)
  var i = isLE ? 0 : (nBytes - 1)
  var d = isLE ? 1 : -1
  var s = value < 0 || (value === 0 && 1 / value < 0) ? 1 : 0

  value = Math.abs(value)

  if (isNaN(value) || value === Infinity) {
    m = isNaN(value) ? 1 : 0
    e = eMax
  } else {
    e = Math.floor(Math.log(value) / Math.LN2)
    if (value * (c = Math.pow(2, -e)) < 1) {
      e--
      c *= 2
    }
    if (e + eBias >= 1) {
      value += rt / c
    } else {
      value += rt * Math.pow(2, 1 - eBias)
    }
    if (value * c >= 2) {
      e++
      c /= 2
    }

    if (e + eBias >= eMax) {
      m = 0
      e = eMax
    } else if (e + eBias >= 1) {
      m = ((value * c) - 1) * Math.pow(2, mLen)
      e = e + eBias
    } else {
      m = value * Math.pow(2, eBias - 1) * Math.pow(2, mLen)
      e = 0
    }
  }

  for (; mLen >= 8; buffer[offset + i] = m & 0xff, i += d, m /= 256, mLen -= 8) {}

  e = (e << mLen) | m
  eLen += mLen
  for (; eLen > 0; buffer[offset + i] = e & 0xff, i += d, e /= 256, eLen -= 8) {}

  buffer[offset + i - d] |= s * 128
}


/***/ }),
/* 323 */
/***/ (function(module, exports) {

var toString = {}.toString;

module.exports = Array.isArray || function (arr) {
  return toString.call(arr) == '[object Array]';
};


/***/ }),
/* 324 */
/***/ (function(module, exports) {

module.exports = function(module) {
	if (!module.webpackPolyfill) {
		module.deprecate = function() {};
		module.paths = [];
		// module.parent = undefined by default
		if (!module.children) module.children = [];
		Object.defineProperty(module, "loaded", {
			enumerable: true,
			get: function() {
				return module.l;
			}
		});
		Object.defineProperty(module, "id", {
			enumerable: true,
			get: function() {
				return module.i;
			}
		});
		module.webpackPolyfill = 1;
	}
	return module;
};


/***/ }),
/* 325 */
/***/ (function(module, exports) {

/* WEBPACK VAR INJECTION */(function(__webpack_amd_options__) {/* globals __webpack_amd_options__ */
module.exports = __webpack_amd_options__;

/* WEBPACK VAR INJECTION */}.call(this, {}))

/***/ }),
/* 326 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(327);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 327 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".absol-debug-task {\n    position: fixed;\n    right: 10px;\n    bottom: 10px;\n    z-index: 999999;\n    border-radius: 4px;\n    background: rgba(169, 169, 171, 0.3);\n    border: solid 1px rgba(21, 21, 214, 0.5);\n    min-width: 45px;\n    min-height: 30px;\n    font-size: 12px;\n    padding: 5px;\n    pointer-events: none;\n}\n\n.absol-debug-task-name{\n    color: darkcyan;\n}\n\n.absol-debug-task-value{\n    color: rgb(159, 8, 197);\n}", ""]);



/***/ }),
/* 328 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(329);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 329 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".kv-document-2-site {\n    display: flex;\n    align-content: stretch;\n}\n\n.kv-document-2-site-left {\n\n    background-color: rgb(61, 29, 154);\n}\n\n.kv-document-2-site-right {\n    flex-grow: 1;\n\n}\n\n.kv-document-2-site-left-header {\n    font-family: \"Helvetica Neue\", Arial, Helvetica, sans-serif;\n    padding: 25px 20px;\n\n}\n\n.kv-document-2-site-left-header-logo {\n    height: 65px;\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.kv-document-2-site-left-header-text {\n    font-weight: bold;\n    font-size: 30px;\n    display: inline-block;\n    vertical-align: middle;\n    color: #26afa8;\n}\n\n.kv-document-2-site-left .as-vertical-timeline {\n    padding: 5px 20px;\n}\n\n\n/* For Document page */\n.kv-document-page {\n    flex-direction: column;\n    display: flex;\n}\n\n.kv-document-page-header {\n    position: relative;\n    text-align: left;\n    padding: 10px 10px 10px 10px;\n}\n\n.kv-document-page-title {\n    font-size: 18px;\n    font-weight: bold;\n    line-height: 30px;\n}\n\n.kv-document-page-close-btn {\n    float: right;\n}\n\n.kv-document-transparent-btn {\n    background-color: transparent;\n    border-radius: 50%;\n    height: 30px;\n    width: 30px;\n    padding: 0;\n    color: var(--as-transparent-button-text-color);\n    font-size: 20px;\n    border: none;\n}\n\n.kv-document-transparent-btn:hover {\n    color: var(--as-transparent-button-text-hover-color);\n}\n\n.kv-document-transparent-btn:active {\n    color: var(--as-transparent-button-text-active-color);\n}\n\n\n.kv-document-page-content {\n    flex-grow: 1;\n    overflow: auto;\n    padding: 10px 20px 10px 20px;\n}\n\n.kv-document-page-footer {\n    position: relative;\n    padding: 30px 20px 10px 0;\n\n}\n\n.kv-document-page-footer .kv-document-link:last-child {\n    float: right;\n}\n\n.kv-document-link {\n    font-family: Arial, Helvetica, sans-serif;\n    font-size: 14px;\n    font-weight: bold;\n    color: rgb(120, 120, 120);\n    cursor: pointer;\n    height: 30px;\n    padding: 0 20px;\n    white-space: normal;\n    border-radius: 3px;\n}\n\n.kv-document-link > span,\n.kv-document-link::before {\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.kv-document-link::before {\n    content: \"\";\n    height: 100%;\n}\n\n\n.kv-document-link.kv-variant-primary {\n    color: white;\n    background-color: rgb(26, 146, 255);\n}", ""]);



/***/ }),
/* 330 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(331);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 331 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".kv-overview-widget {\n    background-color: rgb(212, 227, 252);\n    padding: 0 5px 0 5px;\n    border-radius: 3px;\n    box-sizing: border-box;\n    display: inline-block;\n    width: 350px;\n    height: 550px;\n    font-family: Arial, Helvetica, sans-serif;\n    font-size: 14px;\n    position: fixed;\n    --x: 0;\n    --y: 0;\n    left: var(--x);\n    top: var(--y);\n    z-index: 3000000;\n}\n\n.kv-overview-widget-header {\n    height: 30px;\n    padding-left: 10px;\n    user-select: none;\n    position: relative;\n}\n\n.kv-overview-widget-header-window-action {\n    position: absolute;\n    right: 5px;\n    top: calc(50% - 10px);\n    height: 20px;\n    display: inline-block;\n}\n\n.kv-overview-widget-header-window-action button {\n    background-color: transparent;\n    border-radius: 3px;\n    padding: 0;\n    border: none;\n    width: 20px;\n    height: 20px;\n    color: rgb(69, 69, 70);\n}\n\n.kv-overview-widget-header-window-action button:hover {\n    background-color: var(--as-transparent-button-hover-color);\n}\n\n.kv-overview-widget-header-window-action button:hover {\n    background-color: var(--as-transparent-button-active-color);\n}\n\n.kv-overview-widget-title {\n    font-weight: bold;\n    display: inline-block;\n    line-height: 30px;\n}\n\n.kv-overview-widget-body {\n    box-sizing: border-box;\n    padding-top: 5px;\n    background-color: white;\n    height: calc(100% - 35px);\n}\n\n.kv-overview-widget-body > .absol-tabview > .absol-tabbar .absol-hscroller-viewport {\n    width: 100%;\n    height: 100%;\n}\n\n.kv-overview-widget-body > .absol-tabview > .absol-tabbar .absol-hscroller-viewport {\n    padding-left: 5px;\n    box-sizing: border-box;\n}\n\n.kv-overview-widget-body > .absol-tabview > .absol-tabbar .as-tab-bar-button-ext-icon-ctn {\n    margin: 0;\n}\n\n.kv-overview-widget-page > div {\n    width: 100%;\n    height: 100%;\n}\n\n.kv-overview-widget-tab-view .absol-tabbar-button > .absol-tabbar-button-icon-container {\n    display: none;\n}\n\n.kv-overview-widget-tab-view .absol-tabbar-button {\n    min-width: 70px;\n    text-align: left;\n}\n\n.kv-overview-widget-tab-view {\n    width: 100%;\n    height: 100%;\n}\n\n.kv-overview-widget-bubble {\n    position: fixed;\n    z-index: 3000000;\n    width: 54px;\n    height: 54px;\n    border-radius: 50%;\n    background-color: white;\n    box-shadow: 2px 2px 10px 0px rgba(0, 0, 0, 0.75);\n    -webkit-box-shadow: 2px 2px 10px 0px rgba(0, 0, 0, 0.75);\n    -moz-box-shadow: 2px 2px 10px 0px rgba(0, 0, 0, 0.75);\n    user-select: none;\n}\n\n.kv-overview-widget-bubble:hover {\n    background-color: rgb(240, 240, 250);\n\n}\n\n.kv-overview-widget-bubble:active {\n    box-shadow: 2px 2px 5px 0px rgba(0, 0, 0, 0.75);\n    -webkit-box-shadow: 2px 2px 5px 0px rgba(0, 0, 0, 0.75);\n    -moz-box-shadow: 2px 2px 5px 0px rgba(0, 0, 0, 0.75);\n}\n\n.kv-overview-widget-bubble-background {\n    position: absolute;\n    left: 20%;\n    top: 20%;\n    width: 60%;\n    height: 60%;\n    pointer-events: none;\n}\n\n.kv-overview-widget-bubble-badge {\n    position: absolute;\n    left: calc(85% - 10px);\n    bottom: calc(85% - 10px);\n    text-align: center;\n    padding:0 3px ;\n    background-color: rgba(255,  0, 0, 0.7);\n    color: white;\n    font-family: Arial, Helvetica, sans-serif;\n    font-size: 14px;\n    height: 30px;\n    min-width: 30px;\n    white-space: nowrap;\n    border-radius: 15px;\n    box-sizing: border-box;\n\n}\n\n.kv-overview-widget-bubble-badge span,\n.kv-overview-widget-bubble-badge::before {\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.kv-overview-widget-bubble-badge::before{\n    content:\"\" ;\n    height: 100%;\n}", ""]);



/***/ }),
/* 332 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global) {/* harmony import */ var ___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(81);


global.AbsolBrace = ___WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"];
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(44)))

/***/ }),
/* 333 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(334);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 334 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".ace_editor  ::-webkit-scrollbar {\n    width: 17px;\n}   \n\n/* Track */\n.ace_editor  ::-webkit-scrollbar-track {\n    background: rgba(169, 169, 169, 0.1);\n}\n\n/* Handle */\n.ace_editor  ::-webkit-scrollbar-thumb {\n    background: rgba(169, 169, 169, 0.3);\n}\n\n/* Handle on hover */\n.ace_editor  ::-webkit-scrollbar-thumb:hover {\n    background: rgba(85, 85, 85, 0.445);\n}\n\n\n.ace_editor div {\n    scrollbar-color:  rgba(169, 169, 169, 0.3) rgba(169, 169, 169, 0.1);\n}\n\n", ""]);



/***/ }),
/* 335 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(336);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 336 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".brace-diff {\n    position: relative;\n}\n\n\n.brace-diff-left-container {\n    position: absolute;\n    left: 0;\n    width: calc(50% - 3.5em);\n    top: 0;\n    bottom: 0;\n    background: gray;\n}\n\n\n.brace-diff-right-container {\n    right: 0;\n    position: absolute;\n    width: calc(50% - 3.5em);\n    top: 0;\n    bottom: 0;\n    background: gray;\n    \n}\n\n.brace-diff-middle-tool-container{\n    position: absolute;\n    left:calc(50% - 3.5em - 19px) ;\n    right: calc(50% - 3.5em - 19px);\n    top: 0;\n    bottom: 0;\n    z-index: 9;\n    pointer-events: none;\n}\n\n.brace-diff-middle-tool{\n    position: relative;\n    width: 100%;\n    height: 100%;\n    overflow: hidden;\n}\n\n.brace-diff-left-container>pre,\n.brace-diff-right-container>pre {\n    width: 100%;\n    height: 100%;\n    margin: 0;\n}\n\n.brace-diff-foreground {\n    position: absolute;\n    left: 0;\n    right: 0;\n    top: 0;\n    bottom: 0;\n    z-index: 7;\n    pointer-events: none;\n}\n\n.brace-diff-foreground>svg {\n    /*todo*/\n    margin: 0;\n    pointer-events: none;\n}\n\npath.brace-diff-gap{\n    fill:rgba(9, 205, 231, 0.1);\n    stroke:rgba(8, 73, 82, 0.5);\n    stroke-width: 1;\n}\n\nbutton.brace-diff-arrow{\n    height: 14px;\n    width: 19px; \n    padding: 0;\n    position: absolute;\n    outline: none;\n    border: solid 1px rgba(169, 169, 169,1); \n    background-color: white;\n    pointer-events: all;\n    \n}\n\nbutton.brace-diff-arrow.pick-left{\n    left: 0;\n}\n\nbutton.brace-diff-arrow.pick-left >svg{\n    fill:rgb(226, 35, 35);\n}\n\nbutton.brace-diff-arrow.pick-right >svg{\n    fill:rgb(35, 134, 226);\n}\n\nbutton.brace-diff-arrow.pick-right{\n    right: 0;\n}\n\nbutton.brace-diff-arrow> svg{\n    height:  12px;\n    width: 12px;\n}", ""]);



/***/ }),
/* 337 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(338);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 338 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".atr-explain-modal .atr-punctured-modal {\n    backdrop-filter: blur(0.04em);\n    -webkit-backdrop-filter: blur(0.04em);\n    background-color: rgba(169, 169, 169, 0.40);\n}\n\n.atr-explain-text {\n    color: white;\n    font-size: 1.25em;\n    margin: 0;\n}\n\n.atr-explain-text p{\n    font-size: inherit;\n    margin: 0;\n}", ""]);



/***/ }),
/* 339 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".atr-transparent-modal {\n    position: fixed;\n    left: 0;\n    right: 0;\n    top: 0;\n    bottom: 0;\n    z-index: 99999999;\n}\n\n.atr-on-top {\n    z-index: 1000000001 !important;\n}\n\n.atr-on-top-1 {\n    z-index: 1000000001 !important;\n}\n\n.atr-transparent-modal.as-hidden {\n    visibility: hidden;\n}\n\n.atr-toast-message .toast-body {\n    padding-left: 0.75em;\n    padding-right: 0.75em;\n}\n\n.atr-tab-button-disabled-close .absol-tabbar-button-icon-container {\n    pointer-events: none !important;\n}\n\n.atr-tab-button-disabled-close .absol-tabbar-button-close {\n    color: #dddddd !important;\n}\n\n.atr-scroll-icon-ctn {\n    position: fixed;\n    left: 50px;\n    top: 50px;\n    background-color: #ffea17;\n    pointer-events: none;\n    opacity: 0.7;\n}\n\n.atr-scroll-icon-ctn > svg {\n    width: 17px;\n    height: auto;\n    z-index: 1000000005;\n    display: block;\n}\n\n.atr-scroll-only * {\n    pointer-events: none;\n\n}\n\n.atr-scroll-tooltip {\n    position: fixed;\n    z-index: 1000000009;\n}\n\n.atr-scroll-tooltip {\n    animation: scroll-move 1s linear infinite alternate;\n}\n\n\n@keyframes scroll-move {\n    0% {\n        transform: translateY(0);\n\n    }\n    100% {\n        transform: translateY(40px);\n    }\n}\n\n.atr-confirm-toast-footer {\n    padding: 5px;\n    text-align: center;\n}\n\n.atr-confirm-toast-footer button{\n    height: 30px;\n}\n\n.as-toast pre{\n    padding: initial;\n    margin: initial;\n    overflow: initial;\n    background-color: transparent;\n    border: none;\n}", ""]);



/***/ }),
/* 340 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(341);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 341 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".atr-split-editor {\n    width: 100%;\n    height: 100%;\n}\n\n.atr-split-editor-ace {\n    margin: 0;\n    width: 100%;\n    height: 100%;\n    /*height: calc(100% - 25px);*/\n}\n\n.atr-split-editor .as-form-cmd-tool {\n    border-bottom: 1px solid #ddd;\n    box-sizing: border-box;\n}\n\n.attr-split-editor-window .absol-onscreen-window-head-bar-button-minimize,\n.attr-split-editor-window .absol-onscreen-window-head-bar-button-dock {\n    display: none;\n}\n\n.attr-split-editor-window {\n    z-index: 1000000000;\n}\n\n", ""]);



/***/ }),
/* 342 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(343);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 343 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-form-cmd-tool-window .absol-onscreen-window-body-container {\n    overflow-y: auto;\n}\n\n.as-from-tool-button {\n    font-size: 12px;\n    height: 2em;\n    width: 2em;\n    background-color: transparent;\n    padding: 0;\n    vertical-align: middle;\n    border: none;\n    border-radius: 0.3em;\n    outline: none;\n}\n\n.as-from-tool-button:not(:disabled):hover {\n    background-color: rgba(169, 169, 169, 0.1);\n}\n\n.as-from-tool-button:not(:disabled):active {\n    background-color: rgba(169, 169, 169, 0.2);\n}\n\n.as-from-tool-button > span {\n    font-size: 1.5em;\n}\n\n.as-from-tool-button > svg {\n    width: 1.5em;\n    height: 1.5em;\n}\n\n.as-from-tool-button:not(:disabled) > span.mdi-delete-variant {\n    color: red;\n}\n\n.as-from-tool-button:disabled > span {\n    color: #c4c4c4;\n}\n\n.as-from-tool-button:disabled > svg > path {\n    fill: #c4c4c4;\n}\n\n.as-from-tool-group-buttons {\n    margin-right: 2px;\n\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.as-from-tool-group-buttons .as-from-tool-group-buttons:not(:last-child) {\n    border-right: 0.5px solid #ddd;\n}\n\n.as-from-tool-group-buttons .as-from-tool-group-buttons:not(:first-child) {\n    border-left: 0.5px solid #ddd;\n}\n\n.absol-tooltip-root {\n    z-index: 100;\n}\n\n.as-from-tool-group-buttons:empty {\n    display: none;\n}\n\n\n.as-form-cmd-tool-menu-trigger {\n    position: absolute;\n    right: 0;\n    top: 0;\n    bottom: 0;\n    color: #ddd;\n}\n\n.as-form-cmd-tool-window .absol-onscreen-window-head-bar-button-dock {\n    display: none;\n}\n\n\n.as-form-cmd-tool-window .as-form-cmd-tool-menu-trigger {\n    display: none;\n}", ""]);



/***/ }),
/* 344 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(345);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 345 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".ace_doc-tooltip .ace_storage,\n.ace_doc-tooltip .ace_keyword {\n    color: blue;\n}\n\n.atr-ace-tooltip-desc {\n    margin: 0;\n    max-width: 500px;\n    white-space: pre-wrap;\n}\n\n.atr-ace-tooltip-define {\n    max-width: 500px;\n    white-space: pre-wrap;\n}", ""]);



/***/ }),
/* 346 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(347);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 347 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ":root {\n    --tutor-master-x: 0.2;\n    --tutor-master-y: 0.2;\n    --tutor-master-width: 120px;\n    --tutor-master-height: 40px;\n}\n\n.atr-tutor-master {\n    position: fixed;\n    z-index: 1000000000;\n    left: calc((100vw - var(--tutor-master-width) - 4px) * var(--tutor-master-x) + 2px);\n    top: calc((100vh - var(--tutor-master-height) - 4px) * var(--tutor-master-y) + 2px);\n    background-color: white;\n    padding-left: 40px;\n    height: 40px;\n    border-radius: 5px;\n    box-shadow: 1px 1px 3px 1px rgba(0, 0, 0, 0.3);\n    box-sizing: border-box;\n    min-width: 120px;\n    white-space: nowrap;\n    overflow: hidden;\n    user-select: none;\n    -moz-user-select: none;\n    -webkit-user-select: none;\n}\n\n.atr-tutor-master-head {\n    position: absolute;\n    left: 0;\n    top: 0;\n    bottom: 0;\n    width: 40px;\n    text-align: center;\n    border-right: 1px solid #ddd;\n    box-sizing: border-box;\n    background-color: rgba(169, 169, 169, 0.15);\n}\n\n.atr-tutor-master-head > svg {\n    width: 30px;\n    height: 30px;\n    display: inline-block;\n    vertical-align: middle;\n}\n\n.atr-tutor-master-head > svg path {\n    fill: #04c7ff;\n}\n\n.atr-tutor-master-cmd-ctn {\n    height: 40px;\n    width: 40px;\n}\n\n\n.atr-tutor-master-head::before {\n    content: \"\";\n    display: inline-block;\n    vertical-align: middle;\n    height: 100%;\n}\n\n.atr-tutor-master .as-from-tool-button {\n    width: 40px;\n    height: 40px;\n    font-size: 20px;\n    border-radius: 0;\n}\n\n.atr-tutor-master .as-from-tool-button.as-active {\n    color: #4f72f5;\n}\n\n.atr-has-tutor-master .as-toast-list.as-se,\n.atr-has-tutor-master .as-toast-list.as-sw {\n    bottom: 50px;\n}\n\n.atr-has-tutor-master .ace_tooltip,\n.atr-has-tutor-master .ace_editor.ace_autocomplete {\n    z-index: 1100000000;\n}", ""]);



/***/ }),
/* 348 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(349);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 349 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".atr-flag-manager .as-property-editor {\n    overflow: auto;\n    box-sizing: border-box;\n    width: 100%;\n    height: 100%;\n    text-align: center;\n}\n\ninput.atr-flag-name {\n    outline: none;\n    border: 1px solid #dddddd;\n    height: 30px;\n    box-sizing: border-box;\n    width: 220px;\n}", ""]);



/***/ }),
/* 350 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(351);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 351 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".as-property-editor{\n    padding:0.357em;\n}\n\n\n.as-property-editor>table {\n    border-collapse: collapse;\n    box-sizing: border-box;\n}\n\n.as-property-editor>table>thead{\n    font-style: italic;\n    background: #f5f5f5;\n}\n\n.as-property-editor>table>tbody>tr>td,\n.as-property-editor>table>thead>tr>td {\n    border: 1px solid #aaaaaa;\n    padding: 0.25em;\n\n}\n\n.as-form-property-tab>.as-property-editor>table {\n    width: calc(100% - 10px);\n    margin: 5px;\n}\n\n.as-property-editor>table>tbody>tr>td>input[type=\"text\"],\n.as-property-editor>table>tbody>tr>td>textarea {\n    font-size: 1em;\n    width: 100%;\n    box-sizing: border-box;\n    border: solid 1px #d6d6d6;\n    outline: none;\n}\n\n.as-property-editor>table>tbody>tr>td>textarea{\n    width: 100% !important;\n}\n\n\n.as-property-editor-text-align-input{\n    font-size: 1.5em;\n    width: 1.2em;\n    height: 1.2em;\n    padding: 0;\n    margin: 0;\n    box-sizing: content-box;\n    border: solid 1px #ddd;\n    background-color: rgba(169, 169, 172, 0);\n    outline: none;\n}\n", ""]);



/***/ }),
/* 352 */
/***/ (function(module, exports, __webpack_require__) {


var content = __webpack_require__(353);

if(typeof content === 'string') content = [[module.i, content, '']];

var transform;
var insertInto;



var options = {"hmr":true}

options.transform = transform
options.insertInto = undefined;

var update = __webpack_require__(7)(content, options);

if(content.locals) module.exports = content.locals;

if(false) {}

/***/ }),
/* 353 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(6)(false);
// Module
exports.push([module.i, ".atr-inspector-rect {\n    position: fixed;\n    pointer-events: none;\n    border: 1px solid #3a5b48;\n    z-index: 1100000000;\n    box-sizing: border-box;\n    background-color: rgba(0, 150, 150, 0.03);\n    transition: left 0.1s, top 0.1s, width 0.1s, height 0.1s;\n}\n\n.atr-inspector-rect-text {\n    position: absolute;\n    left: -1px;\n    bottom: calc(100% + 1px);\n    padding: 2px;\n    background-color: rgba(25, 80, 25, 0.5);\n    color: yellow;\n    box-sizing: border-box;\n    text-shadow: 0 0 2px rgba(0, 0, 0, 0.5);\n}\n\n\n.atr-inspector-rect.atr-bottom .atr-inspector-rect-text {\n    top: calc(100% + 1px);\n    bottom: unset;\n}\n\n.atr-inspector-rect.atr-left .atr-inspector-rect-text {\n    right: -1px;\n    left: unset;\n}\n\n.atr-inspector-tree-footer {\n    position: absolute;\n    bottom: 0;\n    left: 0;\n    right: 0;\n    height: 16px;\n    line-height: 16px;\n    font-size: 12px;\n    color: #aaa;\n    background-color: #eee;\n}\n\n\n.atr-inspector-tree-ctn {\n    position: absolute;\n    top: 20px;\n    left: 0;\n    right: 0;\n    bottom: 16px;\n    overflow-y: auto;\n    font-size: 12px;\n}\n\n.atr-inspector-tree-ctn .absol-exp-node.as-active{\n    background-color: darkslategray;\n    color: white;\n}\n\n.atr-inspector-tree-ctn .absol-exp-node.as-active .absol-exp-node-name{\n    color: white;\n}", ""]);



/***/ }),
/* 354 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
// ESM COMPAT FLAG
__webpack_require__.r(__webpack_exports__);

// NAMESPACE OBJECT: ./node_modules/absol/src/Converter/base64.js
var base64_namespaceObject = {};
__webpack_require__.r(base64_namespaceObject);
__webpack_require__.d(base64_namespaceObject, "base64EncodeUnicode", function() { return base64EncodeUnicode; });
__webpack_require__.d(base64_namespaceObject, "base64DecodeUnicode", function() { return base64DecodeUnicode; });
__webpack_require__.d(base64_namespaceObject, "UnicodeBase64Converter", function() { return UnicodeBase64Converter; });

// NAMESPACE OBJECT: ./node_modules/absol/src/JSX/dom.js
var dom_namespaceObject = {};
__webpack_require__.r(dom_namespaceObject);
__webpack_require__.d(dom_namespaceObject, "domVisitor", function() { return domVisitor; });
__webpack_require__.d(dom_namespaceObject, "parseDom", function() { return parseDom; });

// NAMESPACE OBJECT: ./node_modules/absol/src/HTML5/Clipboard.js
var Clipboard_namespaceObject = {};
__webpack_require__.r(Clipboard_namespaceObject);
__webpack_require__.d(Clipboard_namespaceObject, "copyImage", function() { return copyImage; });
__webpack_require__.d(Clipboard_namespaceObject, "copyText", function() { return copyText; });
__webpack_require__.d(Clipboard_namespaceObject, "pasteText", function() { return pasteText; });

// EXTERNAL MODULE: ./css/puncturedmodal.css
var puncturedmodal = __webpack_require__(112);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/AElement.js
var AElement = __webpack_require__(8);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/Dom.js + 1 modules
var Dom = __webpack_require__(1);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/dom/install.js + 114 modules
var install = __webpack_require__(64);

// CONCATENATED MODULE: ./js/dom/Core.js


var Core = new Dom["b" /* default */]({});
Object(install["a" /* default */])(Core);
var Core_ = Core._;
var $ = Core.$;
var $$ = Core.$$;
/* harmony default export */ var dom_Core = (Core);
// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/ResizeSystem.js
var ResizeSystem = __webpack_require__(11);

// EXTERNAL MODULE: ./css/clickico.css
var clickico = __webpack_require__(313);

// EXTERNAL MODULE: ./css/scrollbarico.css
var scrollbarico = __webpack_require__(315);

// CONCATENATED MODULE: ./asset/icon/click.tpl
/* harmony default export */ var click = ("<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" version=\"1.1\" id=\"Capa_1\" x=\"0px\"\n     y=\"0px\" viewBox=\"0 0 512 512\" xml:space=\"preserve\" width=\"512\"\n     height=\"512\" class=\"atr-click-icon\">\n\t\t<path class=\"atr-click-icon-arrow\"\n              d=\"M422.762,507.605l-87.518-87.503l-42.422,42.422c-3.662,3.662-8.979,5.171-14.048,3.999    c-5.068-1.201-9.141-4.922-10.781-9.858l-84.858-254.561c-1.802-5.391-0.396-11.338,3.618-15.352    c3.999-3.999,9.961-5.464,15.352-3.618l254.561,84.858c4.937,1.641,8.657,5.713,9.858,10.781    c1.187,5.054-0.322,10.371-3.999,14.048l-42.422,42.422l87.503,87.517c5.859,5.859,5.859,15.352,0,21.211l-63.633,63.633    C438.113,513.465,428.621,513.465,422.762,507.605z\"/>\n    <g class=\"atr-click-icon-effect\">\n        <path d=\"M195,120c-8.291,0-15-6.709-15-15V15c0-8.291,6.709-15,15-15s15,6.709,15,15v90C210,113.291,203.291,120,195,120z\"/>\n        <path d=\"M120.762,141.973L57.114,78.325c-5.859-5.859-5.859-15.352,0-21.211s15.352-5.859,21.211,0l63.647,63.647    c5.859,5.859,5.859,15.352,0,21.211C136.113,147.832,126.621,147.832,120.762,141.973z\"/>\n        <path d=\"M57.114,332.886c-5.859-5.859-5.859-15.352,0-21.211l63.647-63.647c5.859-5.859,15.352-5.859,21.211,0    s5.859,15.352,0,21.211l-63.647,63.647C72.466,338.745,62.974,338.745,57.114,332.886z\"/>\n        <path d=\"M248.027,141.973c-5.859-5.859-5.859-15.352,0-21.211l63.647-63.647c5.859-5.859,15.352-5.859,21.211,0    s5.859,15.352,0,21.211l-63.647,63.647C263.379,147.832,253.887,147.832,248.027,141.973z\"/>\n        <path d=\"M105,210H15c-8.291,0-15-6.709-15-15s6.709-15,15-15h90c8.291,0,15,6.709,15,15S113.291,210,105,210z\"/>\n    </g>\n\n</svg>\n");
// CONCATENATED MODULE: ./asset/icon/scrollbar.tpl
/* harmony default export */ var scrollbar = ("<svg version=\"1.1\" id=\"Capa_1\" xmlns=\"http://www.w3.org/2000/svg\"\n     width=\"94.305px\" height=\"492.156px\" viewBox=\"198.926 0 94.305 492.156\"\n     xml:space=\"preserve\" class=\"atr-scroll-bar-icon\">\n\t<path class=\"atr-scroll-bar-icon-border\" d=\"M198.926,0v492.156h94.305V0H198.926z M283.64,482.564h-75.126V9.593h75.126V482.564z\"></path>\n\t<path class=\"atr-scroll-bar-icon-btn-up\" d=\"M275.656,17.579H215.73v48.73h59.926 V17.579z M222.034,54.744l23.659-31.54l23.646,31.54H222.034z\"></path>\n\t<path class=\"atr-scroll-bar-icon-btn-down\" d=\"M275.656,426.914H215.73v48.735h59.926V426.914z M245.692,470.038\n\t\tl-23.659-31.551h47.305L245.692,470.038z\"></path>\n\t<path class=\"atr-scroll-bar-icon-bar\" d=\"M268.857,314.251V142.212h-46.341v172.039H268.857z M261.328,247.346h-30.895v-7.99\n\t\th30.895V247.346z M261.328,228.565h-30.895v-7.989h30.895V228.565z M230.048,203.003h30.887v7.992h-30.887V203.003z\"/>\n</svg>");
// CONCATENATED MODULE: ./asset/icon/tutor.tpl
/* harmony default export */ var icon_tutor = ("<svg version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" x=\"0px\" y=\"0px\" viewBox=\"0 0 1000 1000\" enable-background=\"new 0 0 1000 1000\" xml:space=\"preserve\">\n    <path d=\"M471.7,934.1l66.2-34.2L491,682.3l15.3-26.9l-1.2-27.5c-29.2-1.7-37.8-1.7-66.9,0l-1.2,27.5l15.3,26.9l-46.9,217.5L471.7,934.1z\"/><path d=\"M271,403.2c16.8,60.8,40.9,106.4,71.1,139.2c32.9,35.8,72.4,56.1,117.1,64.1l4,0.7l4-0.9c49.5-11.1,89.1-32.4,120.6-67.8c29.2-32.8,51-77.2,67.1-136.4c13.6-8.4,23.8-22.1,30.6-40.2c7.6-19.9,11-45.6,10.6-76l-0.2-12l-9.4-6.7c-1.1-0.9-2.2-1.6-3.4-2.3c12.5-176.8-11-278.7-210.5-250.2C405,24.3,331.4,3.2,289.4,35.8C236.7,88.7,233,168,247.3,261.1c-3.2,1.8-6.3,3.8-9.5,6.2l-9.4,6.7l-0.2,12c-0.5,31,3.2,57.2,11,77.2C246.3,381.5,256.9,395.1,271,403.2z M300.6,307c0.7-2.1,1.3-4.5,2-7.2l0.3,0.1l0.9-5c3.2-13.5,6.8-31.2,10-44.8c1.3-4,2.6-7.9,4.1-11.7c46.4,37.6,129.7,41.8,201-25.3l-12.7,36.8l12.9,2.7l14.6-24.8l-1.8,17.4l13.8,1.9l8.5-28.5c16.9,10.3,35.6,24.1,52.3,16.6c5.5,13.4,9.8,28,12.6,43.7l3.6,20.2l6.3-0.4l2.9,10.5c7.4-1,13.9-1.1,20.2-1.2c-1,14.7-3.3,27.1-7,36.9c-3.9,10-9.1,16.7-15.7,19.1l-10.9,4.1l-3,11.8c-14.3,56.8-33.5,98-59.3,126.8c-24.2,27.2-55,44-93.8,53.4c-34.1-6.9-64.1-22.8-89.1-49.9c-26.8-29.2-48.2-71.6-63-129.7l-3.2-12.4l-11.5-3.8c-6.8-2.2-12.2-8.7-16.1-18.7c-3.9-9.9-6.3-22.5-7.3-37.6C282.9,306.1,294.7,302.9,300.6,307z\"/><path d=\"M825.5,740.9l105.9-266.6l-25.6-11.5l-71.9,181l-24,58.3c-16.9-37.4-37.4-70.1-60.7-93.6l-7.2-7.2l-9.7,0.3l-114,4.1v49.9l105.4-3.8c27.4,31.1,50.5,79.5,66.4,132.4c15.8,52.3,24.3,108.3,23.1,155.6H116.9c1.9-41.3,7-91.3,19.1-140.1c13.4-54.2,35.3-106.9,71.1-143.5l95.6,0.9v-49.9l-104.5-1l-8.8,0l-6.8,6.2c-47.8,44.3-75.8,108.8-92.1,174.7C74.7,851.1,70,916.4,69.1,964.5L68.6,990h24h742.6h21.1l2.3-22.4c5.9-57.9-3.4-131.3-23.8-198.5C831.9,759.6,828.8,750.2,825.5,740.9z\"/>\n</svg>");
// CONCATENATED MODULE: ./js/dom/Icon.js






var ClickIco = Core_(click);
var ScrollBarIco = Core_(scrollbar);
var TutorIco = Core_(icon_tutor);
// CONCATENATED MODULE: ./js/dom/PuncturedModal.js





/***
 * @extends AElement
 * @constructor
 */

function PuncturedModal() {
  this.$target = null;
  this.$trackScrollParents = [];
  this._handlePositionChange = this._handlePositionChange.bind(this);
  this.$attachhook = $('attachhook', this);
  this.$attachhook.requestUpdateSize = this._handlePositionChange;
  this.$a = $('.atr-punctured-modal-a', this);
  this.$b = $('.atr-punctured-modal-b', this);
  this.$c = $('.atr-punctured-modal-c', this);
  this.$d = $('.atr-punctured-modal-d', this);
  this._updateTimeout = -1;
}

PuncturedModal.tag = 'PuncturedModal'.toLowerCase();

PuncturedModal.render = function () {
  return Core_({
    extendEvent: 'positionchange',
    class: ['atr-punctured-modal', 'atr-punctured-modal-root'],
    child: ['.atr-punctured-modal.atr-punctured-modal-a', '.atr-punctured-modal.atr-punctured-modal-b', '.atr-punctured-modal.atr-punctured-modal-d', '.atr-punctured-modal.atr-punctured-modal-c', 'attachhook']
  });
};

PuncturedModal.prototype.follow = function (targetElt) {
  if (this.$trackScrollParents.length > 0) this.stopTrackPosition();
  this.$target = targetElt || null;
  var trackElt = this.$target;
  if (!trackElt) return;

  while (trackElt) {
    if (trackElt.addEventListener) trackElt.addEventListener('scroll', this._handlePositionChange, false);else trackElt.attachEvent('onscroll', this._handlePositionChange, false);
    this.$trackScrollParents.push(trackElt);
    trackElt = trackElt.parentElement;
  }

  if (document.addEventListener) {
    document.addEventListener('scroll', this._handlePositionChange, false);
  } else {
    document.attachEvent('onscroll', this._handlePositionChange, false);
  }

  this.$trackScrollParents.push(document);

  if (this.isDescendantOf(document.body)) {
    this._handlePositionChange();
  } else {
    this.$attachhook.resetState();
  }

  ResizeSystem["a" /* default */].add(this.$attachhook);
};

PuncturedModal.prototype.stopTrackPosition = function () {
  var trackElt;

  for (var i = 0; i < this.$trackScrollParents.length; ++i) {
    trackElt = this.$trackScrollParents[i];
    if (trackElt.removeEventListener) trackElt.removeEventListener('scroll', this._handlePositionChange, false);else trackElt.dettachEvent && trackElt.dettachEvent('onscroll', this._handlePositionChange, false);
  }

  this.$trackScrollParents = [];
};

PuncturedModal.prototype._handlePositionChange = function (event) {
  if (!this.$target) return;
  var thisM = this;
  if (this._updateTimeout > 0) clearTimeout(this._updateTimeout);
  var bound = undefined;

  function update() {
    thisM._updateTimeout = -1;
    if (!thisM.$target) return;
    var bound1 = thisM.$target.getBoundingClientRect();

    if (!bound || bound1.left !== bound.left || bound1.width !== bound.width || bound1.top !== bound.top || bound1.height !== bound.height) {
      thisM.addStyle({
        '--punctured-x': bound1.left + 'px',
        '--punctured-y': bound1.top + 'px',
        '--punctured-width': bound1.width + 'px',
        '--punctured-height': bound1.height + 'px'
      });
      thisM.emit('positionchange', {
        target: this,
        bound: bound
      }, this);
      bound = bound1;
      thisM._updateTimeout = setTimeout(update, 10);
    }
  }

  update();
};

PuncturedModal.prototype.reset = function () {
  this.removeStyle({
    '--punctured-x': null,
    '--punctured-y': null,
    '--punctured-width': null,
    '--punctured-height': null
  });
};

dom_Core.install(PuncturedModal);
/* harmony default export */ var dom_PuncturedModal = (PuncturedModal);
// EXTERNAL MODULE: ./css/blinkmask.css
var blinkmask = __webpack_require__(317);

// CONCATENATED MODULE: ./js/dom/BlinkMask.js






/***
 * @extends PuncturedModal
 * @constructor
 */

function BlinkMask() {
  this.$target = null;
  this.$trackScrollParents = [];
  this._handlePositionChange = this._handlePositionChange.bind(this);
  this.$attachhook = $('attachhook', this);
  this.$attachhook.requestUpdateSize = this._handlePositionChange;
  ;
  this._updateTimeout = -1;
}

BlinkMask.tag = 'BlinkMask'.toLowerCase();

BlinkMask.render = function () {
  return Core_({
    extendEvent: 'positionchange',
    class: ['atr-blink-mask', 'as-anim'],
    child: ['attachhook']
  });
};

BlinkMask.prototype.follow = function () {
  var lastTargetElt = this.$target;
  var res = dom_PuncturedModal.prototype.follow.apply(this, arguments);
  var currentTarget = this.$target;

  if (lastTargetElt !== currentTarget && currentTarget) {
    this.removeClass('as-anim');
    setTimeout(function () {
      if (this.$target === currentTarget) {
        this.addClass('as-anim');
      }
    }.bind(this), 0);
  }

  return res;
};

BlinkMask.prototype.stopTrackPosition = dom_PuncturedModal.prototype.stopTrackPosition;

BlinkMask.prototype._handlePositionChange = function (event) {
  if (!this.$target) return;
  var thisM = this;
  if (this._updateTimeout > 0) clearTimeout(this._updateTimeout);
  var bound = undefined;

  function update() {
    thisM._updateTimeout = -1;
    if (!thisM.$target) return;
    var bound1 = thisM.$target.getBoundingClientRect();

    if (!bound || bound1.left !== bound.left || bound1.width !== bound.width || bound1.top !== bound.top || bound1.height !== bound.height) {
      thisM.addStyle({
        left: bound1.left + 'px',
        top: bound1.top + 'px',
        width: bound1.width + 'px',
        height: bound1.height + 'px'
      });
      thisM.emit('positionchange', {
        target: this,
        bound: bound
      }, this);
      bound = bound1;
      thisM._updateTimeout = setTimeout(update, 10);
    }
  }

  update();
};

BlinkMask.prototype.reset = function () {
  this.removeStyle({
    left: null,
    top: null,
    width: null,
    height: null
  });
};

dom_Core.install(BlinkMask);
/* harmony default export */ var dom_BlinkMask = (BlinkMask);
// CONCATENATED MODULE: ./js/dom/install.js


var PublicTutorCreators = [dom_PuncturedModal, dom_BlinkMask];
function install_install(core) {
  core.install(PublicTutorCreators);
}
// EXTERNAL MODULE: ./node_modules/absol/src/Polyfill/polyfill.js
var polyfill = __webpack_require__(100);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/EventEmitter.js
var EventEmitter = __webpack_require__(3);

// EXTERNAL MODULE: ./node_modules/absol/src/Detector/BrowserDetector.js
var BrowserDetector = __webpack_require__(10);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/JSPath.js
var JSPath = __webpack_require__(47);

// EXTERNAL MODULE: ./node_modules/absol/src/JSMaker/TemplateString.js
var TemplateString = __webpack_require__(26);

// CONCATENATED MODULE: ./node_modules/absol/src/XML/XMLConstant.js
var XMLConstant = {
    TYPE_ELEMENT:1,
    TYPE_TEXT:3,
    TYPE_COMMENT:8,
    TYPE_DECLARATION:16
};

/* harmony default export */ var XML_XMLConstant = (XMLConstant);
// CONCATENATED MODULE: ./node_modules/absol/src/XML/XMLDeclarationNode.js


function XMLDeclaretionNode() {
    this.nodeType = XML_XMLConstant.TYPE_DECLARATION;
    this.parentNode;
    /**
     * @type {String}
     */
    this.tagName = '';
    /**
    * @type {XMLElement}
    */
    this.parentNode;
    this.attributes = {};
}

/**
 * @param {String} name attribute name
 */
XMLDeclaretionNode.prototype.getAttribute = function (name) {
    return this.attributes[name];
};

/**
 * @param {String} name attribute name
 * @param {String} value 
 */
XMLDeclaretionNode.prototype.setAttribute = function (name, value) {
    this.attributes[name] = value;
};

/**
 * @param {String} name attribute name
 */
XMLDeclaretionNode.prototype.removeAttribute = function (name) {
    delete this.attributes[name];
};

XMLDeclaretionNode.prototype.remove = function () {
    if (this.parentNode) {
        this.parentNode.removeChild(this);
    }
};


XMLDeclaretionNode.prototype.toObject = function () {
    return { nodeType: this.nodeType, tagName: this.tagName, attributes: Object.assign({}, this.attributes) };
};


/* harmony default export */ var XMLDeclarationNode = (XMLDeclaretionNode);
// CONCATENATED MODULE: ./node_modules/absol/src/XML/XMLClassList.js
/**
 * 
 * @param {XMLElement} xmlNode 
 */
function XMLClassList(xmlNode) {
    this.xmlNode = xmlNode;
}

/**
 * @param {String} name
 * @returns {Boolean}
 */
XMLClassList.prototype.contains = function (name) {
    var className = this.xmlNode.getAttribute('class');
    if (className) {
        var classes = className.trim().split(/\s+/);
        for (var i = 0; i < classes.length; ++i) {
            if (classes[i] == name) return true;
        }
        return false;
    }
    else return false;
};

/**
 * @param {Number} index
 * @returns {String}
 */
XMLClassList.prototype.item = function (index) {
    var className = this.xmlNode.getAttribute('class');
    if (className) {
        var classes = className.trim().split(/\s+/);
        return classes[index];
    }
    else return undefined;
};


/**
 * @param {Array<String>} arguments
 */
XMLClassList.prototype.remove = function () {
    var dict = Array.prototype.reduce.call(arguments, function (ac, name) {
        ac[name] = true;
        return ac;
    }, {});

    var className = this.xmlNode.getAttribute('class');
    if (className) {
        var classes = className.trim().split(/\s+/);
        var newClasses = classes.filter(function (name) {
            dict[name];
        });
        this.xmlNode.setAttribute(newClasses.join(' '));
    }
};

/**
 * @param {Array<String>} arguments
 */
XMLClassList.prototype.add = function () {
    var className = this.xmlNode.getAttribute('class') || '';
    var classes = className.trim().split(/\s+/);
    var dict = classes.reduce(function (ac, name) {
        ac[name] = true;
        return ac;
    }, {});

    for (var i = 0; i < arguments.length; ++i) {
        var newClass = arguments[i].trim();
        if (newClass.length == 0) return;
        if (!dict[newClass]) {
            classes.push(newClass);
            dict[newClass] = true;
        }
    }

    this.xmlNode.setAttribute('class', classes.join(' '));
};


/* harmony default export */ var XML_XMLClassList = (XMLClassList);
// CONCATENATED MODULE: ./node_modules/absol/src/XML/XMLElement.js



function XMLElement() {
    this.nodeType = XML_XMLConstant.TYPE_ELEMENT;

    /**
     * @type {String}
     */
    this.tagName = '';
    /**
     * @type {XMLElement}
     */
    this.parentNode;
    this.attributes = {};
    /**
     * @type {Array} Array of  XMLElement or XMLText
     */
    this.childNodes = [];

    Object.defineProperty(this, 'classList', {
        value: new XML_XMLClassList(this),
        writable: false
    });
}

/**
 * @param {String} name attribute name
 */
XMLElement.prototype.getAttribute = function (name) {
    return this.attributes[name];
};

/**
 * @param {String} name attribute name
 * @param {String} value 
 */
XMLElement.prototype.setAttribute = function (name, value) {
    this.attributes[name] = value;
};

/**
 * @param {String} name attribute name
 */
XMLElement.prototype.removeAttribute = function (name) {
    delete this.attributes[name];
};

XMLElement.prototype.appendChild = function (node) {
    node.remove();
    this.childNodes.push(node);
    node.parentNode = this;
    return node;
};

/**
 * @param {XMLElement} child
 * @returns {XMLElement} removed node
 */
XMLElement.prototype.removeChild = function (child) {
    var result;
    if (this == child.parentNode) {
        var j = 0;
        for (var i = 0; i < this.childNodes.length; ++i) {
            if (child != this.childNodes[i]) {
                this.childNodes[j] = this.childNodes[i];
                ++j;
            }
            else {
                child.parentNode = undefined;
                result = child;
            }
        }
        while (j > this.childNodes.length) {
            this.childNodes.pop();
        }
    }
    return result;
};

/**
 * @param {XMLElement|XMLText|XMLDeclaretionNode} node
 */
XMLElement.prototype.inserBefore = function (node, child) {
    if (node == child) return;
    var childIndex = -1;
    for (var i = 0; i < this.childNodes.length; ++i) {
        if (this.childNodes[i] == child) {
            childIndex = i;
            break;
        }
    }
    if (childIndex < 0) return;
    node.remove();
    node.parentNode = this;
    this.childNodes.push(null);
    var cIndex = this.childNodes.length - 2;
    while (cIndex >= 0) {
        if (this.childNodes[cIndex] == child) {
            this.childNodes[cIndex + 1] = node;
        }
        else
            this.childNodes[cIndex + 1] = this.childNodes[cIndex];
    }
};



XMLElement.prototype.remove = function () {
    if (this.parentNode) {
        this.parentNode.removeChild(this);
    }
};

XMLElement.prototype.toObject = function () {
    return {
        nodeType: this.nodeType, tagName: this.tagName, attributes: Object.assign({}, this.attributes),
        childNodes: this.childNodes.map(function (child) {
            return child.toObject();
        })
    };
};



/* harmony default export */ var XML_XMLElement = (XMLElement);
// CONCATENATED MODULE: ./node_modules/absol/src/XML/XMLTextNode.js


function XMLTextNode(data) {
    this.nodeType = XML_XMLConstant.TYPE_TEXT;
    /**
     * @type {XMLNode}
     */
    this.parentNode;
    /**
     * @type {String}
     */
    this.data = data || '';
}


XMLTextNode.prototype.remove = function () {
    if (this.parentNode) {
        this.parentNode.removeChild(this);
    }
};


XMLTextNode.prototype.toObject = function () {
    return { nodeType: this.nodeType, data: this.data };
};


/* harmony default export */ var XML_XMLTextNode = (XMLTextNode);
// CONCATENATED MODULE: ./node_modules/absol/src/XML/XMLCommentNode.js


function XMLCommentNode(data) {
    this.nodeType = XML_XMLConstant.TYPE_COMMENT;
    /**
     * @type {XMLNode}
     */
    this.parentNode;
    /**
     * @type {String}
     */
    this.data = data || '';
}


XMLCommentNode.prototype.remove = function () {
    if (this.parentNode) {
        this.parentNode.removeChild(this);
    }
};


XMLCommentNode.prototype.toObject = function () {
    return { nodeType: this.nodeType, data: this.data };
};




/* harmony default export */ var XML_XMLCommentNode = (XMLCommentNode);
// CONCATENATED MODULE: ./node_modules/absol/src/XML/XML.js






/**
 * 
 * @param {RegExp} regex 
 */
function getRegexBody(regex) {
    return regex.toString().match(/^\/(.+)\/([gimuy]*)$/)[1];
}

var BEGIN_TAG = 1;
var END_TAG = 2;
var CDATA = 3;
var DECLARATION = 4;
var COMMENT = 5;
var TEXT = 6;



var identRgx = /[^\s\"\r\n\'\!\/=\>\<\]\[\?\+\.]+/;
var spaceRgx = /[\s\r\n]+/;
var stringRgx = /\"(([^\"\\]*|(\\.))*)\"/;
var textRgx = /[^\<\-]+/;
var doctypeOpenRgx = /\<\!DOCTYPE/;
var commentOpenRgx = /\<!\-\-/;
var commentCloseRgx = /\-\-\>/;
var cdataOpenRgx = /\<\!\[CDATA\[/;
var cdataCloseRgx = /\]\]\>/;
var openRgx = /\</;
var openEndTagRgx = /\<\//;
var closeRgx = /\>/;
var shortCloseRgx = /\/\>/;
var declarationOpenRgx = /\<\?/;
var declarationCloseRgx = /\?\>/;
var assignOpRgx = /=/;

var tokenRgxBody = '(' +
    [
        spaceRgx,
        doctypeOpenRgx,
        declarationOpenRgx,
        cdataOpenRgx,
        commentOpenRgx,
        openEndTagRgx,
        openRgx,
        assignOpRgx,
        stringRgx,
        commentCloseRgx,
        identRgx,
        declarationCloseRgx,
        shortCloseRgx,
        closeRgx,
        cdataCloseRgx,
        textRgx
    ].map(function (e) {
        return getRegexBody(e);
    }).join(')|(')
    + ')';

var tokenType = {
    space: spaceRgx,
    doctypeOpen: doctypeOpenRgx,
    declarationOpen: declarationOpenRgx,
    cdataOpen: cdataOpenRgx,
    commentOpen: commentOpenRgx,
    openEndTag: openEndTagRgx,
    open: openRgx,
    ident: identRgx,
    assignOp: assignOpRgx,
    string: stringRgx,
    commentClose: commentCloseRgx,
    declarationClose: declarationCloseRgx,
    shortClose: shortCloseRgx,
    close: closeRgx,
    cdataClose: cdataCloseRgx,
    text: textRgx
}


var tokenRgx = new RegExp(tokenRgxBody);

/**
 * 
 * @typedef {Object} Token
 * @property {String} text
 * @property {*} matched
 */

/**
 * 
 * @param {String} text 
 * @returns {Array<Token>}
 */
function xmlTokenize(text) {
    var texts = text.match(new RegExp(tokenRgxBody, 'g'));
    return text.match(new RegExp(tokenRgxBody, 'g'))
        .map(function (tokenText, i) {
            var result = { text: tokenText, matched: {} };

            for (var tType in tokenType) {
                var matched = tokenText.match(tokenType[tType]);
                if (matched) {
                    if (matched[0] == tokenText) result.matched[tType] = matched;
                }
            }
            return result;
        });
}




/**
 * @typedef {Object} XMLPaseInfo
 * @property {Array<Token>} tokens
 * @property {Number} type
 * @property {Number} start
 * @property {Number} end
 * @property {Error} error
 * @property {Boolean} closed
 * 
 * 
 * 
 * @typedef {Object} XMLParseNode 
 * @property {XMLPaseInfo} __xml__
 * @property {String} tagName
 * @property {*} attributes
 * @property {String} text
 */

/**
 * 
 * @param {Array<Token>} tokens 
 * @param {Number} i 
 * @returns {XMLParseNode}
 */
function matchAssign(tokens, i) {
    var result = { __xml__: { start: i } };
    var cToken;
    if (i < tokens.length) {
        cToken = tokens[i];
        if (cToken.matched['ident']) {
            result.key = cToken.text;
            ++i;
            if (i < tokens.length) {
                cToken = tokens[i];
                if (cToken.matched['space']) {
                    ++i;
                }
                if (i < tokens.length) {
                    cToken = tokens[i];
                    if (cToken.matched['assignOp']) {
                        ++i;
                        if (i < tokens.length) {
                            cToken = tokens[i];
                            if (cToken.matched['space']) {
                                ++i;
                            }
                            if (i < tokens.length) {
                                cToken = tokens[i];
                                if (cToken.matched['string']) {
                                    result.value = cToken.matched.string[1];
                                    ++i;
                                }
                                else {
                                    result.__xml__.error = new Error('"' + cToken.text + '"' + 'found, expected string');
                                }
                            }
                            else {
                                result.__xml__.error = new Error('End of data found, expected ident');
                            }
                        }
                        else {
                            result.__xml__.error = new Error('End of data found, expected ident');
                        }

                    } else {
                        result.__xml__.error = new Error('"' + cToken.text + '"' + 'found, expected =');
                    }
                }
                else {
                    result.__xml__.error = new Error('End of data found, expected =');
                }
            }
            else {
                result.__xml__.error = new Error('End of data found, expected =');
            }
        }
        else {
            result.__xml__.error = new Error('"' + cToken.text + '"' + 'found, expected ident');
        }
    }
    else {
        result.__xml__.error = new Error('End of data found, expected ident');
    }

    result.__xml__.end = i;
    return result;
}



/**
 * 
 * @param {Array<Token>} tokens 
 * @param {Number} i 
 * @returns {XMLParseNode}
 */
function matchBeginTag(tokens, i) {
    var result = { __xml__: { type: BEGIN_TAG, start: i } };
    var cToken;
    if (i < tokens.length) {
        cToken = tokens[i];
        if (cToken.matched['open']) {
            ++i;
            if (i < tokens.length) {
                cToken = tokens[i];
                if (cToken.matched['ident']) {
                    result.tagName = cToken.text;
                    ++i;
                    if (i < tokens.length) {
                        var finished = false;//when find the close symbol
                        while (i < tokens.length) {
                            cToken = tokens[i];
                            if (cToken.matched['space']) {
                                ++i;
                            }//skip space between attributes
                            if (i < tokens.length) {
                                cToken = tokens[i];
                                if (cToken.matched['shortClose']) {
                                    result.__xml__.closed = true;
                                    ++i;
                                    finished = true;
                                    break;
                                }
                                else if (cToken.matched['close']) {
                                    result.__xml__.closed = false;
                                    ++i;
                                    finished = true;
                                    break;
                                }
                                else if (tokens[i - 1].matched['space']) {
                                    var assign = matchAssign(tokens, i);
                                    if (!assign.__xml__.error) {
                                        result.attributes = result.attributes || {};
                                        result.attributes[assign.key] = assign.value;
                                        i = assign.__xml__.end;
                                    }
                                    else if (cToken.matched['ident']) {
                                        result.attributes = result.attributes || {};
                                        result.attributes[cToken.text] = true;// a flag
                                        ++i;
                                    }
                                    else {
                                        //TODO: we can ignore some error here, the same with order Match* function
                                        result.__xml__.error = new Error('"' + cToken.text + '"' + 'found, expected > or indent');
                                        break;
                                    }
                                }
                                else {
                                    //TODO: we can ignore some error here
                                    result.__xml__.error = new Error('"' + cToken.text + '"' + 'found, expected > or indent');
                                    break;
                                }
                            }
                            else {
                                result.__xml__.error = new Error('End of data found, expected /> or >');
                                break;
                            }
                        }
                        if (!finished && !result.__xml__.error) {
                            result.__xml__.error = new Error('End of data found, expected /> or >');
                        }
                    }
                    else {
                        result.__xml__.error = new Error('End of data found, expected /> or >');
                    }
                }
                else {
                    result.__xml__.error = new Error('Expected indent');
                }
            }
            else {
                result.__xml__.error = new Error('End of data found, expected indent');
            }
            result.__xml__.end = i;
        }
        else {
            result.__xml__.error = new Error('"' + cToken.text + '"' + 'found, expected <');
        }
    }
    else {
        result.__xml__.error = new Error('End of data found, expected <');
    }
    result.__xml__.end = i;
    return result;
}


/**
 * 
 * @param {Array<Token>} tokens 
 * @param {Number} i 
 * @returns {XMLParseNode}
 */
function matchEndTag(tokens, i) {
    var result = { __xml__: { type: END_TAG, closed: true, start: i } };
    var cToken;
    if (i < tokens.length) {
        cToken = tokens[i];
        if (cToken.matched['openEndTag']) {
            ++i;
            if (i < tokens.length) {
                cToken = tokens[i];
                if (cToken.matched['ident']) {
                    result.tagName = cToken.text;
                    ++i;
                    if (i < tokens.length) {
                        var finished = false;//when find the close symbol
                        while (i < tokens.length) {
                            cToken = tokens[i];
                            if (cToken.matched['space']) {
                                ++i;
                            }//skip space between attributes
                            if (i < tokens.length) {
                                cToken = tokens[i];
                                if (cToken.matched['close']) {

                                    ++i;
                                    finished = true;
                                    break;
                                }
                                else if (tokens[i - 1].matched['space']) {
                                    var assign = matchAssign(tokens, i);
                                    if (!assign.__xml__.error) {
                                        result.attributes = result.attributes || {};
                                        result.attributes[assign.key] = assign.value;
                                        i = assign.__xml__.end;
                                    }
                                    else if (cToken.matched['ident']) {
                                        result.attributes = result.attributes || {};
                                        result.attributes[cToken.text] = true;// a flag
                                        ++i;
                                    }
                                    else {
                                        result.__xml__.error = new Error('"' + cToken.text + '"' + 'found, expected > or indent');

                                    }
                                }
                                else {
                                    result.__xml__.error = new Error('"' + cToken.text + '"' + 'found, expected > or indent');
                                }
                            }
                            else {
                                result.__xml__.error = new Error('End of data found, expected /> or >');
                            }
                        }
                        if (!finished && !result.__xml__.error) {
                            result.__xml__.error = new Error('End of data found, expected /> or >');
                        }
                    }
                    else {
                        result.__xml__.error = new Error('End of data found, expected /> or >');
                    }
                }
                else {
                    result.__xml__.error = new Error('Expected indent');
                }
            }
            else {
                result.__xml__.error = new Error('End of data found, expected indent');
            }
            result.__xml__.end = i;
        }
        else {
            result.__xml__.error = new Error('"' + cToken.text + '"' + 'found, expected <');
        }
    }
    else {
        result.__xml__.error = new Error('End of data found, expected <');
    }
    result.__xml__.end = i;
    return result;
}

/**
 * 
 * @param {Array<Token>} tokens 
 * @param {Number} i 
 * @returns {XMLParseNode}
 */
function matchDeclaration(tokens, i) {
    var result = { __xml__: { type: DECLARATION, start: i } };
    var cToken;
    if (i < tokens.length) {
        cToken = tokens[i];
        if (cToken.matched['declarationOpen']) {
            ++i;
            if (i < tokens.length) {
                cToken = tokens[i];
                if (cToken.matched['ident']) {
                    result.tagName = cToken.text;
                    ++i;
                    if (i < tokens.length) {
                        var finished = false;//when find the close symbol
                        while (i < tokens.length) {
                            cToken = tokens[i];
                            if (cToken.matched['space']) {
                                ++i;
                            }//skip space between attributes
                            if (i < tokens.length) {
                                cToken = tokens[i];
                                if (cToken.matched['declarationClose']) {
                                    result.__xml__.closed = false;
                                    ++i;
                                    finished = true;
                                    break;
                                }
                                else if (tokens[i - 1].matched['space']) {
                                    var assign = matchAssign(tokens, i);
                                    if (!assign.__xml__.error) {
                                        result.attributes = result.attributes || {};
                                        result.attributes[assign.key] = assign.value;
                                        i = assign.__xml__.end;
                                    }
                                    else if (cToken.matched['ident']) {
                                        result.attributes = result.attributes || {};
                                        result.attributes[cToken.text] = true;// a flag
                                        ++i;
                                    }
                                    else {
                                        result.__xml__.error = new Error('"' + cToken.text + '"' + 'found, expected > or indent');

                                    }
                                }
                                else {
                                    result.__xml__.error = new Error('"' + cToken.text + '"' + 'found, expected > or indent');
                                }
                            }
                            else {
                                result.__xml__.error = new Error('End of data found, expected /> or >');
                            }
                        }
                        if (!finished && !result.__xml__.error) {
                            result.__xml__.error = new Error('End of data found, expected /> or >');
                        }
                    }
                    else {
                        result.__xml__.error = new Error('End of data found, expected /> or >');
                    }
                }
                else {
                    result.__xml__.error = new Error('Expected indent');
                }
            }
            else {
                result.__xml__.error = new Error('End of data found, expected indent');
            }
            result.__xml__.end = i;
        }
        else {
            result.__xml__.error = new Error('"' + cToken.text + '"' + 'found, expected <');
        }
    }
    else {
        result.__xml__.error = new Error('End of data found, expected <');
    }
    result.__xml__.end = i;
    return result;
}



/**
 * 
 * @param {Array<Token>} tokens 
 * @param {Number} i 
 * @returns {XMLParseNode}
 */
function matchCData(tokens, i) {
    var result = { __xml__: { type: CDATA, start: i } };
    var cToken;
    if (i < tokens.length) {
        cToken = tokens[i];
        if (cToken.matched['cdataOpen']) {
            ++i;
            result.text = '';
            var finished = false;
            while (i < tokens.length) {
                cToken = tokens[i];

                if (cToken.matched['cdataClose']) {
                    finished = true;
                    ++i;
                    break;
                }
                else {
                    result.text += cToken.text;
                    ++i;
                }
            }
            if (!finished) {
                result.__xml__.error = new Error('End of data found, expected ]]>');
            }
        }
        else {
            result.__xml__.error = new Error('"' + cToken.text + '"' + 'found, expected <![CDATA[');
        }
    }
    else {
        result.__xml__.error = new Error('End of data found, expected <![CDATA[');
    }
    result.__xml__.end = i
    return result;
}



/**
 * 
 * @param {Array<Token>} tokens 
 * @param {Number} i 
 * @returns {XMLParseNode}
 */
function matchComment(tokens, i) {
    var result = { __xml__: { type: COMMENT, start: i } };
    var cToken;
    if (i < tokens.length) {
        cToken = tokens[i];
        if (cToken.matched['commentOpen']) {
            ++i;
            result.text = '';
            var finished = false;
            while (i < tokens.length) {
                cToken = tokens[i];

                if (cToken.matched['commentClose']) {
                    finished = true;
                    ++i;
                    break;
                }
                else {
                    result.text += cToken.text;
                    ++i;
                }
            }
            if (!finished) {
                result.__xml__.error = new Error('End of data found, expected -->');
            }
        }
        else {
            result.__xml__.error = new Error('"' + cToken.text + '"' + 'found, expected <!--');
        }
    }
    else {
        result.__xml__.error = new Error('End of data found, expected <!--');
    }
    result.__xml__.end = i;
    return result;
}

/**
 * 
 * @param {Token} tokens 
 */
function parseXMLTab(tokens) {
    var tabs = [];
    var i = 0;
    while (i < tokens.length) {
        var comment = matchComment(tokens, i);
        if (!comment.__xml__.error) {
            tabs.push(comment);
            i = comment.__xml__.end;
        }
        else {
            var declaration = matchDeclaration(tokens, i);
            if (!declaration.__xml__.error) {
                tabs.push(declaration);
                i = declaration.__xml__.end;
            }
            else {
                var begin = matchBeginTag(tokens, i);
                if (!begin.__xml__.error) {
                    tabs.push(begin);
                    i = begin.__xml__.end;
                }
                else {
                    var end = matchEndTag(tokens, i);
                    if (!end.__xml__.error) {
                        tabs.push(end);
                        i = end.__xml__.end;
                    }
                    else {
                        var cdata = matchCData(tokens, i);
                        if (!cdata.__xml__.error) {
                            tabs.push(cdata);
                            i = cdata.__xml__.end;
                        }
                        else {
                            ++i;//skip
                        }
                    }
                }
            }
        }
    }
    return tabs;
}



/**
 * 
 * @param {Array<Token>} tokens 
 * @param {Array<XMLParseNode>} tabs 
 * @returns {Array<XMLParseNode>}
 */
function parseXMLText(tokens, tabs) {
    var texts = [];
    var ofs = 0;
    var text;
    var tab;
    for (var i = 0; i < tabs.length; ++i) {
        tab = tabs[i];
        if (tab.__xml__.start > ofs) {
            text = tokens.slice(ofs, tab.__xml__.start)
                .map(function (token) {
                    return token.text;
                }).join('').trim();
            if (text.length > 0)
                texts.push({
                    __xml__: {
                        type: TEXT,
                        tokens: tokens,
                        start: ofs,
                        end: tab.__xml__.start
                    },
                    text: text
                });
        }
        ofs = tab.__xml__.end;
    }
    if (ofs < tokens.length) {
        text = tokens.slice(ofs)
            .map(function (token) {
                return token.text;
            }).join('').trim();
        if (text.length > 0)
            texts.push({
                __xml__: {
                    type: TEXT,
                    tokens: tokens,
                    start: ofs,
                    end: tab.__xml__.start
                },
                text: text
            });
    }
    return texts;
}


/**
 * 
 * @param {Array<XMLParseNode>} tabs 
 * @param {Array<XMLParseNode>} texts 
 * @return {Array<XMLParseNode>}  
 */
function mergeNodes(tabs, texts) {
    var nodes = [];
    var choose;
    var iTabs = 0, iTexts = 0;
    var diTabs, diTexts;
    var minStart;
    do {
        choose = undefined;
        diTabs = 0, diTexts = 0;
        minStart = 100000000;
        if (iTabs < tabs.length) {
            choose = tabs[iTabs];
            minStart = choose.__xml__.start;
            diTabs = 1;
        }

        if (iTexts < texts.length && texts[iTexts].__xml__.start < minStart) {
            choose = texts[iTexts];
            minStart = choose.__xml__.start;
            diTabs = 0;
            diTexts = 1;
        }
        if (choose) {
            iTexts += diTexts;
            iTabs += diTabs;
            nodes.push(choose);
        }
    } while (choose);
    return nodes;
}

/**
 * 
 * @param {String} text 
 * @return {Array<XMLParseNode>} 
 */
function parseXMLTextToXMLParseNode(text) {
    text = text.trim();
    var tokens = xmlTokenize(text.trim());

    var tabs = parseXMLTab(tokens);
    var texts = parseXMLText(tokens, tabs);
    return mergeNodes(tabs, texts);
}


/**
 * 
 * @param {Array<XMLParseNode>} nodes
 * @returns {Array}
 */
function paresNodesToXMLs(nodes) {
    var node;
    var parentXMLElement = new XML_XMLElement();
    parentXMLElement.tagName = "FAKE_DOCUMENT";

    var assignAttributes = function (node, attributes) {
        Object.keys(attributes).forEach(function (key) {
            node.setAttribute(key, attributes[key]);
        })
    }

    var newXMLNode;
    for (var i = 0; i < nodes.length; ++i) {
        node = nodes[i];
        newXMLNode = undefined;
        switch (node.__xml__.type) {
            case DECLARATION:
                newXMLNode = new XMLDeclarationNode();
                newXMLNode.tagName = node.tagName;
                if (node.attributes)
                    assignAttributes(newXMLNode, node.attributes);

                parentXMLElement.appendChild(newXMLNode);
                break;
            case BEGIN_TAG:
                newXMLNode = new XML_XMLElement();
                newXMLNode.tagName = node.tagName;
                if (node.attributes)
                    assignAttributes(newXMLNode, node.attributes);
                parentXMLElement.appendChild(newXMLNode);
                if (!node.__xml__.closed)
                    parentXMLElement = newXMLNode;
                break;
            case END_TAG:
                if (parentXMLElement && node.tagName == parentXMLElement.tagName) {
                    parentXMLElement = parentXMLElement.parentNode;
                }
                else if (parentXMLElement && (parentXMLElement.tagName == 'img' || parentXMLElement.tagName == 'input')) {
                    // image can be not close
                    while (parentXMLElement.tagName == 'img' || parentXMLElement.tagName == 'input') {
                        parentXMLElement = parentXMLElement.parentNode;
                    }

                    parentXMLElement = parentXMLElement.parentNode;
                }

                else {
                    throw new Error("Unknown close of tagName " + node.tagName
                        + ', but ' + (parentXMLElement ? parentXMLElement.tagName : "EOF") + ' expected');

                }
                break;
            case TEXT:
                newXMLNode = new XML_XMLTextNode(node.text);
                parentXMLElement.appendChild(newXMLNode);
                break;
            case COMMENT:
                newXMLNode = new XML_XMLCommentNode(node.text);
                parentXMLElement.appendChild(newXMLNode);
                break;
        }

    }
    return parentXMLElement.childNodes.slice().map(function (e) {
        e.remove();
        return e;
    });
}


/**
 * 
 * @param {XMLElement} node 
 */
function makeOpenXMLElementTab(node) {
    var res = '<' + node.tagName;
    var attributesText = Object.keys(node.attributes)
        .map(function (key) {
            var value = node.attributes[key];
            if (value === null) {
                return key;
            }
            else {
                return key + '=' + '"' + value + '"';
            }

        }).join(' ');
    if (attributesText.length > 0) {
        res += ' ' + attributesText;
    }
    res += '>';
    return res;
}

/**
 * 
 * @param {XMLDeclaretionNode} node 
 */
function makeXMLDeclaretionTab(node) {
    var res = '<?' + node.tagName;
    var attributesText = Object.keys(node.attributes)
        .map(function (key) {
            var value = node.attributes[key];
            if (value === null) {
                return key;
            }
            else {
                return key + '=' + '"' + value + '"';
            }

        }).join(' ');
    if (attributesText.length > 0) {
        res += ' ' + attributesText;
    }
    res += '?>';
    return res;
}


/**
 * 
 * @param {XMLDeclaretionNode} node 
 */
function makeXMLCommentTab(node) {
    var res = '<!--' + node.data + '-->';
    return res;
}

var XML = {};

/**
 * @param {String} code
 * @returns {Array<XMLElement>}
 */
XML.parseLikeHTML = function (code) {
    var nodes = parseXMLTextToXMLParseNode(code);
    // console.log('nodes', nodes);
    var xmls = paresNodesToXMLs(nodes);
    return xmls;
};

/**
 * @param {String} code
 * @returns {XMLElement}
 */
XML.parse = function (code) {
    var xmls = this.parseLikeHTML(code);
    if (xmls.length == 0) return undefined;
    var obj = xmls[xmls.length - 1].toObject();
    return obj;
};


XML.DFNodeVisit = function (node, handlers, accumulator) {
    if (!node.childNodes || node.childNodes.length == 0) {
        if (handlers.leaf) handlers.leaf(accumulator, node);
    }
    else {
        if (handlers.open) handlers.open(accumulator, node);
        for (var i = 0; i < node.childNodes.length; ++i) {
            this.DFNodeVisit(node.childNodes[i], handlers, accumulator);
        }
        if (handlers.close) handlers.close(accumulator, node);
        return accumulator;
    }
};


/**
 * @typedef {Object} XMLBeautifyOption
 * @property {String} indent
 * @property {Number} initDepth 
 */

/**
 * @param {Array<XMLElement>} o 
 * @param {XMLBeautifyOption} beautifyOption 
 * 
 * 
 */
XML.stringify = function (o, beautifyOption) {
    var texts = [];
    var indent = '';
    var lineBreak = '';
    var depth = 0;
    if (beautifyOption) {
        lineBreak = '\n';
        indent = typeof (beautifyOption.indent) == 'string' ? beautifyOption.indent : '    ';
        depth = beautifyOption.initDepth || 0;
    }

    if (!(o instanceof Array)) {
        o = [o];
    }
    var visitor = {
        open: function (ac, node) {
            var currentLineIndent = ac.lineIndentStack[ac.lineIndentStack.length - 1];

            var openTabText = makeOpenXMLElementTab(node);
            ac.texts.push(currentLineIndent + openTabText);
            ac.lineIndentStack.push(currentLineIndent + ac.indent);
        },
        close: function (ac, node) {
            ac.lineIndentStack.pop();
            var currentLineIndent = ac.lineIndentStack[ac.lineIndentStack.length - 1];
            var endTab = '</' + node.tagName + '>';
            if (node.childNodes.length == 1 && node.childNodes[0].nodeType == XML_XMLConstant.TYPE_TEXT) {
                ac.texts[ac.texts.length - 1] += endTab;
            }
            else {
                ac.texts.push(currentLineIndent + endTab);
            }

        },
        leaf: function (ac, node) {
            var currentLineIndent = ac.lineIndentStack[ac.lineIndentStack.length - 1];
            var tab;
            if (node.nodeType == XML_XMLConstant.TYPE_TEXT) {
                if (node.parentNode && node.parentNode.childNodes.length == 1) {
                    ac.texts[ac.texts.length - 1] += node.data;
                }
                else {
                    ac.texts.push(currentLineIndent + node.data);
                }
            }
            else if (node.nodeType == XML_XMLConstant.TYPE_ELEMENT) {
                var openTabText = makeOpenXMLElementTab(node);
                var endTab = '</' + node.tagName + '>';
                ac.texts.push(currentLineIndent + openTabText + endTab);
            }
            else if (node.nodeType == XML_XMLConstant.TYPE_DECLARATION) {
                tab = makeXMLDeclaretionTab(node);
                ac.texts.push(currentLineIndent + tab);
            }
            else if (node.nodeType == XML_XMLConstant.TYPE_COMMENT) {
                tab = makeXMLCommentTab(node);
                ac.texts.push(currentLineIndent + tab);
            }
        }
    };

    for (var i = 0; i < o.length; ++i) {
        this.DFNodeVisit(o[i],
            visitor,
            {
                depth: 0,
                texts: texts,
                lineIndentStack: [''],
                indent: indent
            });
    }
    return texts.join(lineBreak);
};



/* harmony default export */ var XML_XML = (XML);


// CONCATENATED MODULE: ./node_modules/absol/src/JSMaker/TemplateXML.js





function TemplateXML(props) {
    this.xml = props.xml;
}


TemplateXML.prototype._xmlNodeToJSCode = function (node) {
    var body = [];
    if (node.nodeType == XML_XMLConstant.TYPE_ELEMENT) {
        body.push('tag:' + JSON.stringify(node.tagName));
        var attributeKeys = Object.keys(node.attributes).filter(function (x) { return x != 'class' && x != 'style' && !x.startsWith('az-') });
        if (attributeKeys && attributeKeys.length > 0) {
            body.push('attr: {' + attributeKeys.map(function (key) {
                return JSON.stringify(key) + ': ' + TemplateString["a" /* default */].parse(node.attributes[key]).toJSCode();
            }).join(', ') + '}');
        }

        if (node.attributes['az-props']) {
            body.push('props: ' + TemplateString["a" /* default */].parse(node.attributes['az-props']).toJSCode() );
        }
        if (node.attributes['az-data']) {
            body.push('data: ' + TemplateString["a" /* default */].parse(node.attributes['az-data']).toJSCode() );
        }

        if (node.attributes.style) {
            var styleSheet = node.attributes.style.split(';').map(function (s) {
                var t = s.split(':').map(function (text) { return text.trim() });
                if (t.length == 2) {
                    return JSON.stringify(t[0]) + ': ' + JSON.stringify(t[1]);
                }
                else return false;

            }).filter(function (e) {
                return !!e;
            });
       
            if (styleSheet.length > 0) {
                body.push('style:{' + styleSheet.join(',') + '}');
            }
        }

        if (node.attributes.class) {
            var classList = node.attributes.class.trim().split(/\s+/);
            if (classList.length > 0)
                body.push('class:' + JSON.stringify(classList));
        }

        if (node.childNodes && node.childNodes.length > 0) {
            var childList = '[' + node.childNodes.filter(function (e) {
                return e.nodeType == XML_XMLConstant.TYPE_ELEMENT || e.nodeType == XML_XMLConstant.TYPE_TEXT;
            }).map(function (e) {
                return this._xmlNodeToJSCode(e);
            }.bind(this)).filter(function (e) { return !!e; }).join(', ') + ']';
            if (childList && childList.length > 0)
                body.push('child: ' + childList);
        }
    }
    else if (node.nodeType == XML_XMLConstant.TYPE_TEXT) {
        body.push('text: ' + TemplateString["a" /* default */].parse(node.data).toJSCode());
    }
    else return undefined;

    var res = '{' + body.join(', ') + '}';
    return res;
};

TemplateXML.prototype.toJSCode = function () {
    var res = this._xmlNodeToJSCode(this.xml);
    return res;
};

/**
 * 
 * @param  {...any} args 
 * @returns {Function}
 */
TemplateXML.compileToFunction = function () {
    var innerCode = 'return ' + this.parse(arguments[arguments.length - 1]).toJSCode() + ';';
    var fParam = Array.prototype.slice.call(arguments, 0, arguments.length - 1);
    fParam.push(innerCode);
    return Function.apply(null, fParam);
};



TemplateXML.parse = function (text) {
    var xml = XML_XML.parse(text);
    if (xml) {
        return new TemplateXML({
            xml: xml
        });
    }
    else
        return undefined;
};

/* harmony default export */ var JSMaker_TemplateXML = (TemplateXML);
// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/Svg.js
var Svg = __webpack_require__(16);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/OOP.js
var OOP = __webpack_require__(2);

// EXTERNAL MODULE: ./node_modules/absol/src/Color/Color.js
var Color = __webpack_require__(57);

// EXTERNAL MODULE: ./node_modules/absol/src/Network/IFrameBridge.js
var IFrameBridge = __webpack_require__(52);

// EXTERNAL MODULE: ./node_modules/absol/src/JSDocx/JSDocx.js
var JSDocx = __webpack_require__(105);

// EXTERNAL MODULE: ./node_modules/absol/src/String/stringGenerate.js + 1 modules
var stringGenerate = __webpack_require__(12);

// CONCATENATED MODULE: ./node_modules/absol/src/Network/Broadcast.js



// it can be replace BroadcastChanel
function Broadcast(channel, id) {
    EventEmitter["b" /* default */].call(this);
    this.channel = channel;
    this.id = id;
    this._ev_message = this._ev_message.bind(this);
    this._ev_storage = this._ev_storage.bind(this);
    this._init();
}

Object.defineProperties(Broadcast.prototype, Object.getOwnPropertyDescriptors(EventEmitter["b" /* default */].prototype));

Broadcast.prototype.constructor = Broadcast;


Broadcast.prototype._init = function () {
    if ('BroadcastChannel' in window) {
        this.nativeBroadcastChannel = new BroadcastChannel(this.channel);
        this.nativeBroadcastChannel.onmessage = this._ev_message;
    }
    else if ('localStorage' in window) {
        if (!('onstorage' in window))
            console.warn("Your browser may not support onstorage event.");
        if (window.addEventListener) {
            window.addEventListener('storage', this._ev_storage);
        }
        else {
            window.attachEvent('onstorage', this._ev_storage);
        }
        this.storageKey = '_broadcast_' + this.channel;
    }
    else {
        throw new Error("Your browser can not support broadcast!");
    }
};

Broadcast.prototype._ev_storage = function (event) {
    if (event.key == this.storageKey) {
        var data = JSON.parse(event.newValue);
        if (data.sourceId != this.id)
            this.handleMessData(data.message);
    }
};

Broadcast.prototype._ev_message = function (event) {
    var data = event.data;
    this.handleMessData(data);
};


Broadcast.prototype.handleMessData = function (data) {
    if (data.type == "EMIT")
        this.fire.apply(this, data.params);
    if (typeof this.onmessage == 'function')
        this.onmessage(event);
};

/**
 * @param {Array<*>}
 */
Broadcast.prototype.emit = function () {
    var params = Array.prototype.slice.call(arguments);
    this.postMessage({ type: "EMIT", params, sourceId: this.id });
};

/**
 * @param {*} message
 */
Broadcast.prototype.postMessage = function (message) {
    if (this.nativeBroadcastChannel) {
        this.nativeBroadcastChannel.postMessage(message);
    }
    else {
        localStorage.setItem(this.storageKey, JSON.stringify({ message: message, sourceId: this.id }));
    }
};

Broadcast.prototype.onmessage = null;


Broadcast.prototype.close = function () {
    if (this.nativeBroadcastChannel) this.nativeBroadcastChannel.close();
};

/* harmony default export */ var Network_Broadcast = (Broadcast);
// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/Text.js
var Text = __webpack_require__(30);

// EXTERNAL MODULE: ./node_modules/absol/src/Converter/file.js + 1 modules
var file = __webpack_require__(36);

// CONCATENATED MODULE: ./node_modules/absol/src/Converter/base64.js
function base64EncodeUnicode(str) {
    return btoa(encodeURIComponent(str).replace(/%([0-9A-F]{2})/g,
        function toSolidBytes(match, p1) {
            return String.fromCharCode('0x' + p1);
        }));
};

function base64DecodeUnicode(str) {
    return decodeURIComponent(atob(str).split('').map(function (c) {
        return '%' + ('00' + c.charCodeAt(0).toString(16)).slice(-2);
    }).join(''));
}


var UnicodeBase64Converter = {
    encode: base64EncodeUnicode,
    decode: base64DecodeUnicode
};
// CONCATENATED MODULE: ./node_modules/absol/src/Time/Alarm.js
/**
 * 
 * @param {Date| Number} time 
 * @param {Function} callback 
 */
function Alarm(time, callback) {
    this.LIMIT_TIMEOUT = 2147483647;
    this.callback = callback;
    this.state = "STAND_BY";
    this.timeout = -1;
    if (typeof time == 'number')
        this.time = time;
    else this.time = time.getTime();
    this.args = Array.prototype.slice.call(arguments, 2);
    this.tick = this.tick.bind(this);
    if (this.time >= new Date().getTime())
        this.start();
    else
        this.kill();
}


Alarm.prototype.start = function () {
    if (this.state == 'STAND_BY' || this.state == "PAUSE") {
        this.state = "RUNNING";
        this.tick();
        return true;
    }
    return false;
};

Alarm.prototype.pause = function () {
    if (this.state == "RUNNING") {
        clearTimeout(this.timeout);
        this.timeout = -1;
        this.state = 'PAUSE';
    }
};

Alarm.prototype.tick = function () {
    var now = new Date().getTime();
    if (now >= this.time) {
        this.callback && this.callback.apply(null, this.args);
        this.start = 'FINISH';
    }
    else {
        var deltaTime = Math.min(this.LIMIT_TIMEOUT, this.time - now);
        this.timeout = setTimeout(this.tick, deltaTime);
        this.state = "RUNNING";
    }
}

Alarm.prototype.kill = function () {
    if (this.state != "FINISH" && this.state != "DEAD") {
        if (this.timeout >= 0)
            clearTimeout(this.timeout);
        this.state = 'DEAD';
        return true;
    }
    return false;
};


/* harmony default export */ var Time_Alarm = (Alarm);
// EXTERNAL MODULE: ./node_modules/absol/src/AppPattern/Ref.js
var Ref = __webpack_require__(75);

// EXTERNAL MODULE: ./node_modules/absol/src/Network/XHR.js
var XHR = __webpack_require__(59);

// EXTERNAL MODULE: ./node_modules/absol/src/String/stringFormat.js
var stringFormat = __webpack_require__(15);

// EXTERNAL MODULE: ./node_modules/absol/src/JSX/attribute.js
var JSX_attribute = __webpack_require__(48);

// CONCATENATED MODULE: ./node_modules/absol/src/JSX/dom.js


function domVisitor(jsxCode) {
    var visitor = {
        File: function (node, ac) {
            return acept(node.program, ac);
        },
        Program: function (node, ac) {
            ac.child = node.body.map(function (cNode) {
                return acept(cNode, {});
            });
            return ac;
        },
        ExpressionStatement: function (node, ac) {
            return acept(node.expression, ac);
        },
        JSXElement: function (node, ac) {
            acept(node.openingElement, ac);
            if (node.children && node.children.length > 0) {

                ac.child = node.children.map(function (cNode) {

                    return acept(cNode, {});
                });
            }
            return ac;

        },
        JSXOpeningElement: function (node, ac) {
            var name = {};
            acept(node.name, name);
            ac.tag = name.value;
            if (node.attributes && node.attributes.length > 0) {
                node.attributes.forEach(function (aNode) {
                    var attribute = {};
                    acept(aNode, attribute);
                    if (attribute.key) {
                        if (attribute.key.startsWith('data-')) {
                            ac.data = ac.data || {};
                            ac.data[attribute.key.replace('data-', '')] = attribute.value;
                        }
                        else if (attribute.key.startsWith('prop-')) {
                            ac.props = ac.props || {};
                            ac.props[attribute.key.replace('prop-', '')] = attribute.value;
                        }
                        else if (attribute.key.startsWith('on-')) {
                            ac.on = ac.props || {};
                            ac.on[attribute.key.replace('on-', '')] = attribute.value;
                        }
                        else if (attribute.key == 'style') {
                            ac.style = Object(JSX_attribute["parseStyleAttr"])(attribute.value);
                        }
                        else if (attribute.key == 'class') {
                            var classList = Object(JSX_attribute["parseClassAttr"])(attribute.value);
                            if (classList.length > 0)
                                ac.class = classList;
                        }
                        else{
                            ac.attr = ac.attr || {};
                            ac.attr[attribute.key] = attribute.value;
                        }
                    }
                }, {});
            }
            return ac;
        },
        JSXIdentifier: function (node, ac) {
            ac.value = node.name;
        },
        JSXAttribute: function (node, ac) {
            var key = {};
            acept(node.name, key);

            ac.key = key.value;
            var value = {};

            acept(node.value, value);
            ac.value = value.value;
            return ac;
        },
        StringLiteral: function (node, ac) {
            ac.value = node.value;
        },
        JSXExpressionContainer: function (node, ac) {
            ac.value = { expression: jsxCode.substring(node.expression.start, node.expression.end) };
            return ac;
        },
        JSXText: function (node, ac) {
            ac.text = node.value
            return ac;
        }
    };
    function acept(node, ac) {
        return node && visitor[node.type] && visitor[node.type](node, ac);
    }
    return {
        acept: acept,
        visitor: visitor
    }
}


/***
 * @param {String} jsxCode
 */
function parseDom(jsxCode) {
    jsxCode = jsxCode.trim().replace(/>\s+</gm, '><').replace(/<(\/?)(img|input|link|br|meta)([^>]*)>/g, function (sub, end, tag, content) {
        if (end == '/') return '';
        return '<' + tag + content + '/>';
    });
    var ast = babel.parse(
        jsxCode,
        {
            plugins: [
                babel.pluginSyntaxJsx
            ]
        });
    var xmlData = {};
    domVisitor(jsxCode).acept(ast, xmlData);
    if (xmlData.child.length > 1) return xmlData.child;
    return xmlData.child[0];
}


// EXTERNAL MODULE: ./node_modules/absol/src/Code/noop.js
var noop = __webpack_require__(13);

// CONCATENATED MODULE: ./node_modules/absol/src/AppPattern/Context.js

function Context() {
    this.state = "CREATE";
    /**
     * @type {Context}
     */
    this.parent = null;
    /***
     *
     * @type {null|ContextManager}
     */
    this.ctxMng = null;
}


/**
 * @returns {*}
 */
Context.prototype.getContext = function (key) {
    var ctx = this;
    var res;
    while (ctx && !res){
        if (ctx.ctxMng) {
            res = ctx.ctxMng.get(key);
        }
        ctx = ctx.parent;
    }
    return res;
};

/**
 * @param {string} key
 * @param {*} value
 * @returns {*}
 */
Context.prototype.setContext = function (key, value) {
    return this.getContextManager().set(key, value);
};

/**
 * @returns {ContextManager}
 */
Context.prototype.getContextManager = function () {
    var ctx = this;
    var res;
    while (ctx && !res){
        if (ctx.ctxMng) {
            res = ctx.ctxMng;
        }
        ctx = ctx.parent;
    }
    return res;
};

/**
 * @param {Context} parent
 */
Context.prototype.attach = function (parent) {
    //stop before attach to new context
    this.stop();
    /**
     * @type {Application}
     */
    this.parent = parent;
    this.onAttached && this.onAttached();
};

Context.prototype.detach = function () {
    this.stop();
    this.onDetached && this.onDetached();
    this.parent = null;
};

Context.prototype.pause = function () {
    if (this.state.match(/RUNNING|PAUSE/)) {
        if (this.state === "RUNNING"){
            this.state = "PAUSE";
            this.onPause && this.onPause();
        }
    }
    else {
        console.warn(this, "NOT RUNNING");
    }
};
Context.prototype.resume = function () {
    if (!this.state.match(/STANDBY|PAUSE|RUNNING/)) {
        console.error(this, 'NOT READY!', this.state);
        return;
    }
    if (this.state === "RUNNING") return;
    this.state = "RUNNING";
    this.onResume && this.onResume();
};

/***
 * @param {boolean=} standBy start but waiting for resume()
 */
Context.prototype.start = function (standBy) {
    if (this.state.match(/DIE/)) {
        console.error(this, 'DIED!');
        return;
    }

    if (this.state.match(/RUNNING/)) return;

    if (this.state.match(/STOP|CREATE/)) {
        this.state = "STANDBY";
        this.onStart && this.onStart();
    }
    if (!standBy && this.state.match(/STANDBY|PAUSE/)) {
        this.resume();
    }
};

Context.prototype.stop = function () {
    if (this.state.match(/STOP|DIE|CREATE/)) return;
    if (this.state.match(/RUNNING/)) this.pause();
    this.state = "STOP";
    this.onStop && this.onStop();
};

Context.prototype.destroy = function () {
    if (this.state.match(/DIE/)) return;
    if (this.state.match(/RUNNING|PAUSE/)) this.stop();
    this.state = "DIE";
    this.onDestroy && this.onDestroy();
};

Context.prototype.onDestroy = noop["a" /* default */];
Context.prototype.onStop = noop["a" /* default */];
Context.prototype.onStart = noop["a" /* default */];
Context.prototype.onResume = noop["a" /* default */];
Context.prototype.onPause = noop["a" /* default */];
Context.prototype.onDetached = noop["a" /* default */];
Context.prototype.onAttached = noop["a" /* default */];


/* harmony default export */ var AppPattern_Context = (Context);
// CONCATENATED MODULE: ./node_modules/absol/src/AppPattern/Activity.js


//NOTE: !impotant : don't make setter, getter for activity, just code like JAVA
/** 
 * @class
 */
function Activity() {
    AppPattern_Context.call(this);
}


Object.defineProperties(Activity.prototype, Object.getOwnPropertyDescriptors(AppPattern_Context.prototype));
Activity.prototype.constructor = Activity;


Activity.prototype.startActivity = function (activity) {
    if (this.parent) {
        this.parent.startActivity(activity);
    }
    else {
    }
};

Activity.prototype.finish = function () {
    if (this.parent) {
        this.parent.stopActivity(this);
    }
    else {

    }
};

/* harmony default export */ var AppPattern_Activity = (Activity);
// CONCATENATED MODULE: ./node_modules/absol/src/AppPattern/ContextManager.js
function ContextManager(){
    this.__contextData__ = {};
}

/**
 * @param {String} key
 * @returns {*}
 */
ContextManager.prototype.get = function(key){
    return this.__contextData__[key];
};


/**
 * @param {String} key
 * @param {*} value
 * @returns {Context}
 */
ContextManager.prototype.set = function(key, value){
    this.__contextData__[key] = value;
    return this;
};

ContextManager.prototype.assign = function(obj){
    Object.assign(this.__contextData__, obj);
    return this;
};

ContextManager.prototype.remove = function(key){
    delete this.__contextData__[key];
    return this;
};

ContextManager.prototype.contains = function(key){
    return  (key in this.__contextData__);
};



/* harmony default export */ var AppPattern_ContextManager = (ContextManager);
// CONCATENATED MODULE: ./node_modules/absol/src/AppPattern/Application.js



/**
 * @class
 */
function Application() {
    AppPattern_Context.call(this);
    this.activityStack = [];
    /** @type {Activity} */
    this.currentActivity = null;
}

Object.defineProperties(Application.prototype, Object.getOwnPropertyDescriptors(AppPattern_Context.prototype));
Application.prototype.constructor = Application;

/**
 * @param {Activity} activity
 */
Application.prototype.startActivity = function (activity) {
    if (this.currentActivity != null) {
        this.currentActivity.pause();
        this.activityStack.push(this.currentActivity);
    }
    this.currentActivity = activity;
    this.appendChild(activity);
    activity.attach(this);
    this.setContentView(activity.getView(), true);
    activity.start();
};

/**
 * @param {Activity} activity
 */
Application.prototype.stopActivity = function (activity) {
    if (this.currentActivity == activity) {
        if (this.activityStack.length == 0) {
            //todo
        }
        else {
            activity.detach();
            this.removeChild(this.currentActivity);
            this.currentActivity = this.activityStack.pop();
            this.setContentView(this.currentActivity.getView());
            this.currentActivity.resume();
        }
    }
    else {
        console.error("NOT ON TOP ACTIVITY");
    }
};

/**
 * @param {HTMLElement} view
 */
Application.prototype.setContentView = function (view, overlay) {
    throw new Error("Not Implement!");
};

Application.prototype.backToTopActivity = function () {
    while (this.activityStack.length > 0) {
        this.currentActivity.stop();
        this.currentActivity = this.activityStack.pop();
    }
    this.setContentView(this.currentActivity.getView());
    this.currentActivity.resume();
};

/* harmony default export */ var AppPattern_Application = (Application);
// CONCATENATED MODULE: ./node_modules/absol/src/AppPattern/VarScope.js
function VarScope(parent) {
    this.parent = parent;
    this.data = {};
}

VarScope.prototype.declare = function (name, initValue) {
    if (name in this.data) throw new Error(name + ' is already delared in this scope!');
    this.data[name] = initValue;
};

VarScope.prototype.get = function (name) {
    var scope = this.findScope(name);
    if (!scope) throw new Error(name + ' is not declared!');
    return scope.data[name];
};

VarScope.prototype.set = function (name, value) {
    var scope = this.findScope(name);
    if (!scope) throw new Error(name + ' is not declared!');
    scope.data[name] = value;
};


VarScope.prototype.findScope = function (name) {
    var currentScope = this;
    while (currentScope) {
        if (name in currentScope.data) break;
        currentScope = currentScope.parent;
    }
    return currentScope;
};

/* harmony default export */ var AppPattern_VarScope = (VarScope);


// CONCATENATED MODULE: ./node_modules/absol/src/AppPattern/GrandContext.js




/***
 * @extends Context
 * @constructor
 */
function GrandContext(){
    AppPattern_Context.call(this);
    this.ctxMng = new AppPattern_ContextManager();
}

OOP["a" /* default */].mixClass(GrandContext, AppPattern_Context);

/* harmony default export */ var AppPattern_GrandContext = (GrandContext);
// CONCATENATED MODULE: ./node_modules/absol/src/AppPattern/Fragment.js





/***
 * @extends GrandContext
 * @constructor
 */
function Fragment() {
    AppPattern_GrandContext.call(this);
}

OOP["a" /* default */].mixClass(Fragment, AppPattern_GrandContext);


Fragment.prototype.createView = function () {
    throw new Error("Not implement!");
};

Fragment.prototype.getView = function () {
    if (this.$view) return this.$view;
    this.$view = this.createView() || this.$view;
    if (!this.$view) throw new Error("this.$view must be not null!");
    if (this.onCreated) this.onCreated();
    return this.$view;
};

Fragment.prototype.onCreated = noop["a" /* default */];

/* harmony default export */ var AppPattern_Fragment = (Fragment);
// EXTERNAL MODULE: ./node_modules/absol/src/Math/Rectangle.js
var Rectangle = __webpack_require__(18);

// EXTERNAL MODULE: ./node_modules/absol/src/Math/Vec2.js
var Vec2 = __webpack_require__(9);

// EXTERNAL MODULE: ./node_modules/absol/src/Math/int.js
var Math_int = __webpack_require__(14);

// CONCATENATED MODULE: ./node_modules/absol/src/Math/Arc.js



function Arc(x, y, r, start, end) {
    this.x = x;
    this.y = y;
    this.r = r;
    this.start = start;
    this.end = end;
}

Arc.prototype.isPointInBound = function (p) {
    if (Object(Math_int["distance"])(this.x, this.y, p.x, p.y) > r) return false;
    return Object(Math_int["radianInRange"])(Math.atan2(p.y - this.y, p.x - this.x), start, end);
};

Arc.prototype.isRectInBound = function (rect) {
    return this.isPointInBound(rect.A()) && this.isPointInBound(rect.B()) &&
        this.isPointInBound(rect.C()) && this.isPointInBound(rect.D());
};

Arc.prototype.isRectOutBound = function (rect) {
    return !this.isPointInBound(rect.A()) && !this.isPointInBound(rect.B()) &&
        !this.isPointInBound(rect.C()) && !this.isPointInBound(rect.D());
};

Arc.prototype.isRectCollapse = function (rect) {
    return this.isPointInBound(rect.A()) || this.isPointInBound(rect.B()) ||
        this.isPointInBound(rect.C()) || this.isPointInBound(rect.D());
};


Arc.prototype.centerPoint = function () {
    var mid = (this.start + this.end) / 2;
    var x = this.x + Math.cos(mid) * this.r * 2 / 3;
    var y = this.y + Math.sin(mid) * this.r * 2 / 3;
    return new Vec2["a" /* default */](x, y);
};

Arc.prototype.centerRoundPoint = function () {
    var mid = (this.start + this.end) / 2;
    var x = this.x + Math.cos(mid) * this.r;
    var y = this.y + Math.sin(mid) * this.r;
    return new Vec2["a" /* default */](x, y);
};


Arc.make = function (x, y, r, start, end) {
    return new Arc(x, y, r, start, end);
};


/* harmony default export */ var Math_Arc = (Arc);
// CONCATENATED MODULE: ./node_modules/absol/src/Math/NumRange.js
/**
 * 
 * @param {Number} start 
 */
function NumRange(start, length) {
    if (arguments.length == 1)
        length = 0;
    else if (arguments.length == 0) {
        length = 0;
        start = 0;
    }
    this.start = start;
    this.length = length;
}


/**
 * @param {Number} num 
 */
NumRange.prototype.contains = function (num) {
    return (num >= this.start) && (num <= this.start + this.length);
};


/**
 * @param {NumRange} other
 * @returns {NumRange}
 */
NumRange.prototype.merge = function (other) {
    var start = Math.min(this.start, other.start);
    var end = Math.max(this.start + this.length, other.start + other.length);
    return new NumRange(start, end - start);
};


NumRange.prototype.centerValue = function () {
    return this.start + this.length / 2;
};


/**
 * @param {NumRange} other
 * @returns {Boolean}
 */
NumRange.prototype.isCollapse = function (other) {
    var start = Math.max(this.start, other.start);
    var end = Math.min(this.start + this.length, other.start + other.length);
    return start <= end;
};


/**
 * @param {NumRange} other
 * @returns {Boolean}
 */
NumRange.prototype.collapsedNumRange = function (other) {
    var start = Math.max(this.start, other.start);
    var end = Math.min(this.start + this.length, other.start + other.length);
    if (start <= end)
        return new NumRange(start, end - start);
    return null;
};


NumRange.prototype.clone = function () {
    return new NumRange(this.start, this.length);
};


/* harmony default export */ var Math_NumRange = (NumRange);
// CONCATENATED MODULE: ./node_modules/absol/src/HTML5/Clipboard.js
function copyImage(src) {

    var ranges, sel;
    if (window.getSelection) {
        sel = window.getSelection();
        //backup
        ranges = [];
        for (var i = 0; i < sel.rangeCount; ++i) {
            ranges.push(sel.getRangeAt(i));
        }

        //copy
        var contentdiv = document.createElement('div');
        var image = document.createElement('img');
        contentdiv.appendChild(image);
        image.src = src;
        contentdiv.contentEditable = true;
        // contentdiv.style.display = 'none';
        document.body.appendChild(contentdiv);

        var range = document.createRange();
        range.selectNodeContents(image);
        sel.removeAllRanges();
        sel.addRange(range);
        document.execCommand('copy');
        // contentdiv.remove();

        //recover
        sel.removeAllRanges();
        for (var i = 0; i < sel.rangeCount; ++i) {
            sel.addRange(ranges[i]);
        }
    }
    else {
        console.error("Not support copy!")
        //not support IE
    }
}

function fallbackCopyTextToClipboard(text) {
    return new Promise(function (resolve, reject) {
        var textArea = document.createElement("textarea");
        textArea.value = text;

        // Avoid scrolling to bottom
        textArea.style.top = "0";
        textArea.style.left = "0";
        textArea.style.position = "fixed";

        document.body.appendChild(textArea);
        textArea.focus();
        textArea.select();

        try {
            var successful = document.execCommand('copy');
            if (successful) {
                resolve();
            }
            else {
                reject();
            }
        } catch (err) {
            reject(err);
        }

        document.body.removeChild(textArea);
    });
}

function copyText(text) {
    if (!navigator.clipboard) {
        return fallbackCopyTextToClipboard(text);
    }
    return navigator.clipboard.writeText(text);
}


function fallbackReadTextFromClipboard() {
    return new Promise(function (resolve, reject) {
        var textArea = document.createElement("textarea");

        // Avoid scrolling to bottom
        textArea.style.top = "0";
        textArea.style.left = "0";
        textArea.style.position = "fixed";

        document.body.appendChild(textArea);
        textArea.focus();

        try {
            var successful = document.execCommand('paste');
            if (successful) {
                resolve(textArea.value);
            }
            else {
                reject();
            }
        } catch (err) {
            reject(err);
        }

        document.body.removeChild(textArea);
    });
}

function pasteText() {
    if (navigator.clipboard) {
        return navigator.clipboard.readText();
    }
    else {
        return fallbackReadTextFromClipboard();
    }
}
// CONCATENATED MODULE: ./node_modules/absol/src/DataStructure/Heap.js
function defaultCmp(x, y) {
    if (x < y) {
        return -1;
    }
    if (x > y) {
        return 1;
    }
    return 0;
};


/**
 * 
 * @param {Array} arr 
 * @param {Number} pos 
 * @param {Function} cmp 
 */
function heapDown(arr, pos, cmp) {
    if (!cmp) cmp = defaultCmp;
    var item = arr[pos];
    var endPos = arr.length;
    var childPos = (pos << 1) | 1;
    var childRightPos;
    while (childPos < endPos) {
        childRightPos = childPos + 1;
        if (childPos + 1 < endPos && cmp(arr[childPos], arr[childRightPos]) > 0) {
            childPos = childRightPos;
        }
        if (cmp(arr[childPos], item) < 0) {
            arr[pos] = arr[childPos];
            arr[childPos] = item;
            pos = childPos;
            childPos = (pos << 1) | 1;
        }
        else break;
    }
}


/**
 * 
 * @param {Array} arr 
 * @param {Number} pos 
 * @param {Function} cmp 
 */
function heapUp(arr, pos, cmp) {
    if (!cmp) cmp = defaultCmp;
    var item = arr[pos];
    var parPos;
    while (pos > 0) {
        parPos = (pos - 1) >> 1;
        if (cmp(arr[parPos], item) > 0) {
            arr[pos] = arr[parPos];
            arr[parPos] = item;
            pos = parPos;
        }
        else break;
    }
}


/**
 *
 * @param {Array} arr
 * @param {Function} cmp
 */
function heapify(arr, cmp) {
    if (!cmp) cmp = defaultCmp;
    var endPos = arr.length;
    for (var i = 0; i < endPos; ++i)
        heapUp(arr, i, cmp);
}



/**
 * 
 * @param {Array} arr 
 * @param {Function} cmp 
 */
function heapPop(arr, cmp) {
    if (!cmp) cmp = defaultCmp;
    var item = arr[0];
    var lastItem = arr.pop();
    if (arr.length > 0) {
        arr[0] = lastItem;
        heapDown(arr, 0, cmp);
    }
    return item;
}


/**
 * 
 * @param {Array} arr 
 * @param {*} item
 * @param {Function} cmp 
 */
function heapPush(arr, item, cmp) {
    if (!cmp) cmp = defaultCmp;
    arr.push(item);
    heapUp(arr, arr.length - 1, cmp);
}




function Heap(cmd) {
    this.cmp = cmd || defaultCmp;
    this.arr = [];
}

/**
 * @param {Array} arr
 * @param {Function} cmp
 * @returns {Heap}
 */
Heap.fromArray = function (arr, cmp) {
    var heap = new Heap(cmp);
    heapify(arr);
    heap.arr = arr;
    return heap;
};



Heap.prototype.push = function (x) {
    heapPush(this.arr, x, this.cmp);
    return this;
};

Heap.prototype.pop = function () {
    return heapPop(this.arr, this.cmp);
};

Heap.prototype.peek = function () {
    return this.arr[0];
};

Heap.prototype.contains = function (x) {
    return this.arr.indexOf(x) !== -1;
};


Heap.prototype.clear = function () {
    this.arr.splice(0, this.arr.length);
    return this;
};

Heap.prototype.empty = function () {
    return this.arr.length === 0;
};

Heap.prototype.size = function () {
    return this.arr.length;
};

Heap.prototype.clone = function () {
    var heap;
    heap = new Heap(this.cmp);
    heap.arr = this.arr.slice(0);
    return heap;
};

Heap.prototype.toArray = function () {
    return this.arr.slice(0);
};

Heap.prototype.toSortedArray = function () {
    var res = [];
    var heap = this.clone();
    while (!heap.empty())
        res.push(heap.pop());
    return res;
};


Heap.prototype.insert = Heap.prototype.push;

Heap.prototype.top = Heap.prototype.peek;

Heap.prototype.front = Heap.prototype.peek;

Heap.prototype.has = Heap.prototype.contains;

Heap.prototype.copy = Heap.prototype.clone;

/* harmony default export */ var DataStructure_Heap = (Heap);

// EXTERNAL MODULE: ./node_modules/absol/src/Time/datetime.js
var datetime = __webpack_require__(5);

// EXTERNAL MODULE: ./node_modules/absol/src/AppPattern/CMDRunner.js
var CMDRunner = __webpack_require__(60);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/Element.js
var Element = __webpack_require__(24);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/AElementNS.js
var AElementNS = __webpack_require__(56);

// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/DomSignal.js
var DomSignal = __webpack_require__(20);

// CONCATENATED MODULE: ./node_modules/absol/src/Cookie/CookieStore.js


function CookieStore(converter) {
    this.converter = converter || UnicodeBase64Converter;
}


CookieStore.prototype.isEnabled = function () {
    var cookieEnabled = !!navigator.cookieEnabled;

    //if not IE4+ nor NS6+
    if (typeof navigator.cookieEnabled == "undefined" && !cookieEnabled) {
        document.cookie = "testcookie_enabled";
        cookieEnabled = document.cookie.indexOf("testcookie_enabled") != -1;
    }
    return cookieEnabled;
};

CookieStore.prototype.secure = function () {
    document.cookie = "secure";
};


CookieStore.prototype.get = function (key) {
    var bkey = this.converter.encode(key).replace(/=/g, '_');
    var pairs = document.cookie.split(';')
        .map(function (text) { return text.split('=') })
        .filter(function (pair) {
            return pair[0].trim() == bkey;
        });
    if (pairs.length > 0) {
        if (pairs[0].length > 1) {
            var bvalue = pairs[0][1];
            return this.converter.decode(bvalue.replace(/_/g, '=').trim());
        }
        else {
            return true;
        }
    }
    else
        return undefined;
};


CookieStore.prototype.set = function (key, value) {
    var bkey = this.converter.encode(key);
    var bvalue = this.converter.encode(value);
    document.cookie = bkey.replace(/=/g, '_') + "=" + bvalue.replace(/=/g, '_');
};

/* harmony default export */ var Cookie_CookieStore = (new CookieStore());



// CONCATENATED MODULE: ./node_modules/absol/src/Cookie/parseCookieString.js
/***
 *
 * @param {string} text
 * @return {{}}
 */
function parseCookieString(text) {
    return text.split(/\s*;\s*/).reduce(function (ac, item) {
        var tokens = item.split('=');
        var name = (tokens.shift() || '').trim();
        if (!name) return ac;
        var value = (tokens.shift() || '').trim();
        if (!value) value = true;
        ac[name] = value;
        return ac;
    }, {});
}
// CONCATENATED MODULE: ./node_modules/absol/src/Math/Mat3.js


function Mat3(data) {
    this.data = data || Array(6).fill(0);
}

Mat3.identity = function () {
    return new Mat3([1, 0, 0, 0, 1, 0, 0, 0, 1]);
};

/**
 *
 * @returns {Mat3|null}
 */
Mat3.prototype.invert = function () {
    var a = this.data;
    var out = Array(9);
    var a00 = a[0], a01 = a[1], a02 = a[2];
    var a10 = a[3], a11 = a[4], a12 = a[5];
    var a20 = a[6], a21 = a[7], a22 = a[8];

    var b01 = a22 * a11 - a12 * a21;
    var b11 = -a22 * a10 + a12 * a20;
    var b21 = a21 * a10 - a11 * a20;

    // Calculate the determinant
    var det = a00 * b01 + a01 * b11 + a02 * b21;

    if (!det) return null;
    det = 1.0 / det;

    out[0] = b01 * det;
    out[1] = (-a22 * a01 + a02 * a21) * det;
    out[2] = (a12 * a01 - a02 * a11) * det;
    out[3] = b11 * det;
    out[4] = (a22 * a00 - a02 * a20) * det;
    out[5] = (-a12 * a00 + a02 * a10) * det;
    out[6] = b21 * det;
    out[7] = (-a21 * a00 + a01 * a20) * det;
    out[8] = (a11 * a00 - a01 * a10) * det;
    return new Mat3(out);
};

/**
 *
 * @param {Vec2} v
 * @return {Mat3}
 */
Mat3.prototype.translate = function (v) {
    var out = Array(9);
    var a = this.data;
    var a00 = a[0], a01 = a[1], a02 = a[2];
    var a10 = a[3], a11 = a[4], a12 = a[5];
    var a20 = a[6], a21 = a[7], a22 = a[8];
    var x = v.x, y = v.y;

    out[0] = a00;
    out[1] = a01;
    out[2] = a02;

    out[3] = a10;
    out[4] = a11;
    out[5] = a12;

    out[6] = x * a00 + y * a10 + a20;
    out[7] = x * a01 + y * a11 + a21;
    out[8] = x * a02 + y * a12 + a22;
    return new Mat3(out);
};


/**
 *
 * @param {Mat3} mat
 * @returns {Mat3}
 */
Mat3.prototype.multiply = function (mat) {
    var a = this.data;
    var b = mat.data;
    var a00 = a[0], a01 = a[1], a02 = a[2];
    var a10 = a[3], a11 = a[4], a12 = a[5];
    var a20 = a[6], a21 = a[7], a22 = a[8];

    var b00 = b[0], b01 = b[1], b02 = b[2];
    var b10 = b[3], b11 = b[4], b12 = b[5];
    var b20 = b[6], b21 = b[7], b22 = b[8];

    var out = Array(9);
    out[0] = b00 * a00 + b01 * a10 + b02 * a20;
    out[1] = b00 * a01 + b01 * a11 + b02 * a21;
    out[2] = b00 * a02 + b01 * a12 + b02 * a22;

    out[3] = b10 * a00 + b11 * a10 + b12 * a20;
    out[4] = b10 * a01 + b11 * a11 + b12 * a21;
    out[5] = b10 * a02 + b11 * a12 + b12 * a22;

    out[6] = b20 * a00 + b21 * a10 + b22 * a20;
    out[7] = b20 * a01 + b21 * a11 + b22 * a21;
    out[8] = b20 * a02 + b21 * a12 + b22 * a22;

    return new Mat3(out);
}

/***
 *
 * @param {Number} rad
 * @return {Mat3}
 */
Mat3.prototype.rotate = function (rad) {
    var a = this.data;
    var a00 = a[0], a01 = a[1], a02 = a[2];
    var a10 = a[3], a11 = a[4], a12 = a[5];
    var a20 = a[6], a21 = a[7], a22 = a[8];

    var s = Math.sin(rad);
    var c = Math.cos(rad);
    var out = Array(9);

    out[0] = c * a00 + s * a10;
    out[1] = c * a01 + s * a11;
    out[2] = c * a02 + s * a12;

    out[3] = c * a10 - s * a00;
    out[4] = c * a11 - s * a01;
    out[5] = c * a12 - s * a02;

    out[6] = a20;
    out[7] = a21;
    out[8] = a22;
    return new Mat3(out);
};

/***
 *
 * @param {Vec2} v
 * @returns {Mat3}
 */
Mat3.prototype.scale = function (v) {
    var x = v.x;
    var y = v.y;
    var out = Array(9);
    out[0] = x * a[0];
    out[1] = x * a[1];
    out[2] = x * a[2];

    out[3] = y * a[3];
    out[4] = y * a[4];
    out[5] = y * a[5];

    out[6] = a[6];
    out[7] = a[7];
    out[8] = a[8];

    return new Mat3(out);
};

/***
 *
 * @return {Mat3}
 */
Mat3.prototype.transpose = function (){
    var a = this.data;
    var out = Array(9);
    out[0] = a[0];
    out[1] = a[3];
    out[2] = a[6];
    out[3] = a[1];
    out[4] = a[4];
    out[5] = a[7];
    out[6] = a[2];
    out[7] = a[5];
    out[8] = a[8];
    return new Mat3(out);
};

/**
 *
 * @param {Vec2}v
 */
Mat3.prototype.apply2DTransform = function (v) {
    var a = this.data;
    var x0 = v.x;
    var y0 = v.y;
    var x = x0 * a[0] + y0 * a[3] + a[6];
    var y = x0 * a[1] + y0 * a[4] + a[7];
    return new Vec2["a" /* default */](x, y);
}


/* harmony default export */ var Math_Mat3 = (Mat3);
// EXTERNAL MODULE: ./node_modules/absol/src/HTML5/LanguageSystem.js
var LanguageSystem = __webpack_require__(66);

// EXTERNAL MODULE: ./node_modules/absol/src/Code/ALogger.js
var ALogger = __webpack_require__(109);

// EXTERNAL MODULE: ./node_modules/absol/src/Code/FlagManager.js
var FlagManager = __webpack_require__(63);

// CONCATENATED MODULE: ./node_modules/absol/src/AppPattern/ObservableArray.js


/***
 * @augments EventEmitter
 * @extends Array
 * @constructor
 */
function ObservableArray(array) {
    EventEmitter["b" /* default */].call(this);
    Object.defineProperty(this, '_array', {
        configurable: false,
        enumerable: false,
        value: array
    });
    this._makeArrIndex(0, array.length);
}


Object.defineProperty(ObservableArray.prototype, 'unshift',
    {
        enumerable: false,
        value: function () {
            var newItems = Array.prototype.slice.call(arguments);
            var cN = this._array.length;
            this._makeArrIndex(cN, this._array.length + newItems.length);
            this._array.unshift.apply(this._array, newItems);
            this.emit("additem", {
                target: this,
                items: newItems,
                type: 'additem',
                offset: 0,
                action: 'unshift'
            }, this);
        }
    });

Object.defineProperty(ObservableArray.prototype, 'shift',
    {
        enumerable: false,
        value: function () {
            var res = undefined;
            if (this._array.length > 0) {
                res = this._array.shift();
                this._removeIndex(this._array.length);
                this.emit("removeitem", {
                    target: this, type: 'additem',
                    offset: 0,
                    action: 'shift',
                    items: [res],
                    item: res
                }, this);
            }
            return res;
        }
    });


Object.defineProperty(ObservableArray.prototype, 'push', {
    enumerable: false,
    value: function () {
        var newItems = Array.prototype.slice.call(arguments);
        var cN = this._array.length;
        this._makeArrIndex(this._array.length, this._array.length + newItems.length);
        this._array.push.apply(this._array, newItems);
        this.emit("additem", { target: this, items: newItems, type: 'additem', offset: cN, action: 'push' }, this);
    }
});

Object.defineProperty(ObservableArray.prototype, 'pop', {
    enumerable: false,
    value: function () {
        var res = undefined;
        if (this._array.length > 0) {
            res = this._array.pop();
            this._removeIndex(this._array.length);
            this.emit("removeitem", {
                target: this,
                type: 'additem',
                offset: this._array.length,
                action: 'shift',
                items: [res],
                item: res
            }, this);
        }
        return res;
    }
});

Object.defineProperty(ObservableArray.prototype, 'replace', {
    enumerable: false,
    value: function (offset, items) {
        for (var i = 0; i < items.length && offset < this._array.length; ++i, ++offset) {
            this._array[offset] = items[i];
        }
    }
});


Object.defineProperty(ObservableArray.prototype, 'toJSON', {
    enumerable: false,
    value: function () {
        return this._array;
    }
});

Object.defineProperty(ObservableArray.prototype, 'valueOf', {
    enumerable: false,
    value: function () {
        return this._array;
    }
});

Object.defineProperty(ObservableArray.prototype, '_makeArrIndex', {
    enumerable: false,
    value: function (cN, nN) {
        var i;
        if (nN > cN) {
            for (i = cN; i < nN; ++i)
                this._defineIndex(i);
        }
        else {
            for (i = cN - 1; i >= nN; --i)
                this._removeIndex(i);
        }
    }
});

/***
 *
 * @param {number} idx
 * @private
 */
Object.defineProperty(ObservableArray.prototype, '_defineIndex', {
    enumerable: false,
    value: function (idx) {
        if (!(idx in this)) {
            Object.defineProperty(this, idx, {
                set: function (value) {
                    var oldValue = this._array[idx]
                    this._array[idx] = value;
                    this.emit('setitem', {
                        type: 'setitem',
                        target: this,
                        oldValue: oldValue,
                        vale: value,
                        offset: idx
                    }, this);
                },
                get: function () {
                    return this._array[idx];
                },
                configurable: true,
                enumerable: true
            });
        }
    }
});

Object.defineProperty(ObservableArray.prototype, '_removeIndex', {
    enumerable: false,
    value: function (idx) {
        delete this[idx];
    }
});


Object.defineProperty(ObservableArray.prototype, 'splice', {
    enumerable: false,
    value: function (index, howMany) {
        var res = [];
        var newItems = Array.prototype.slice.call(arguments, 2);
        index = index == null ? 0 : index < 0 ? this._array.length + index : index;
        howMany = howMany == null ? this._array.length - index : howMany > 0 ? howMany : 0;
        if (howMany > 0) {
            this._makeArrIndex(this._array.length, this._array.length - howMany);
            res = this._array.splice(index, howMany);
            if (newItems.length > 0) {
                if (res.length > 0) {
                    this.emit('replaceitem', {
                        type: 'replaceitem',
                        offset: index,
                        oldItems: res,
                        newItems: newItems,
                        target: this,
                        action: 'splice'
                    }, this);
                }
                else {
                    this.emit('additem', {
                        type: 'additem',
                        offset: index,
                        items: newItems,
                        target: this
                    }, this);
                }
            }
            else {
                if (res.length > 0) {
                    this.emit('removeitem', {
                        target: this, type: 'additem',
                        offset: 0,
                        action: 'splice',
                        items: res,
                    }, this);
                }
            }
        }
        return res;
    }
});

Object.defineProperty(ObservableArray.prototype, 'length', {
    set: function (value) {
        var n = Number(value);
        var length = this._array.length;
        if (n % 1 === 0 && n >= 0) {
            if (n < length) {
                this.splice(n);
            }
            else if (n > length) {
                this.push.apply(this, new Array(n - length));
            }
        }
        else {
            throw new RangeError("Invalid array length");
        }
        this._array.length = n;
    },
    get: function () {
        return this._array.length;
    }
});


Object.getOwnPropertyNames(Array.prototype).forEach(function (name) {
    if (!(name in ObservableArray.prototype)) {
        Object.defineProperty(ObservableArray.prototype, name, {
            configurable: false,
            enumerable: false,
            writable: false,
            value: Array.prototype[name]
        });
    }
});

Object.getOwnPropertyNames(EventEmitter["b" /* default */].prototype).forEach(function (name) {
    if (!(name in ObservableArray.prototype)) {
        Object.defineProperty(ObservableArray.prototype, name, {
            configurable: false,
            enumerable: false,
            writable: false,
            value: EventEmitter["b" /* default */].prototype[name]
        });
    }
});

/* harmony default export */ var AppPattern_ObservableArray = (ObservableArray);


// CONCATENATED MODULE: ./node_modules/absol/src/AppPattern/ObservableStruct.js


/***
 * @extends EventEmitter
 * @param {Object} o
 * @constructor
 */
function ObservableStruct(o) {
    EventEmitter["b" /* default */].call(this);
    Object.defineProperty(this, '__o__', {
        configurable: false,
        enumerable: false,
        value: o
    });
    for (var key in o) this.defineProperty(key);
}

Object.defineProperty(ObservableStruct.prototype, 'defineProperty', {
    configurable: false,
    enumerable: false,
    writable: false,
    /***
     *
     * @param {string} name
     * @param {*=} value
     */
    value: function (name, value) {
        if (!(name in this)) {
            Object.defineProperty(this, name, {
                set: function (value) {
                    var oldValue = this.__o__[name]
                    this.__o__[name] = value;
                    this.emit('setproperty', {
                        type: 'setproperty',
                        target: this,
                        oldValue: oldValue,
                        vale: value,
                        name: name
                    }, this);
                },
                get: function () {
                    return this.__o__[name];
                },
                configurable: true,
                enumerable: true
            });
        }
    }
});


Object.getOwnPropertyNames(EventEmitter["b" /* default */].prototype).forEach(function (name) {
    if (!(name in ObservableStruct.prototype)) {
        Object.defineProperty(ObservableStruct.prototype, name, {
            configurable: false,
            enumerable: false,
            writable: false,
            value: EventEmitter["b" /* default */].prototype[name]
        });
    }
});

/* harmony default export */ var AppPattern_ObservableStruct = (ObservableStruct);

// EXTERNAL MODULE: ./node_modules/absol/src/Code/safeThrow.js
var safeThrow = __webpack_require__(31);

// CONCATENATED MODULE: ./node_modules/absol/src/AppPattern/circuit/CCBlock.js



/***
 *
 * @param {{id?:string}=} opt
 * @constructor
 */
function CCBlock(opt) {
    opt = opt || {};
    this.id = opt.id || Object(stringGenerate["randomIdent"])(16);
    Object.defineProperty(this, '__cc_listener__', {
        enumerable: false,
        configurable: true,
        writable: false,
        value: {}
    });

    Object.defineProperty(this, '__cc_line_list_by_id__', {
        enumerable: false,
        configurable: true,
        writable: false,
        value: {}
    });
}

/***
 *
 * @param {string} pinName
 * @param {function} listener
 * @return {CCBlock}
 */
CCBlock.prototype.pinOn = function (pinName, listener) {
    var cbList;
    if (this.__cc_listener__[pinName]) {
        cbList = this.__cc_listener__[pinName];
    } else {
        cbList = [];
        this.__cc_listener__[pinName] = cbList;

    }
    if (cbList.indexOf(listener) < 0) {
        cbList.push(listener);
    } else {
        console.warn("Duplicate pin listener!");
    }
    return this;
};

CCBlock.prototype.pinOff = function (pinName, listener) {
    if (!this.__cc_listener__[pinName]) return this;
    var cbList = this.__cc_listener__[pinName];
    var cbIdx = cbList.indexOf(listener);
    if (cbIdx >= 0) {
        cbList.splice(cbIdx);
    }
    return this;
};

CCBlock.prototype.pinFire = function (pinName) {
    if (!this.__cc_listener__[pinName]) return this;
    var cbList = this.__cc_listener__[pinName].slice();
    var args = Array.prototype.slice.call(arguments, 1);
    if (args.length === 0 && this.pinHandlers[pinName] && this.pinHandlers[pinName].get && cbList.length > 0)
        args.push(this.pinGetValue(pinName));
    for (var i = 0; i < cbList.length; ++i) {
        try {
            cbList[i].apply(this, args);
        } catch (e) {
            Object(safeThrow["a" /* default */])(e);
        }
    }
};

CCBlock.prototype.pinFireAll = function () {
    var pinNames = Object.keys(this.pinHandlers);
    var pinName;
    for (var i = 0; i < pinNames.length; ++i) {
        pinName = pinNames[i];
        if (this.pinHandlers[pinName] && this.pinHandlers[pinName].get)
            this.pinFire(pinName);
    }
};


CCBlock.prototype.pinReceives = function (pinName) {
    var args = Array.prototype.slice.call(arguments, 1);
    if (this.pinHandlers[pinName] && this.pinHandlers[pinName].receives) {
        this.pinHandlers[pinName].receives.apply(this, args);
    }
};

CCBlock.prototype.pinGetValue = function (pinName) {
    var args = Array.prototype.slice.call(arguments, 1);
    if (this.pinHandlers[pinName] && this.pinHandlers[pinName].get) {
        return this.pinHandlers[pinName].get.apply(this, args);
    }
    return undefined;
};


CCBlock.prototype.pinGetDescriptor = function (pinName) {
    var args = Array.prototype.slice.call(arguments, 1);
    var descriptor = this.pinHandlers[pinName] && this.pinHandlers[pinName].descriptor;
    if (descriptor) {
        if (typeof descriptor === "function")
            return this.pinHandlers[pinName].get.apply(this, args);
        return descriptor;
    }
    return undefined;
};

Object.defineProperty(CCBlock.prototype, 'pinLines', {
    get: function () {
        var lineList = this.__cc_line_list_by_id__;
        return Object.keys(lineList).map(function (id) {
            return lineList[id];
        });
    }
});


CCBlock.prototype.pinHandlers = {};

/* harmony default export */ var circuit_CCBlock = (CCBlock);
// CONCATENATED MODULE: ./node_modules/absol/src/AppPattern/circuit/CCLine.js



/***
 *
 * @param {CCBlock} u
 * @param {string} uPinName
 * @param {CCBlock} v
 * @param {string} vPinName
 * @param {boolean=} twoWay
 * @param {{id?:string}=} opt
 * @constructor
 */
function CCLine(u, uPinName, v, vPinName, twoWay, opt) {
    opt = opt || {};
    twoWay = !!twoWay;
    Object.defineProperty(this, 'id', {
        enumerable: true, writable: false, value: opt.id || Object(stringGenerate["randomIdent"])(32)
    });
    Object.defineProperty(this, 'u', {
        enumerable: true, writable: false, value: u
    });
    Object.defineProperty(this, 'v', {
        enumerable: true, writable: false, value: v
    });
    Object.defineProperty(this, 'uPinName', {
        enumerable: true, writable: false, value: uPinName
    });
    Object.defineProperty(this, 'vPinName', {
        enumerable: true, writable: false, value: vPinName
    });

    Object.defineProperty(this, 'twoWay', {
        enumerable: true, writable: false, value: twoWay
    });

    this.vToU = this.vToU.bind(this);
    this.uToV = this.uToV.bind(this);
    this.u.pinOn(this.uPinName, this.uToV);
    if (this.twoWay)
        this.v.pinOn(this.vPinName, this.vToU);
    this.u.__cc_line_list_by_id__[this.id] = this;
    this.v.__cc_line_list_by_id__[this.id] = this;
}


CCLine.prototype.remove = function () {
    this.u.pinOff(this.uPinName, this.uToV);
    if (this.twoWay)
        this.v.pinOff(this.vPinName, this.vToU);
    delete this.u.__cc_line_list_by_id__[this.id];
    delete this.v.__cc_line_list_by_id__[this.id];
};

CCLine.prototype.uToV = function () {
    var args = [this.vPinName].concat(Array.prototype.slice.call(arguments));
    this.v.pinReceives.apply(this.v, args);
};

CCLine.prototype.vToU = function () {
    var args = [this.uPinName].concat(Array.prototype.slice.call(arguments));
    this.u.pinReceives.apply(this.u, args);
};


/* harmony default export */ var circuit_CCLine = (CCLine);
// EXTERNAL MODULE: ./node_modules/absol/src/Network/FileSaver.js
var FileSaver = __webpack_require__(51);

// CONCATENATED MODULE: ./node_modules/absol/src/Network/RemoteThread.tpl
/* harmony default export */ var RemoteThread = ("function safeThrow(error) {\n    setTimeout(function () {\n        throw  error;\n    }, 0);\n}\n\nfunction EventEmitter() {\n    if (!this._azar_extendEvents) {\n        Object.defineProperty(this, '_azar_extendEvents', {\n            enumerable: false,\n            value: this._azar_extendEvents || { supported: {}, prioritize: {}, nonprioritize: {} }\n        });\n        Object.defineProperty(this, '__azar_force', {\n            value: true,\n            enumerable: false\n        });\n    }\n}\n\n\nEventEmitter.prototype.defineEvent = function (name) {\n    if (name instanceof Array) {\n        for (var i = 0; i < name.length; ++i)\n            this._azar_extendEvents.supported[name[i]] = true;\n    }\n    else\n        this._azar_extendEvents.supported[name] = true;\n    return this;\n};\n\nEventEmitter.prototype.isSupportedEvent = function (name) {\n    return true;\n};\n\n\nEventEmitter.prototype.emit = function (eventName, data) {\n    this.fire.apply(this, arguments);\n};\n\nEventEmitter.prototype.fire = function (eventName, data) {\n    var others = Array.prototype.slice.call(arguments, 1);\n    if (this.isSupportedEvent(eventName)) {\n        var listenerList;\n        var i;\n        if (this._azar_extendEvents.prioritize[eventName]) {\n            listenerList = this._azar_extendEvents.prioritize[eventName].slice();\n            for (i = 0; i < listenerList.length; ++i) {\n                try {\n                    listenerList[i].wrappedCallback.apply(this, others);\n                } catch (e) {\n                   safeThrow(e);\n                }\n            }\n        }\n\n        if (this._azar_extendEvents.nonprioritize[eventName]) {\n            listenerList = this._azar_extendEvents.nonprioritize[eventName].slice();\n            for (i = 0; i < listenerList.length; ++i) {\n                try {\n                    listenerList[i].wrappedCallback.apply(this, others);\n                } catch (e) {\n                    safeThrow(e);\n                }\n            }\n        }\n    }\n    else {\n        if (this.dispatchEvent) {\n            var event = new Event(eventName);\n            data && Object.assign(event, data);\n            this.dispatchEvent(event);\n        }\n        else\n            throw new Error(\"Not support event \" + eventName);\n    }\n    return this;\n};\n\n\nEventEmitter.prototype.eventEmittorOnWithTime = function (isOnce, arg0, arg1, arg2) {\n    if (typeof arg0 == 'object') {\n        for (var key in arg0) {\n            this.eventEmittorOnWithTime(isOnce, key, arg0[key]);\n        }\n        return this;\n    }\n    else {\n        if (typeof arg1 == 'object') {\n            return this.eventEmittorOnWithTime(isOnce, arg0, arg1.callback, arg1.cap);\n        }\n        else {\n            var eventArr = this._azar_extendEvents[arg2 ? 'prioritize' : 'nonprioritize'][arg0] || [];\n            var eventIndex = -1;\n            for (var i = 0; i < eventArr.length; ++i) {\n                if (eventArr[i].wrappedCallback == arg1) {\n                    eventIndex = i;\n                    break;\n                }\n            }\n            if (eventIndex < 0) {\n                var event = { isOnce: isOnce, eventName: arg0, callback: arg1, cap: !!arg2 };\n                //wrappedCallback will be call\n                if (isOnce) {\n                    event.wrappedCallback = function () {\n                        event.callback.apply(this, arguments);\n                        this.off(event.eventName, event.wrappedCallback, event.cap);\n                    };\n                }\n                else {\n                    event.wrappedCallback = event.callback;\n                }\n\n                if (!this.isSupportedEvent(arg0)) {\n                    if (this.addEventListener) {\n                        this.addEventListener(arg0, event.wrappedCallback, !!arg2);\n                    }\n                    else {\n                        this.attachEvent('on' + arg0, arg1, !!arg2);\n                    }\n                }\n\n                eventArr.push(event);\n                this._azar_extendEvents[arg2 ? 'prioritize' : 'nonprioritize'][arg0] = eventArr;\n            }\n            else {\n                console.warn(\"dupplicate event\");\n            }\n\n        }\n        return this;\n    }\n};\n\n\nEventEmitter.prototype.on = function (arg0, arg1, arg2) {\n    this.eventEmittorOnWithTime(false, arg0, arg1, arg2);\n    return this;\n};\n\n\nEventEmitter.prototype.once = function (arg0, arg1, arg2) {\n    this.eventEmittorOnWithTime(true, arg0, arg1, arg2);\n    return this;\n};\n\nEventEmitter.prototype.off = function (arg0, arg1, arg2) {\n    if (typeof arg0 == 'object') {\n        for (var key in arg0) {\n            this.off(key, arg0[key]);\n        }\n        return this;\n    }\n    else {\n        if (typeof arg1 == 'object') {\n            return this.off(arg0, arg1.callback, arg1.cap);\n        }\n        else {\n            var eventArr = this._azar_extendEvents[arg2 ? 'prioritize' : 'nonprioritize'][arg0] || [];\n            var newEventArray = [];\n            for (var i = 0; i < eventArr.length; ++i) {\n                var event = eventArr[i];\n                if (event.wrappedCallback == arg1) {\n                    //Dont add to newEventArray\n                    if (this.isSupportedEvent(arg0)) {\n                    }\n                    else {\n                        if (this.removeEventListener) {\n                            this.removeEventListener(event.eventName, event.wrappedCallback, !!event.cap);\n                        }\n                        else {\n                            this.detachEvent('on' + event.eventName, event.wrappedCallback, !!event.cap);\n                        }\n                    }\n                }\n                else {\n                    newEventArray.push(event);\n                }\n            }\n            this._azar_extendEvents[arg2 ? 'prioritize' : 'nonprioritize'][arg0] = newEventArray;\n            return this;\n        }\n    }\n\n};\n\n\n/**\n *\n * @param {Worker} host\n */\nfunction IFrameBridge(host, origin) {\n    EventEmitter.call(this);\n    this.detach();\n    this.origin = origin;\n    if (host) this.attach(host);\n    this.__azarResolveCallbacks = {};\n}\n\nIFrameBridge.prototype.attach = function (host) {\n    this.host = host;\n    if (this.host.addEventListener) {\n        this.host.addEventListener(\"message\", this.__azarMessageListener.bind(this), false);\n    }\n    else if (this.host.attachEvent) {\n        this.host.attachEvent(\"onmessage\", this.__azarMessageListener.bind(this));\n    }\n    else {\n        this.host.onmessage = this.__azarMessageListener.bind(this);\n    }\n    this.__IFrameBridge_resolve();\n};\n\nIFrameBridge.prototype.detach = function () {\n    this.sync = new Promise(function (resolve) {\n        this.__IFrameBridge_resolve = resolve;\n    }.bind(this));\n};\n\nObject.defineProperties(IFrameBridge.prototype, Object.getOwnPropertyDescriptors(EventEmitter.prototype));\nIFrameBridge.prototype.constructor = IFrameBridge;\n\nIFrameBridge.prototype.__azarMessageListener = function (event) {\n    this.__azarHandleData(event.data);\n};\n\n\nIFrameBridge.prototype.__azarHandleData = function (data) {\n    if (data.type) {\n        if (data.type == \"INVOKE\") {\n            try {\n                var result = this.__azarSelfInvoke(data.name, data.params);\n                if (result && typeof result.then == 'function') {\n                    result.then(function (result) {\n                        this.__azarResolve(data.taskId, result);\n                    }.bind(this))\n                        .catch(function (err) {\n                            console.error(err);\n                            this.__azarResolve(data.taskId, null, { message: err.message, stack: err.stack });\n                        }.bind(this));\n                }\n                else {\n                    this.__azarResolve(data.taskId, result);\n                }\n            } catch (err) {\n                console.error(err);\n                this.__azarResolve(data.taskId, null, { message: err.message, stack: err.stack });\n            }\n\n\n        }\n        else if (data.type == \"INVOKE_RESULT\") {\n            if (this.__azarResolveCallbacks[data.taskId]) {\n                if (data.error) {\n                    this.__azarRejectCallbacks[data.taskId](data.error);\n                }\n                else {\n                    this.__azarResolveCallbacks[data.taskId](data.result);\n                }\n                delete this.__azarResolveCallbacks[data.taskId];\n                delete this.__azarRejectCallbacks[data.taskId];\n            }\n        }\n        else if (data.type == \"EMIT\") {\n            this.fire.apply(this, data.params);\n        }\n        else this.fire('message', data, this);\n    }\n};\n\n\nIFrameBridge.prototype.__azarResolve = function (taskId, result, error) {\n    var data = {\n        type: \"INVOKE_RESULT\",\n        taskId: taskId,\n        result: result,\n        error: error\n    };\n\n    if (this.origin) {\n        this.host.postMessage(data, this.origin);\n    }\n    else {\n        this.host.postMessage(data);\n    }\n};\n\n\nIFrameBridge.prototype.__azarSelfInvoke = function (name, params) {\n    if (typeof this[name] == 'function') {\n        return this[name].apply(this, params);\n    }\n    else {\n        return this[name];\n    }\n};\n\n\nIFrameBridge.prototype.emit = function () {\n    var params = [];\n    params.push.apply(params, arguments);\n    this.sync.then(function () {\n        var data = {\n            type: \"EMIT\",\n            params: params\n        };\n        if (this.origin) {\n            this.host.postMessage(data, this.origin);\n        }\n        else {\n            this.host.postMessage(data);\n        }\n    }.bind(this));\n    return this;\n};\n\n\nIFrameBridge.prototype.invoke = function (name) {\n    var params = [];\n    params.push.apply(params, arguments);\n    params.shift();\n    return this.sync.then(function () {\n        var indent = randomIdent(32);\n        var data = {\n            type: 'INVOKE',\n            params: params,\n            taskId: indent,\n            name: name\n        };\n        if (this.origin) {\n            this.host.postMessage(data, this.origin);\n        }\n        else {\n            this.host.postMessage(data);\n        }\n        return new Promise(function (resolve) {\n            this.__azarResolveCallbacks[indent] = resolve;\n        }.bind(this));\n    }.bind(this));\n};\n\nIFrameBridge.prototype.importScriptURLs = function () {\n    return this.invoke.apply(this, ['_receiveScriptURLs'].concat(Array.prototype.slice.call(arguments)));\n};\n\nIFrameBridge.prototype._receiveScriptURLs = function () {\n    if (self.importScripts) {\n        self.importScripts.apply(self, arguments);\n    }\n};\n\n\nIFrameBridge.prototype._receiveMethod = function (name, code) {\n    this[name] = (new Function('return ' + code))();\n};\n\nObject.defineProperties(self, Object.getOwnPropertyDescriptors(IFrameBridge.prototype));\nIFrameBridge.call(self, self);");
// CONCATENATED MODULE: ./node_modules/absol/src/Network/Thread.js




/***
 *
 * @param {{methods?:Object, extendCode: string}} opt
 * @constructor
 */
function Thread(opt) {
    this.worker = new Worker(this._makeCodeUrl(opt));
    IFrameBridge["a" /* default */].call(this, this.worker);
    this._attachClientMethods(opt.methods);
}

Thread.prototype._makeCodeUrl = function (opt) {
    var code = [
        this._makeLibCode(opt.libs),
        RemoteThread,
        this._makeMethodCode(opt.methods),
        this._makePropCode(opt.props),
        opt.extendCode || '',
    ].join('\n\n');
    var blob = new Blob([code], { type: 'application/javascript' });
    var url = URL.createObjectURL(blob);
    return url;
};

Thread.prototype._makePropCode = function (props) {
    if (!props) return '';
    return 'Object.assign(self, ' + JSON.stringify(props) + ');';
};

Thread.prototype._makeLibCode = function (libs) {
    if (!libs) return '';
    return libs.map(function (lib) {
        return 'self.importScripts(' + JSON.stringify(lib) + ');'
    }).join('\n');
}

Thread.prototype._makeMethodCode = function (methods) {
    if (!methods) return '';
    return Object.keys(methods).map(function (key) {
        var fx = methods[key];
        if (typeof fx === "function") {
            fx = fx.toString();
            return 'self[' + JSON.stringify(key) + '] = ' + fx;
        }
    }).join('\n\n');
};

Thread.prototype._attachClientMethods = function (methods) {
    if (!methods) return '';
    Object.keys(methods).reduce(function (ac, name) {
        ac[name] = function () {
            return this.invoke.apply(this, [name].concat(Array.prototype.slice.call(arguments)))
        }
        return ac;
    }, this);
};


OOP["a" /* default */].mixClass(Thread, IFrameBridge["a" /* default */]);

/* harmony default export */ var Network_Thread = (Thread);
// CONCATENATED MODULE: ./node_modules/absol/src/JSMaker/generator.js
function generateJSVariable(obj, indent) {
    indent = indent || '';
    var childIndent = indent + '    ';
    if (obj === null) {
        return 'null';
    } else if (obj instanceof Array) {
        if (obj.length === 0)
            return '[]';
        return '[\n'
            + obj.map(function (it) {
                return childIndent + generateJSVariable(it, childIndent);
            }).join(',\n')
            + '\n' + indent + ']';
    } else if (typeof obj === 'object') {
        var keys = Object.keys(obj);
        if (keys.length === 0) return '{}';
        return '{\n'
            + keys.map(function (key) {
                var value = obj[key];
                if (!key.match(/^[a-zA-Z_$]([a-zA-Z_0-9$]*)$/)) key = JSON.stringify(key);
                return childIndent + key + ': ' + generateJSVariable(value, childIndent)
            }).join(',\n')
            + '\n' + indent + '}';
    } else if (obj === undefined) {
        return 'undefined';
    } else {
        return JSON.stringify(obj);
    }
}
// CONCATENATED MODULE: ./node_modules/absol/src/AppPattern/ShareConfiguration.js


function ShareConfiguration() {
    Object.defineProperty(this, 'data', {
        value: {},
        enumerable: true,
        writable: false
    });

    Object.defineProperty(this, '__listener__', {
        value: {},
        enumerable: false,
        writable: false
    })
}

/***
 *
 * @param {string} key
 * @param {*|undefined} value
 */
ShareConfiguration.prototype.set = function (key, value) {
    var prev = this.data[key];
    this.data[key] = value;
    if (value !== prev) {
        this.emit(key, value, this);
    }
    return this;
};

ShareConfiguration.prototype.emit = function (key) {
    var args = Array.prototype.slice.call(arguments, 1);
    var self = this;
    if (this.__listener__[key]) {
        this.__listener__[key].slice().forEach(function (f) {
            try {
                f.apply(self, args);
            } catch (err) {
               Object(safeThrow["a" /* default */])(err);
            }
        });
    }
    return this;
};

/***
 *
 * @param {string|Object} key
 * @param {function=}listener
 * @return {ShareConfiguration}
 */
ShareConfiguration.prototype.on = function (key, listener) {
    if (typeof key === "string") {
        if (!this.__listener__[key]) this.__listener__[key] = [];
        if (this.__listener__[key].indexOf(listener) < 0) {
            this.__listener__[key].push(listener);
        }
    } else if (typeof key === "object") {
        for (var key1 in key) {
            this.on(key1, key[key1]);
        }
    }
    return this;
};

/***
 *
 * @param {string|Object} key
 * @param {function=}listener
 * @return {ShareConfiguration}
 */
ShareConfiguration.prototype.off = function (key, listener) {
    if (typeof key === "string" && this.__listener__[key]) {
        var idx = this.__listener__[key].indexOf(listener);
        if (idx >= 0) {
            this.__listener__[key].splice(idx, 1);
        }
    } else if (typeof key === "object") {
        for (var key1 in key) {
            this.off(key1, key[key1]);
        }
    }
    return this;
};

/***
 *
 * @param {string} key
 * @param {*=} defaultValue
 * @return {*}
 */
ShareConfiguration.prototype.get = function (key, defaultValue) {
    return this.data[key];
};

ShareConfiguration.prototype.contains = function (key) {
    return this.data[key] === undefined;
};

ShareConfiguration.instance = new ShareConfiguration();

/* harmony default export */ var AppPattern_ShareConfiguration = (ShareConfiguration);
// CONCATENATED MODULE: ./node_modules/absol/src/index.js




































































var src_absol = {
    int: Math_int,
    safeThrow: safeThrow["a" /* default */],
    Rectangle: Rectangle["a" /* default */],
    ResizeSystem: ResizeSystem["a" /* default */],
    Arc: Math_Arc,
    NumRange: Math_NumRange,
    CookieStore: Cookie_CookieStore,
    parseCookieString: parseCookieString,
    CMDRunner: CMDRunner["a" /* default */],
    ContextManager: AppPattern_ContextManager,
    Application: AppPattern_Application,
    Fragment: AppPattern_Fragment,
    VarScope: AppPattern_VarScope,
    Context: AppPattern_Context,
    Activity: AppPattern_Activity,
    Element: Element["a" /* default */],
    ElementNS: AElementNS["a" /* default */],
    AElement: Element["a" /* default */],
    AElementNS: AElementNS["a" /* default */],
    DomSignal: DomSignal["a" /* default */],
    JSPath: JSPath["a" /* default */],
    TemplateString: TemplateString["a" /* default */],
    TemplateXML: JSMaker_TemplateXML,
    Dom: Dom["b" /* default */],
    Svg: Svg["a" /* default */],
    BrowserDetector: BrowserDetector["a" /* default */],
    OOP: OOP["a" /* default */],
    XML: XML_XML,
    Color: Color["a" /* default */],
    EventEmitter: EventEmitter["b" /* default */],
    JSZip: window.JSZip,
    IFrameBridge: IFrameBridge["a" /* default */],
    JSDocx: JSDocx["a" /* default */],
    Broadcast: Network_Broadcast,
    text: Text,
    file: file,
    base64: base64_namespaceObject,
    Alarm: Time_Alarm,
    coreDom: Dom["b" /* default */].ShareInstance,
    coreSvg: Svg["a" /* default */].ShareInstance,
    require: function (tagName) {
        return this.coreDom.require(tagName) || this.coreSvg.require(tagName);
    },
    domCreator: Dom["b" /* default */].ShareInstance.creator,
    svgCreator: Dom["b" /* default */].ShareInstance.creator,
    _: Dom["b" /* default */].ShareInstance._,
    $: Dom["b" /* default */].ShareInstance.$,
    $$: Dom["b" /* default */].ShareInstance.$$,
    _svg: Svg["a" /* default */].ShareInstance._,
    $svg: Svg["a" /* default */].ShareInstance.$,
    Ref: Ref["a" /* default */],
    XHR: XHR["a" /* default */],
    string: Object.assign({}, stringFormat, stringGenerate),
    jsx: {
        dom: dom_namespaceObject,
        attribute: JSX_attribute
    },

    clipboard: Clipboard_namespaceObject,
    dataStructure: { Heap: DataStructure_Heap },
    datetime: datetime,
    Vec2: Vec2["a" /* default */],
    Mat3: Math_Mat3,
    LanguageSystem: LanguageSystem["a" /* default */],
    ALogger: ALogger["a" /* default */],
    FlagManager: FlagManager["a" /* default */],
    ObservableArray: AppPattern_ObservableArray,
    ObservableStruct: AppPattern_ObservableStruct,
    circuit: {
        CCBlock: circuit_CCBlock,
        CCLine: circuit_CCLine
    },
    FileSaver: FileSaver,
    Thread: Network_Thread,
    generateJSVariable: generateJSVariable,
    normalizeIdent: stringFormat["normalizeIdent"],
    shareConfiguration: AppPattern_ShareConfiguration.instance
};



/* harmony default export */ var src = (src_absol);
// CONCATENATED MODULE: ./node_modules/absol/src/absol.js




//for old plugin
src['HTML'+'El'+'ement'.toLowerCase()] = src.Element;
src.dom = src.Dom;
src.event = src.EventEmitter;
src.Event = src.EventEmitter;
src.color = src.Color;
src.documentReady = src.Dom.documentReady;
window.AComp = src.AComp;
window.PhotoSwipeViewer = src.PhotoSwipeViewer;
window.IFrameBridge = src.IFrameBridge;
window.absol = src;

var mapKeys = {
    ShareDom: 'coreDom',
    ShareDomCreator: 'domCreator',
    ShareSvgC: 'coreSvgCreator',
    ShareSvgCreator: 'svgCreator',
    ShareCreator: 'domCreator'
};

src.logData = [];
src.log = function () {
    src.logData.push([new Error('TraceError')].concat(Array.prototype.slice.call(arguments)))
}

Object.keys(mapKeys).forEach(function (key) {
    var valueKey = mapKeys[key];
    Object.defineProperty(src, key, {
        get: function () {
            if (!this['__warn' + key + '__']) {
                this['__warn' + key + '__'] = true;
                src.log("use " + valueKey + ' instead of ' + key);
            }
            return this[valueKey];
        }
    });
});

/**
 * @deprecated
 * @param {string|Array} className
 * @returns {Boolean}
 */
AElement["a" /* default */].prototype.containsClass = function (className) {
    if (className.forEach && className.map) {
        for (var i = 0; i < className.length; ++i)
            if (!this.classList.containsClass(className[i])) return false;
        return true;
    }
    else
        return this.classList.contains(className);
};
// CONCATENATED MODULE: ./node_modules/absol/src/polyfill.js

// EXTERNAL MODULE: ./node_modules/absol-acomp/ACore.js
var ACore = __webpack_require__(0);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/adapter/MaterialDesignIconsAdapter.js
/***
 * Old name to new name
 */



var MaterialDesignIconsNameMap = {
    'settings-outline': 'cog-outline',
    'contact-mail': 'card-account-mail',
};

var MaterialDesignIconsCode = {};

Dom["b" /* default */].documentReady.then(function () {
    var _ = ACore["d" /* default */]._;
    var a = _({
        tag: 'span',
        class: ['mdi'],
        style: {
            display: 'none'
        }
    }).addTo(document.body);
    var content;
    var cssCodeLines = [];
    for (var oldName in MaterialDesignIconsNameMap) {
        a.addClass('mdi-' + MaterialDesignIconsNameMap[oldName]);
        content = getComputedStyle(a, '::before').content;
        MaterialDesignIconsCode[oldName] = content;
        cssCodeLines.push('.mdi-' + oldName + '::before{content:' + content + '}');
        a.removeClass('mdi-' + MaterialDesignIconsNameMap[oldName]);
    }

    a.remove();

    var styleElt = _({
        tag: 'style',
        props: {
            innerHTML: cssCodeLines.join('\n')
        }
    }).addTo(document.head);
});

// EXTERNAL MODULE: ./node_modules/absol-acomp/AComp.js
var AComp = __webpack_require__(78);

// EXTERNAL MODULE: ./node_modules/absol/src/String/stringMatching.js
var stringMatching = __webpack_require__(39);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/keeview.css
var keeview = __webpack_require__(328);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/QuickMenu.js
var QuickMenu = __webpack_require__(27);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/ChromeCalendar.js
var ChromeCalendar = __webpack_require__(32);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Radio.js
var Radio = __webpack_require__(73);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/EmojiChars.js
var EmojiChars = __webpack_require__(79);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/EmojiAnims.js
var EmojiAnims = __webpack_require__(33);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/MessageInput.js + 1 modules
var MessageInput = __webpack_require__(37);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/EmojiPicker.js
var EmojiPicker = __webpack_require__(38);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/ContextMenu.js
var ContextMenu = __webpack_require__(43);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Searcher.js
var Searcher = __webpack_require__(67);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/utils.js
var utils = __webpack_require__(4);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/materializeIconTrigger.js




function materializeIconTrigger() {
    Dom["b" /* default */].documentReady.then(function () {
        var linkMaterial = ACore["d" /* default */].$('link', document.head, function (elt) {
            if (elt.href && elt.href.indexOf('Material+Icons')) return true;
        });
        if (!linkMaterial) return;
        var checkInv = -1;

        function onLoaded() {
            if (checkInv > 0) {
                clearTimeout(checkInv);
                checkInv = -1;
            }
            linkMaterial.off('loaded', onLoaded)
                .off('load', onLoaded)
                .off('error', onLoaded);
            i.remove();

            requestAnimationFrame(function () {
                ResizeSystem["a" /* default */].update();
                if (document.cookie.indexOf('absol_debug') >= 0) {
                    console.info('Resize after MaterialIcons load');
                }
            });
        }

        linkMaterial.on('loaded', onLoaded)
            .on('load', onLoaded)
            .on('error', onLoaded);
        var i = ACore["d" /* default */]._({
            tag: 'i',
            class:"material-icons",
            style: {
                fontSize: '14px',
                position: 'fixed',
                top: '0',
                left: '0',
                zIndex: '-1000',
                visibility: 'hidden'
            },
            child: { text: 'account_balance_wallet' }
        }).addTo(document.body);
        var iBox = i.getBoundingClientRect();
        if (iBox.width < iBox.height * 3) {
            onLoaded();
            return;
        }
        var intervalCount = 50;
        checkInv = setInterval(function () {
            intervalCount--;
            if (intervalCount < 0) {
                onLoaded();
            }
            iBox = i.getBoundingClientRect();
            if (iBox.width < iBox.height * 3) {
                onLoaded();
            }
        }, 200);
    });
}


// EXTERNAL MODULE: ./node_modules/absol-acomp/js/VariantColors.js
var VariantColors = __webpack_require__(54);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Tooltip.js
var Tooltip = __webpack_require__(28);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TextMeasureData.js
/* harmony default export */ var TextMeasureData = ({
    chars: (" !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~©´ÀÁÂÊÍÒÔÙÚ" +
        "ÝàáâãèéêìíðòóôõùúýĂăĐđĩũƠơƯưɐɔɕɗəɛɡɣɲʃʒʝʰˆː˘̪̀̃͡τφχẠạẢảẤấẦầẩẫẬậắằẳặẸẹẻẽếỀềểễỆệỉịọỏỐốồổỗỘộỚớỜờởỡỢợụỦủỨứỪừửữựỳỷỹ" +
        "–‘“”…♥♪【】🤣️�").split(''),
    fonts: {
        "Times New Roman": {
            "width": {
                "0": "̪̀̃͡️",
                "5": " ,.",
                "10": "0123456789#$*_bdghknopquvxyðòóôõùúýđũɗɡɣɲọỏốồổỗộụủỳỷỹ–♪",
                "20": "…【】",
                "6.66015625": "!()-I[]`fr´Íʃˆ˘‘",
                "8.1640625": "\"",
                "16.66015625": "%",
                "15.556640625": "&m",
                "3.603515625": "'",
                "11.279296875": "+<=>",
                "5.556640625": "/:;\\ijltìíĩʝːỉị",
                "8.876953125": "?acezàáâãèéêăɐɔɕəʒχạảấầẩẫậắằẳặẹẻẽếềểễệ“”",
                "18.41796875": "@",
                "14.443359375": "ADGHKNOQUVXYwÀÁÂÒÔÙÚÝĂĐƠẠẢẤẦẬỐỘỚỜỢỦ",
                "13.33984375": "BCR",
                "12.216796875": "ELTZÊẸỀỆ",
                "11.123046875": "FPS",
                "7.783203125": "Js",
                "17.783203125": "M",
                "18.876953125": "W",
                "9.384765625": "^",
                "9.599609375": "{}",
                "4.00390625": "|",
                "10.8203125": "~",
                "15.1953125": "©",
                "10.576171875": "ơớờởỡợ",
                "15.517578125": "ƯỨỪ",
                "10.83984375": "ưứừửữự",
                "8.3984375": "ɛ",
                "6.42578125": "ʰ",
                "8.037109375": "τ",
                "11.54296875": "φ",
                "11.875": "♥",
                "19.423828125": "🤣�"
            },
            "spacing": {
                "-0.7421875": "11W:W;",
                "-2.216796875": "ATP,P.VaVeVyWAY-YAYqYu",
                "-2.578125": "AVV,V.VAVoY,Y.",
                "-1.6015625": "AWF,F.RVTAWaWeWo",
                "-1.8359375": "AYAwAyLTLVPAT-V-W,W.Y:Y;Yp",
                "-1.484375": "AvFALWT,T.V:V;‘‘",
                "-2.001953125": "LYYaYeYoYv",
                "-1.103515625": "LyRWRYT;W-Yir.",
                "-1.201171875": "RTViVrVuWy",
                "-0.80078125": "RyWiWrWur,",
                "-0.99609375": "T:",
                "-0.361328125": "TOffrg",
                "-1.396484375": "TaTcTeToTsTwTy",
                "-0.703125": "TiTrTu",
                "-0.400390625": "r-",
                "-1.298828125": "v,v.w,w.y,y.",
                "-0.439453125": "χφ",
                "-4.443359375": "【̀【̃【̪【͡】̀】̃】̪】͡",
                "-11.38671875": "🤣"
            },
            "fontBoundingBoxAscent": 18,
            "fontBoundingBoxDescent": 4
        },
        "Arial": {
            "width": {
                "0": "̪̀̃͡️",
                "10": "Jcksvxyzýɔɕỳỷỹ♪",
                "20": "…【】",
                "11.123046875": "0123456789#$?L_abdeghnopquàáâãèéêðòóôõùúăđũɐɗəɡɲạảấầẩẫậắằẳặẹẻẽếềểễệọỏốồổỗộụủ–",
                "5.556640625": " !,./:;I[\\]ftÍìíĩː",
                "7.099609375": "\"",
                "17.783203125": "%",
                "13.33984375": "&ABEKPSVXYÀÁÂÊÝĂẠẢẤẦẬẸỀỆ",
                "3.818359375": "'",
                "6.66015625": "()-`r´ˆ˘“”",
                "7.783203125": "*",
                "11.6796875": "+<=>~",
                "20.302734375": "@",
                "14.443359375": "CDHNRUwÙÚĐỦ",
                "12.216796875": "FTZ",
                "15.556640625": "GOQÒÔỐỘ",
                "16.66015625": "Mm",
                "18.876953125": "W",
                "9.384765625": "^",
                "4.443359375": "ijlʃỉị‘",
                "6.6796875": "{}",
                "5.1953125": "|",
                "14.736328125": "©",
                "17.1484375": "ƠỚỜỢ",
                "13.115234375": "ơớờởỡợ",
                "17.080078125": "ƯỨỪ",
                "13.388671875": "ưứừửữự",
                "9.169921875": "ɛ",
                "10.01953125": "ɣ",
                "10.8984375": "ʒ",
                "7.94921875": "ʝ",
                "7.666015625": "ʰ",
                "7.900390625": "τ",
                "12.96875": "φ",
                "10.498046875": "χ",
                "11.875": "♥",
                "19.423828125": "🤣�"
            },
            "spacing": {
                "-1.484375": "11ATAVAYLTLVLWLYPATAVAVaYAYaYpv,v.y,y.",
                "-0.7421875": "AWLyTiTrTuV:V;VrVuVyWAWaYi",
                "-0.361328125": "AvAwAyRTRVRWRYTOViW-W:W;WeWoWrWuff‘‘",
                "-2.216796875": "F,F.T,T.T:T;TaTcTeToTs",
                "-1.103515625": "FAT-TwTyV-VeVoW,W.Y:YuYvr,r.w,w.",
                "-2.578125": "P,P.Y,Y.",
                "-1.8359375": "V,V.Y-YeYoYq",
                "-0.17578125": "Wy",
                "-1.298828125": "Y;",
                "1.11328125": "ìĩ",
                "-0.283203125": "τφφτ",
                "-0.537109375": "φχχφ",
                "-5": "【̀【̃【̪【͡】̀】̃】̪】͡",
                "-11.38671875": "🤣"
            },
            "fontBoundingBoxAscent": 18,
            "fontBoundingBoxDescent": 4
        }
    }
});

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/TextMeasure.js


function TextMeasure() {
    this.$canvas = null;
    this.data = {};
    this._loadComputedData();
    // if the font is not in data, create it and copy console log to TextMeasureData.js
    // this._makeFontSize('Times New Roman');
    // this._makeFontSize('Arial');
}

TextMeasure.prototype._loadComputedData = function () {
    var thisO = this;
    this.data.chars = TextMeasureData.chars;
    this.data.fonts = Object.keys(TextMeasureData.fonts).reduce(function (ac, fontName) {
        var font = TextMeasureData.fonts[fontName];
        ac[fontName] = {
            width: thisO._valueDict2KeyDict(font.width),
            spacing: thisO._valueDict2KeyDict(font.spacing, 2),
            fontBoundingBoxAscent: font.fontBoundingBoxAscent,
            fontBoundingBoxDescent: font.fontBoundingBoxDescent
        }
        return ac;
    }, {});
};

TextMeasure.prototype._valueDict2KeyDict = function (dict, keyLength) {
    var thisO = this;
    return Object.keys(dict).reduce(function (ac, valueText) {
        var keys = thisO._splitKey(dict[valueText], keyLength || 1);
        var value = parseFloat(valueText);
        keys.reduce(function (ac1, key) {
            ac1[key] = value;
            return ac1;
        }, ac);
        return ac;
    }, {});
};

TextMeasure.prototype._keyDic2ValueDict = function (keyDict) {
    return Object.keys(keyDict).reduce(function (ac, cr) {
        var vKey = keyDict[cr].toString();
        ac[vKey] = ac[vKey] || '';
        ac[vKey] += cr;
        return ac;
    }, {});
}

/***
 *
 * @param s
 * @param l
 * @returns {string[]}
 * @private
 */
TextMeasure.prototype._splitKey = function (s, l) {
    var cArr = s.split('');
    if (!l || l < 2) return cArr;
    return cArr.reduce(function (ac, cr) {
        ac.last += cr;
        if (ac.last.length >= l) {
            ac.arr.push(ac.last);
            ac.last = '';
        }
        return ac;
    }, { arr: [], last: '' }).arr;
};

TextMeasure.prototype._array2keyDict = function (arrKey, arrVal) {
    return arrKey.reduce(function (ac, cr, i) {
        ac[cr] = arrVal[i]
        return ac;
    }, {})
};

TextMeasure.prototype._makeFontSize = function (fontName) {
    var thisO = this;
    var charList = TextMeasureData.chars;
    var fontMt = this.measureTextByCanvas("demo-abgH", '20px ' + fontName);
    var cWidthArr = charList.map(function (c) {
        return thisO.measureTextByCanvas(c).width;
    });
    var width = this._array2keyDict(charList, cWidthArr);
    var spacing = charList.reduce(function (ac, c1, i1) {
        return charList.reduce(function (ac1, c2, i2) {
            var d = thisO.measureTextByCanvas(c1 + c2).width - cWidthArr[i1] - cWidthArr[i2];
            if (d !== 0)
                ac1[c1 + c2] = d;
            return ac1;
        }, ac);
    }, {});

    TextMeasureData[fontName] = {
        width: thisO._keyDic2ValueDict(width),
        spacing: thisO._keyDic2ValueDict(spacing),
        fontBoundingBoxAscent: fontMt.fontBoundingBoxAscent,
        fontBoundingBoxDescent: fontMt.fontBoundingBoxDescent
    };

    this.data.fonts[fontName] = {
        width: width,
        spacing: spacing,
        fontBoundingBoxAscent: fontMt.fontBoundingBoxAscent,
        fontBoundingBoxDescent: fontMt.fontBoundingBoxDescent
    };

    // copy from console and paste it to TextMeasureData
    // console.log(fontName+":"+JSON.stringify(this.data.fonts[fontName]));
};

/***
 *
 * @param {string} text
 * @param {string} fontName
 * @param {number} fontSize
 * @return {number}
 */
TextMeasure.prototype.measureWidth = function (text, fontName, fontSize) {
    var width = this.data.fonts[fontName].width;
    var spacing = this.data.fonts[fontName].spacing;
    var res = 0;
    var prevC = text[0];
    var c = text[0];
    res += width[c] || 0;
    for (var i = 1; i < text.length; ++i) {
        c = text[i];
        res += spacing[prevC + c] || 0;
        res += width[c] || 0;
        prevC = c;
    }
    return res * fontSize / 20;
}

/***
 *
 * @param {string}text
 * @param {string=} font - without font-size, default is 20px
 * @returns {TextMetrics}
 */
TextMeasure.prototype.measureTextByCanvas = function (text, font) {
    if (!document || !document.createElement) throw new Error("Not support renderer!");
    var canvas = this.$canvas || (this.$canvas = document.createElement("canvas"));
    var context = canvas.getContext("2d");
    if (font)
        context.font = font;
    var metrics = context.measureText(text);
    return metrics;
};


/* harmony default export */ var js_TextMeasure = (new TextMeasure());

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/BContextCapture.js







/***
 * simple way, to replace old ContextCapture version
 ***/

function BContextCapture() {
    EventEmitter["b" /* default */].call(this);
    this.sync = Promise.resolve();
    this.$root = null;
    this._pointerSession = 0;
    this.ev_contextMenu = this.ev_contextMenu.bind(this);
}

OOP["a" /* default */].mixClass(BContextCapture, EventEmitter["b" /* default */]);

BContextCapture.prototype.attachTo = function (elt) {
    if (this.$root) this.$root.removeEventListener('contextmenu', this.ev_contextMenu, false);
    this.$root = elt;
    if (this.$root) this.$root.addEventListener('contextmenu', this.ev_contextMenu, false);
}

BContextCapture.prototype.auto = function () {
    Dom["b" /* default */].documentReady.then(function () {
        this.attachTo(document.body);
    }.bind(this));
};


BContextCapture.prototype.showContextMenu = ContextMenu["a" /* default */].prototype.showContextMenu;
BContextCapture.prototype._fireContextMenuEvent = ContextMenu["a" /* default */].prototype._fireContextMenuEvent;
BContextCapture.prototype._checkNeedHandle = ContextMenu["a" /* default */].prototype._checkNeedHandle;
/***
 *
 * @param {PointerEvent} event
 */
BContextCapture.prototype.ev_contextMenu = function (event) {
    this._pointerSession++;
    this._posCurrent = new Vec2["a" /* default */](event.clientX, event.clientY);
    this.$target = event.target;
    if (this._checkNeedHandle(event.target)) {
        if (this._fireContextMenuEvent()) {
            event.preventDefault();
        }
    }
};

var instance = new BContextCapture();
if ((!BrowserDetector["a" /* default */].isMobile || !BrowserDetector["a" /* default */].isSafari) && (BrowserDetector["a" /* default */].os.type !== 'ios')) {
    BrowserDetector["a" /* default */].nativeContextMenuSupport = true;
    ContextMenu["a" /* default */].auto = instance.auto.bind(instance);//override old version
}
else {
    BrowserDetector["a" /* default */].nativeContextMenuSupport = false;
}


/* harmony default export */ var js_BContextCapture = (instance);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/CPUViewer.js
var CPUViewer = __webpack_require__(23);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/list/ListDictionary.js
/***
 * usage: HR
 */
/***
 *
 * @param {Array<SelectionItem>} arr
 * @constructor
 */
function ItemDictionary(arr) {
    this.arr = arr;
    this.dict = {};
    this.dupKeys = [];
    this.update();
}

ItemDictionary.prototype.update = function () {
    this.dict = {};
    var dict = this.dict;
    var item;

    var dupKeyDict = {};

    function scan(arr) {
        for (var i = 0; i < arr.length; ++i) {
            item = arr[i];
            if (dict[item.value]) {
                dict[item.value].dupItems = dict[item.value].dupItems || [];
                dict[item.value].dupItems.push(item);
                dupKeyDict[item.value] = 1;
            }
            else {
                dict[item.value] = {
                    idx: i,
                    item: item
                };
            }
            if (item.items  && item.items.length > 0){
                scan( item.items);
            }
        }
    }

    scan(this.arr);
    this.dupKeys = Object.keys(dupKeyDict);
};

/***
 *
 * @param {String | Number} value
 * @returns {SelectionItem | null}
 */
ItemDictionary.prototype.getItemByValue = function (value) {
    var iDict = this.dict[value];
    if (iDict) return iDict.item;
    return null;
};

/***
 *
 * @param {String | Number} value
 * @returns {Array<SelectionItem> }
 */
ItemDictionary.prototype.getAllItemByValue = function (value) {
    var iDict = this.dict[value];
    if (iDict) return [iDict.item].concat(iDict.dupItems || []);
    return [];
};

ItemDictionary.prototype.getDuplicateKeys = function () {
    return this.dupKeys;
};

/* harmony default export */ var ListDictionary = (ItemDictionary);

// EXTERNAL MODULE: ./node_modules/absol-acomp/css/keeview/overviewwidget.css
var overviewwidget = __webpack_require__(330);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/TabView.js + 2 modules
var TabView = __webpack_require__(82);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Hanger.js
var Hanger = __webpack_require__(29);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/OnScreenWidget.js
var OnScreenWidget = __webpack_require__(74);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/keeview/OverviewWidget.js














/***
 * @extends Fragment
 * @param {{}} host
 * @param {Fragment[]} children
 * @constructor
 */
function OverviewWidget(host, children) {
    AppPattern_Fragment.call(this);
    this.setting = {
        viewPos: { x: 0, y: 0 },
        minimize: true
    };
    this.host = host;
    this.children = children || [];

    this.childrenById = this.children.reduce(function (ac, child) {
        ac[child.id] = child;
        return ac;
    }, {});
    this._position = new Vec2["a" /* default */](0, 0);
    this.setContext("OVERVIEW_WIDGET", this);
    this.children.forEach(function (fg) {
        fg.attach(this);
    }.bind(this));
}

OOP["a" /* default */].mixClass(OverviewWidget, AppPattern_Fragment);

OverviewWidget.prototype.createView = function () {
    this.$title = Object(ACore["c" /* _ */])({
        tag: 'span',
        class: 'kv-overview-widget-title',
        child: { text: 'Phản hồi' }
    });
    this.$tabs = this.children.map(function (fg) {
        return Object(ACore["c" /* _ */])({
            tag: 'tabframe',
            class: 'kv-overview-widget-page',
            child: fg.getView(), props: {
                name: '&nbsp;'.repeat(5),//||fg.name,
                tabIcon: fg.tabIcon,
                id: fg.id
            }
        });
    });
    this.$view = Object(ACore["c" /* _ */])({
        class: 'kv-overview-widget',
        style: {
            '--x': '0px',
            '--y': '0px',
            visibility: 'hidden'
        },
        child: [
            {
                tag: Hanger["a" /* default */].tag,
                class: 'kv-overview-widget-header',
                child: [
                    this.$title,
                    {
                        class: 'kv-overview-widget-header-window-action',
                        child: [
                            {
                                tag: 'button',
                                child: 'span.mdi.mdi-window-minimize',
                                on: {
                                    click: this.minimize.bind(this)
                                }
                            }
                        ]
                    }
                ],
                on: {
                    predrag: this.ev_headerPredrag.bind(this),
                    dragstart: this.ev_headerDragStart.bind(this),
                    drag: this.ev_headerDrag.bind(this),
                    dragend: this.ev_headerDragEnd.bind(this),

                }
            },
            {
                class: 'kv-overview-widget-body',
                child: {
                    tag: TabView["a" /* default */].tag,
                    class: ['kv-overview-widget-tab-view', 'xp-tiny'],
                    child: this.$tabs,
                    on: {
                        activetab: this.ev_activeTab.bind(this)
                    }
                }
            }
        ]
    });
    this._updateViewPosition();

    this.$bubble = Object(ACore["c" /* _ */])({
        tag: OnScreenWidget["a" /* default */].tag,
        class: 'kv-overview-widget-bubble',
        id: 'overview_widget_bubble',
        style: {
            visibility: 'hidden'
        },
        child: [
            '<svg class="kv-overview-widget-bubble-background"  viewBox="0 0 24 24">\n' +
            '    <path fill="currentColor" d="M3 11H11V3H3M5 5H9V9H5M13 21H21V13H13M15 15H19V19H15M3 21H11V13H3M5 15H9V19H5M13 3V11H21V3M19 9H15V5H19Z" />\n' +
            '</svg>',
            {
                class: 'kv-overview-widget-bubble-badge',
                child: { tag: 'span', child: { text: '0' } }
            }
        ],
        on: {
            click: this.maximize.bind(this)
        }
    });
    this.$tabview = Object(ACore["a" /* $ */])('.kv-overview-widget-tab-view', this.$view);
    this.$action = Object(ACore["a" /* $ */])('.kv-overview-widget-header-window-action', this.$view);
    this.$bubbleBadge = Object(ACore["a" /* $ */])('.kv-overview-widget-bubble-badge', this.$bubble);
    this.$badgeText = Object(ACore["a" /* $ */])('span', this.$bubbleBadge);
    this.$badgeText.requestUpdateSize = this._updateViewPosition.bind(this);
    var self = this;
    this.$tabs.forEach(function (tabElt) {
        tabElt.on('active', function () {
            self.childrenById[this.id].start();
        });
        tabElt.on('deactive', function () {
            self.childrenById[this.id].pause();
        });

    });
    this.updateCounter();
};


OverviewWidget.prototype.saveSetting = function () {
    localStorage.setItem('overview_widget_setting', JSON.stringify(this.setting));
};

OverviewWidget.prototype.loadSetting = function () {
    var setting = {};
    try {
        var settingJson = localStorage.getItem('overview_widget_setting');
        if (settingJson) setting = JSON.parse(settingJson);

    } catch (err) {
    }

    Object.assign(this.setting, setting);
    this._position = new Vec2["a" /* default */](this.setting.viewPos.x, this.setting.viewPos.y);
    this._updateViewPosition();
};

OverviewWidget.prototype.updateCounter = function (from) {
    var id;
    var tabElt;
    var counter;

    if (from) {
        id = from.id;
        tabElt = this.$tabview.getTabById(id);
        counter = from.counter;
        if (counter)
            tabElt.name = '(' + counter + ')';
        else tabElt.name = '&nbsp;'.repeat(5);
    }
    else {
        this.$tabs.forEach(function (tabElt) {
            id = tabElt.id;
            var frg = this.childrenById[id];
            var counter = frg.counter;
            if (counter)
                tabElt.name = '(' + counter + ')';
            else tabElt.name = '&nbsp;'.repeat(5);
        }.bind(this));
    }

    var sumCounter = this.children.reduce(function (ac, cr) {
        return ac + cr.counter;
    }, 0);
    this.$badgeText.firstChild.data = sumCounter + '';
    if (sumCounter > 0) {
        this.$bubbleBadge.removeStyle('visibility');
    }
    else {
        this.$bubbleBadge.addStyle('visibility', 'hidden');
    }
};


OverviewWidget.prototype.onStart = function () {
    this.getView();
    this.loadSetting();
    this.$view.addTo(document.body);
    this.$bubble.addTo(document.body);
    ResizeSystem["a" /* default */].add(this.$badgeText);
    this._updateViewPosition();
    if (this.setting.minimize) {
        this.$bubble.removeStyle('visibility');
    }
    else {
        this.$view.removeStyle('visibility');
    }
    this.children.forEach(function (fg) {
        fg.start(true);
    });
    var activeTabId = this.$tabview.getActiveTabId();
    this.childrenById[activeTabId].start();
};


OverviewWidget.prototype.onStop = function () {
    this.getView().remove();
};

OverviewWidget.prototype.ev_activeTab = function (event) {
    var frag = this.childrenById[event.id];
    this.$title.firstChild.data = frag.name + '';
};

OverviewWidget.prototype.ev_headerPredrag = function (event) {
    if (Object(EventEmitter["d" /* hitElement */])(this.$action, event)) {
        event.cancel();
    }
};

OverviewWidget.prototype.ev_headerDragStart = function (event) {
    var bound = this.$view.getBoundingClientRect();
    this._dragData = {
        bound: bound,
        p0: new Vec2["a" /* default */](bound.left, bound.top),
        modal: Object(ACore["c" /* _ */])({
            style: {
                position: 'fixed',
                zIndex: '1000000000',
                left: 0,
                right: 0,
                top: 0,
                bottom: 0,
                background: 'transparent'
            }
        }).addTo(document.body)
    };
};

OverviewWidget.prototype.ev_headerDrag = function (event) {
    var d = event.currentPoint.sub(event.startingPoint);
    this._position = this._dragData.p0.add(d);
    this._updateViewPosition();
};

OverviewWidget.prototype.ev_headerDragEnd = function (event) {
    this._dragData.modal.remove();
    this.setting.viewPos.x = this._position.x;
    this.setting.viewPos.y = this._position.y;
    this.saveSetting();
};

OverviewWidget.prototype._updateViewPosition = function () {
    if (!this.$view) return;
    var screenSize = Object(Dom["d" /* getScreenSize */])();
    var bound = this.$view.getBoundingClientRect();
    var x = Math.max(0, Math.min(this._position.x, screenSize.width - bound.width));
    var y = Math.max(0, Math.min(this._position.y, screenSize.height - bound.height));
    this.$view.addStyle({
        '--x': x + 'px',
        '--y': y + 'px'
    });
};


Object.defineProperty(OverviewWidget.prototype, 'position', {
    set: function (value) {
        if (!value) value = new Vec2["a" /* default */](0, 0);
        if (value instanceof Array) {
            if (Object(utils["isRealNumber"])(value[0] && Object(utils["isRealNumber"])(value[1]))) {
                value = new Vec2["a" /* default */](value[0], value[1]);
            }
            else {
                value = new Vec2["a" /* default */](0, 0);
            }
        }
        else if (!(value instanceof Vec2["a" /* default */])) {
            if (Object(utils["isRealNumber"])(value.x && Object(utils["isRealNumber"])(value.y))) {
                value = new Vec2["a" /* default */](value[0], value[1]);
            }
            else {
                value = new Vec2["a" /* default */](0, 0);
            }
        }
        this._position = value;
        this._updateViewPosition();
    },
    get: function () {
        return this._position;
    }
});

OverviewWidget.prototype.minimize = function () {
    this.$view.addStyle('visibility', 'hidden');
    this.$bubble.removeStyle('visibility');
    this.setting.minimize = true;
    this.saveSetting();
    var activeTabId = this.$tabview.getActiveTabId();
    this.childrenById[activeTabId].pause();
};


OverviewWidget.prototype.maximize = function () {
    this.$bubble.addStyle('visibility', 'hidden');
    this.$view.removeStyle('visibility');
    this.setting.minimize = false;
    this.saveSetting();
    var activeTabId = this.$tabview.getActiveTabId();
    this.childrenById[activeTabId].start();
};


/* harmony default export */ var keeview_OverviewWidget = (OverviewWidget);

// CONCATENATED MODULE: ./node_modules/absol-acomp/js/keeview/OverviewPage.js






/***
 * @extends Fragment
 * @param {{}} host
 * @constructor
 */
function OverviewPage(host) {
    AppPattern_Fragment.call(this);
    this.host = host;
    this.id = Object(stringGenerate["randomIdent"])(5);
    this._counter = 0;

}

OOP["a" /* default */].mixClass(OverviewPage, AppPattern_Fragment);


OverviewPage.prototype.tabIcon = 'span.mdi.mdi-cube-outline';
OverviewPage.prototype.name = 'Overview Page';

OverviewPage.prototype.createView = function () {
    return Object(ACore["c" /* _ */])({
        child: { tag: 'span', child: { text: 'OverviewPage' } }
    });
};

Object.defineProperty(OverviewPage.prototype, 'counter', {
    set: function (value) {
        /***
         *
         * @type {OverviewWidget}
         */
        var parent = this.parent;
        if (!Object(utils["isRealNumber"])(value)) value = 0;
        value = Math.max(0, value >> 0);
        this._counter = value;
        parent.updateCounter();

    },
    get: function () {
        return this._counter;
    }
});


/* harmony default export */ var keeview_OverviewPage = (OverviewPage);
// CONCATENATED MODULE: ./node_modules/absol-acomp/dev.js
































absol.VariantColors = VariantColors["a" /* default */];
absol.parseMessage = MessageInput["c" /* parseMessage */];
absol.vScrollIntoView = utils["vScrollIntoView"];

//for export to window
absol.Tooltip = Tooltip["a" /* default */];
absol.QuickMenu = QuickMenu["a" /* default */];
absol.AComp = AComp["a" /* default */];
absol.Radio = Radio["a" /* default */];
absol.EmojiChars = EmojiChars["a" /* default */];
absol.EmojiAnims = EmojiAnims["a" /* default */];
absol.ChromeCalendar = ChromeCalendar["a" /* default */];
Object(install["a" /* default */])(absol.coreDom);
//old module
absol.coreDom.install('searchcrosstextinput', Searcher["a" /* default */]);

Object.assign(absol.string, stringMatching);
absol.MessageInput = MessageInput["b" /* default */]
absol.EmojiPicker = EmojiPicker["a" /* default */];
absol.ContextCaptor = ContextMenu["a" /* default */];
absol.ListDictionary = ListDictionary;

window.AComp = absol.AComp;
absol.TextMeasure = js_TextMeasure;

Dom["b" /* default */].documentReady.then(function () {
    var mdiLink = absol.$('link', document.head, function (e) {
        if (e.href && e.href.toLowerCase().indexOf('materialdesignicons') >= 0) return true;
    });
    if (!mdiLink) {
        mdiLink = absol._({
            tag: 'link',
            attr: {
                rel: 'stylesheet',
                href: '//cdn.jsdelivr.net/npm/@mdi/font@6.5.95/css/materialdesignicons.min.css'
            }
        }).addTo(document.head);
    }
});

Object.assign(absol.$, utils);

materializeIconTrigger();

absol.MaterialDesignIconsNameMap = MaterialDesignIconsNameMap;
absol.openFileDialog = utils["openFileDialog"];
absol.CPUViewer = CPUViewer["a" /* default */];

absol.OverviewWidget = keeview_OverviewWidget;
absol.OverviewPage = keeview_OverviewPage;

// EXTERNAL MODULE: ./node_modules/absol-brace/dev.js
var dev = __webpack_require__(332);

// EXTERNAL MODULE: ./css/explain.css
var explain = __webpack_require__(337);

// CONCATENATED MODULE: ./js/scriptor/TutorNameManager.js
function TutorNameManager() {
  this.sync = {};
  this.async = {};
  this.const = {};
  this._cacheSync = null;
  this._cacheAsync = null;
  this._cacheConst = null;
}

TutorNameManager.prototype.addAsync = function (key) {
  this.async[key] = true;
  this._cacheAsync = null;
  return this;
};

TutorNameManager.prototype.addSync = function (key) {
  this.sync[key] = true;
  this._cacheSync = null;
  return this;
};

TutorNameManager.prototype.addConst = function (key) {
  this.const[key] = true;
  this._cacheConst = null;
  return this;
};

TutorNameManager.prototype.getAllSync = function () {
  if (!this._cacheSync) this._cacheSync = Object.keys(this.sync);
  return this._cacheSync;
};

TutorNameManager.prototype.getAllAsync = function () {
  if (!this._cacheAsync) this._cacheAsync = Object.keys(this.async);
  return this._cacheAsync;
};

TutorNameManager.prototype.getAllConst = function () {
  if (!this._cacheConst) this._cacheConst = Object.keys(this.const);
  return this._cacheConst;
};

TutorNameManager.prototype.getAll = function () {
  return this.getAllSync().concat(this.getAllAsync()).concat(this.getAllConst());
};

TutorNameManager.prototype.spreadObject = function (obj) {
  return this.getAll().map(function (key) {
    return obj[key];
  });
};

/* harmony default export */ var scriptor_TutorNameManager = (new TutorNameManager());
// CONCATENATED MODULE: ./js/scriptor/TACData.js
var TACData = {
  define: function define(path, desc) {
    var t = path.split('.');
    var cObject = this;
    var cKey;

    for (var i = 0; i < t.length; ++i) {
      cKey = t[i];
      cObject.properties = cObject.properties || {};

      if (i + 1 === t.length) {
        cObject.properties[cKey] = desc;
      } else {
        cObject.properties[cKey] = cObject.properties[cKey] || {};
      }

      cObject = cObject.properties[cKey];
    }

    return this;
  }
};
TACData.define('Math.max', {
  type: 'function',
  args: [{
    name: '...x',
    type: 'number'
  }],
  returns: 'number',
  desc: "Giá trị lớn nhất"
});
TACData.define('Math.min', {
  type: 'function',
  args: [{
    name: '...x',
    type: 'number'
  }],
  returns: 'number',
  desc: "Giá trị nhỏ nhất"
});
/* harmony default export */ var scriptor_TACData = (TACData);
// CONCATENATED MODULE: ./js/engine/TState.js

/***
 *
 * @param {AsyncCommand} command
 * @constructor
 */

function TState(command) {
  this.command = command;
}

TState.prototype.name = 'noop';
TState.prototype.onStart = noop["a" /* default */];
TState.prototype.onStop = noop["a" /* default */];
/***
 *
 * @param {string} state
 */

TState.prototype.goto = function (state) {
  this.command.goto(state);
};

/* harmony default export */ var engine_TState = (TState);
// CONCATENATED MODULE: ./js/engine/AsyncCommand.js



var STATE_FINISH = 'finish';
/***
 * @extends TState
 * @param command
 * @constructor
 */

function StateFinish(command) {
  engine_TState.apply(this, arguments);
}

OOP["a" /* default */].mixClass(StateFinish, engine_TState);

StateFinish.prototype.onStart = function () {
  this.command.resolve();
};
/***
 *
 * @param {TProcess}process
 * @param {{}} args
 * @constructor
 */


function AsyncCommand(process, args) {
  this.process = process;
  this.args = args;
  this.state = null;
  this.promise = new Promise(function (resolve, reject) {
    this._resolveCb = resolve;
    this._rejectCb = reject;
  }.bind(this));
}

AsyncCommand.prototype.type = 'async';
AsyncCommand.prototype.argNames = [];
AsyncCommand.prototype.onStart = noop["a" /* default */];
AsyncCommand.prototype.onStop = noop["a" /* default */];

AsyncCommand.prototype.goto = function (state) {
  if (!this.state) return; // stop or not start, can not goto

  var clazz = this.stateClasses[state];
  this.state.onStop();
  this.state = new clazz(this);
  this.state.onStart();
};

AsyncCommand.prototype.resolve = function (result) {
  var stackIdx;

  if (this.state) {
    this.state.onStop();
    this.onStop();
    this.state = null;
    stackIdx = this.process.stack.indexOf(this);

    if (stackIdx >= 0) {
      this.process.stack.splice(stackIdx, 1);
    } else {
      throw new Error('Stack error: process.stack run incorrectly!');
    }
  }

  if (this._resolveCb) {
    this._resolveCb(result);

    this._rejectCb = null;
    this._resolveCb = null;
  }
};

AsyncCommand.prototype.reject = function (err) {
  if (this.state) {
    this.state.onStop();
    this.state = null;
    this.onStop();
  }

  if (this._rejectCb) {
    this._rejectCb(err);

    this._rejectCb = null;
    this._resolveCb = null;
  }
};

AsyncCommand.prototype.exec = function () {
  if (!this.state) {
    this.process.stack.push(this);
    this.onStart();
    this.state = new this.stateClasses.entry(this);
    this.state.onStart();
  }

  return this.promise;
};

AsyncCommand.prototype.stateClasses = {};
AsyncCommand.prototype.stateClasses.finish = StateFinish;
AsyncCommand.prototype.stateClasses.entry = StateFinish;
/* harmony default export */ var engine_AsyncCommand = (AsyncCommand);
// CONCATENATED MODULE: ./js/engine/TCommand.js


/***
 * @type {function(...args: function):void}
 */

function inheritCommand() {
  var classes = Array.prototype.slice.call(arguments);
  var clazz = classes.shift();
  if (classes.length === 0) classes.push(engine_AsyncCommand);
  var argNames = [];
  var stateClasses;
  var des = {};

  for (var i = 0; i < classes.length; ++i) {
    Object.assign(des, Object.getOwnPropertyDescriptors(classes[i].prototype));

    if (classes[i].prototype.stateClasses) {
      stateClasses = Object.assign(stateClasses || {}, classes[i].prototype.stateClasses);
    }

    if (classes[i].prototype.argNames) {
      argNames = classes[i].prototype.argNames;
    }
  }

  delete des.constructor;
  Object.defineProperties(clazz.prototype, des);
  clazz.prototype.argNames = argNames.slice();

  if (stateClasses) {
    clazz.prototype.stateClasses = stateClasses;
  }
}
/***
 *
 * @param {TProcess} process
 * @param {{}} args
 * @constructor
 */

function TCommand(process, args) {
  this.process = process;
  this.args = args;
}

TCommand.prototype.className = 'TCommand';
TCommand.prototype.argNames = [];
TCommand.prototype.onStart = noop["a" /* default */];
TCommand.prototype.onStop = noop["a" /* default */];
TCommand.prototype.exec = noop["a" /* default */];
/* harmony default export */ var engine_TCommand = (TCommand);
// CONCATENATED MODULE: ./js/scriptor/BaseState.js


/***
 * @extends TState
 * @param command
 * @constructor
 */

function BaseState(command) {
  engine_TState.apply(this, arguments);
  /***
   * @type BaseCommand
   * @name command
   * @memberOf BaseState#
   */

  for (var key in this) {
    if (key.startsWith('ev_') || typeof this[key] === "function") {
      this[key] = this[key].bind(this);
    }
  }
}

OOP["a" /* default */].mixClass(BaseState, engine_TState);
Object.defineProperty(BaseState.prototype, 'tutor', {
  get: function get() {
    return this.command.tutor;
  }
});
Object.defineProperty(BaseState.prototype, 'args', {
  get: function get() {
    return this.command.args;
  }
});
/* harmony default export */ var scriptor_BaseState = (BaseState);
// EXTERNAL MODULE: ./css/basecommand.css
var basecommand = __webpack_require__(101);

// CONCATENATED MODULE: ./js/util/wrapAsync.js
function wrapAsync(val) {
  if (val) {
    if (val.exec) return val.exec();
    if (val.then) return val;
  }

  return Promise.resolve(val);
}
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Toast.js
var Toast = __webpack_require__(35);

// EXTERNAL MODULE: ./node_modules/showdown/dist/showdown.js
var showdown = __webpack_require__(110);

// CONCATENATED MODULE: ./js/scriptor/BaseCommand.js
















var showdownConverter = new showdown["Converter"]();
/***
 * @typedef {{eltPath:string, message:string, wrongMessage:string, finishMessage:string, text: string, query: string, value:(string|number|null)>,until:(BaseCommand|(function():Promise))}} TutorCommandArgs
 */

/***
 * @extends AsyncCommand
 * @param process
 * @param {TutorCommandArgs} args
 * @constructor
 */

function BaseCommand(process, args) {
  engine_AsyncCommand.apply(this, arguments);
  this.tooltipToken = null;
  /***
   *
   * @type {*[]}
   * @protected
   */

  this._toastElts = [];
  this.hadWrongAction = false;
  this.$target = null;
  this._currentTostPosition = 'se';
  /** KeyBoard **/

  this._ev_docKeyboard = this.ev_docKeyboard.bind(this);
  this._keyboardPrevented = false;
  /***
   * only call if prevented keyboard
   * @type {function():void}
   */

  this.keyCb = null;
  /** Mouse **/

  this.ev_clickModal = this.ev_clickModal.bind(this);
  /***
   * only call if prevented mouse
   * @type {function():void}
   */

  this.clickCb = null;
}

inheritCommand(BaseCommand, engine_AsyncCommand);
BaseCommand.prototype.$htmlRender = Core_('div');
/***
 * @type BlinkMask
 */

BaseCommand.prototype.$highlightModal = Core_({
  tag: dom_BlinkMask.tag,
  class: ['atr-explain-modal', 'as-non-interact', 'as-animation']
});
BaseCommand.prototype.$puncturedModal = Core_({
  tag: 'puncturedmodal',
  class: 'as-transparent',
  props: {
    onInteractOut: null
  }
});
BaseCommand.prototype.$transparentModal = Core_('.atr-transparent-modal.as-hidden');
BaseCommand.prototype.$tooltipContent = Core_({
  class: 'atr-explain-text'
});
/***
 *
 * @param {KeyboardEvent} event
 */

BaseCommand.prototype.ev_docKeyboard = function (event) {
  this.hadWrongAction = true;
  event.preventDefault();

  if (this.keyCb) {
    this.keyCb();
  }
};
/***
 *
 * @param {function|null} cb
 */


BaseCommand.prototype.ifPressKey = function (cb) {
  this.keyCb = cb;
};

BaseCommand.prototype.ev_clickModal = function (event) {
  this.hadWrongAction = true;
  if (this.clickCb) this.clickCb();
};
/***
 *
 * @param {function|null} cb
 */


BaseCommand.prototype.ifClickModal = function (cb) {
  this.clickCb = cb;
};
/***
 * @param {HTMLElement} elt
 * @param {MouseEvent} event
 */


BaseCommand.prototype.hitSomeOf = function (elt, event) {
  if (Object(EventEmitter["d" /* hitElement */])(elt, event)) return false;
  var bound = Rectangle["a" /* default */].fromClientRect(elt.getBoundingClientRect());
  var p = new Vec2["a" /* default */](event.clientX, event.clientY);
  if (!bound.containsPoint(p)) return false;
  var id = elt.getAttribute('data-tutor-id') || elt['data-tutor-id'];
  if (!id) return false;
  var target = event.target;
  var tId;

  while (target) {
    tId = target.getAttribute('data-tutor-id') || target['data-tutor-id'];
    if (tId === id) return elt !== target;
    target = target.parentElement;
  }

  return false;
};

BaseCommand.prototype.onStart = function () {
  this.$puncturedModal.on('click', this.ev_clickModal);
  this.$transparentModal.on('click', this.ev_clickModal);
};
/***
 *
 * @param {function|null} cb
 */


BaseCommand.prototype.ifCancel = function (cb) {};

BaseCommand.prototype.onStop = function () {
  /** modal **/
  this.$puncturedModal.off('click', this.ev_clickModal);
  this.$transparentModal.off('click', this.ev_clickModal);
  this.clickCb = null;
  this.keyCb = null;
  this.closeTooltip();
  this.closeAllToasts();
  this.highlightElt(null);
  this.onlyClickTo(null);
  this.preventMouse(false);
  this.preventKeyBoard(false);
};

BaseCommand.prototype.md2HTMLElements = function (text) {
  this.$htmlRender.innerHTML = showdownConverter.makeHtml(text);
  return Array.prototype.slice.call(this.$htmlRender.childNodes);
};

BaseCommand.prototype.preventMouse = function (flag) {
  if (!this.$transparentModal.parentElement) {
    document.body.appendChild(this.$transparentModal);
  }

  if (flag) {
    this.$transparentModal.removeClass('as-hidden');
  } else {
    this.$transparentModal.addClass('as-hidden');
  }
};

BaseCommand.prototype.preventKeyBoard = function (flag) {
  if (flag) {
    if (!this._keyboardPrevented) {
      this._keyboardPrevented = true;
      document.addEventListener('keydown', this.ev_docKeyboard);
    }
  } else {
    if (this._keyboardPrevented) {
      this._keyboardPrevented = false;
      document.removeEventListener('keydown', this.ev_docKeyboard);
    }
  }
};

BaseCommand.prototype.highlightElt = function (elt) {
  if (!this.$highlightModal.parentElement) {
    document.body.appendChild(this.$highlightModal);
  }

  this.$highlightModal.follow(elt);

  if (elt) {
    this.$highlightModal.removeClass('as-transparent');
  } else {
    this.$highlightModal.addClass('as-transparent');
    this.$highlightModal.reset();
  }
};

BaseCommand.prototype.onlyClickTo = function (elt) {
  if (!this.$puncturedModal.parentElement) {
    document.body.appendChild(this.$puncturedModal);
  }

  if (elt) {
    this.$puncturedModal.follow(elt);
    this.$puncturedModal.removeClass('as-hidden');
  } else {
    this.$puncturedModal.follow(null);
    this.$puncturedModal.addClass('as-hidden');
    this.$puncturedModal.onInteractOut = null;
  }
};
/***
 *
 * @param {string} message
 */


BaseCommand.prototype.showDelayToast = function (message) {
  var thisC = this;
  this.preventMouse(true);
  this.showToast(message);
  return new Promise(function (resolve, reject) {
    setTimeout(function () {
      thisC.preventMouse(false);
      resolve();
    }, thisC.tutor.option.messageDelay);
  });
};

BaseCommand.prototype.showTooltip = function (elt, message) {
  if (typeof message !== "string") return;
  var eltList = this.md2HTMLElements(message);
  this.$tooltipContent.clearChild();
  eltList.forEach(function (elt) {
    this.$tooltipContent.addChild(elt);
  }.bind(this));
  this.tooltipToken = Tooltip["a" /* default */].show(elt, this.$tooltipContent, 'auto');
  Tooltip["a" /* default */].$holder.addClass('atr-on-top-1');
};
/***
 *
 * @param {string} message
 */


BaseCommand.prototype.showToast = function (message) {
  if (typeof message !== "string") return;
  var pos = this._currentTostPosition;
  var toastElt = Toast["a" /* default */].make({
    class: ['as-variant-background', 'atr-toast-message'],
    props: {
      htitle: 'Tutor',
      variant: 'sticky-note',
      timeText: ''
    },
    child: this.md2HTMLElements(message)
  }, pos);

  this._toastElts.push(toastElt);

  this._updateToastPosition();
};

BaseCommand.prototype.closeAllToasts = function () {
  setTimeout(function () {
    this._toastElts.forEach(function (elt) {
      elt.disappear();
    });
  }.bind(this), 1000);
};

BaseCommand.prototype.assignTarget = function (targetElt) {
  this.$target = targetElt;

  this._updateToastPosition();
};
/***
 *
 * @protected
 */


BaseCommand.prototype._updateToastPosition = function () {
  var targetElt = this.$target;

  if (targetElt) {
    var bound = targetElt.getBoundingClientRect();
    var screenSize = Object(Dom["d" /* getScreenSize */])();
    var toastListElt = Toast["a" /* default */].$toastList4Pos[this._currentTostPosition];
    var toastListBound = toastListElt.getBoundingClientRect();
    var boundRect = Rectangle["a" /* default */].fromClientRect(bound);
    var roastListRect = Rectangle["a" /* default */].fromClientRect(toastListBound);
    var isOverlay = roastListRect.isCollapse(boundRect);

    if (this._currentTostPosition === 'se' && bound.left + 400 >= screenSize.width && bound.top + 150 >= screenSize.height || isOverlay) {
      this._currentTostPosition = 'sw';
    } else if (this._currentTostPosition === 'sw' && bound.left <= 400 && bound.top + 150 >= screenSize.height || isOverlay) {
      this._currentTostPosition = 'se';
    }

    this._toastElts.forEach(function (elt) {
      if (!elt.parentElement || elt.parentElement === toastListElt) return;
      toastListElt.addChild(elt);
    });
  }
};

BaseCommand.prototype.closeTooltip = function () {
  if (this.tooltipToken) {
    Tooltip["a" /* default */].closeTooltip(this.tooltipToken);
  }
};

BaseCommand.prototype.depthClone = function () {
  var args = this.args;
  var newArgs = Object.keys(args).reduce(function (ac, cr) {
    if (args[cr] && args[cr].depthClone) {
      ac[cr] = args[cr].depthClone();
    } else {
      ac[cr] = args[cr];
    }

    return ac;
  }, {});
  return new this.constructor(this.process, newArgs);
};

BaseCommand.prototype.asyncGetElt = function (val) {
  var res;

  if (typeof val === "string") {
    res = wrapAsync(this.tutor.findNode(val));
  } else {
    res = wrapAsync(val);
  }

  return res.then(function (result) {
    if (result) return $(result);
    return result;
  });
};
/***
 *
 * @param {string|AElement} query
 * @param {boolean=} unsafe
 * @return {AElement}
 */


BaseCommand.prototype.findNode = function (query, unsafe) {
  return this.tutor.findNode(query, unsafe);
};

BaseCommand.attachEnv = function (tutor, env) {};

Object.defineProperty(BaseCommand.prototype, 'tutor', {
  get: function get() {
    return this.process.tutor;
  }
});
/* harmony default export */ var scriptor_BaseCommand = (BaseCommand);
// CONCATENATED MODULE: ./js/scriptor/UserBaseAction.js




/***
 * @extends BaseState
 * @param {BaseCommand} command
 * @constructor
 */

function StateWaitElt(command) {
  scriptor_BaseState.call(this, command);
  this.checkElt = this.checkElt.bind(this);
  this.countDown = 20;
}

OOP["a" /* default */].mixClass(StateWaitElt, scriptor_BaseState);

StateWaitElt.prototype.onStart = function () {
  this.inv = setInterval(this.checkElt, 100);
};

StateWaitElt.prototype.onStop = function () {
  clearInterval(this.inv);
};

StateWaitElt.prototype.checkElt = function () {
  this.command.elt = this.command.findNode(this.args.eltPath, true);
  this.countDown--;

  if (this.countDown <= 0) {
    this.command.reject(new Error("Could not find " + this.args.eltPath));
    return;
  }

  var error;

  if (this.command.elt) {
    error = this.command.verifyElt();

    if (error) {
      this.command.reject(error);
    } else {
      this.command.assignTarget(this.command.elt);
      this.goto('show_message');
    }
  }
};
/***
 * @extends BaseState
 * @param {BaseCommand} command
 * @constructor
 */


function StateShowMessage(command) {
  scriptor_BaseState.call(this, command);
}

OOP["a" /* default */].mixClass(StateShowMessage, scriptor_BaseState);

StateShowMessage.prototype.onStart = function () {
  this.command.showDelayToast(this.args.message).then(function () {
    this.goto('user_begin');
  }.bind(this));
};
/***
 * @extends BaseCommand
 * @constructor
 */


function UserBaseAction() {
  scriptor_BaseCommand.apply(this, arguments);
  /***
   *
   * @type {null|AElement}
   */

  this.elt = null;
  this.hadWrongAction = false;
}

inheritCommand(UserBaseAction, scriptor_BaseCommand);
/***
 *
 * @return {Promise<void>}
 */

UserBaseAction.prototype.requestUserAction = function () {
  return Promise.resolve();
};
/***
 *
 * @returns {null|Error}
 */


UserBaseAction.prototype.verifyElt = function () {
  return null;
};

UserBaseAction.prototype.stateClasses.entry = StateWaitElt;
UserBaseAction.prototype.stateClasses.show_message = StateShowMessage;
UserBaseAction.prototype.stateClasses.user_begin = UserBaseAction.prototype.stateClasses.finish;
/* harmony default export */ var scriptor_UserBaseAction = (UserBaseAction);
// EXTERNAL MODULE: ./node_modules/regenerator-runtime/runtime.js
var runtime = __webpack_require__(80);
var runtime_default = /*#__PURE__*/__webpack_require__.n(runtime);

// CONCATENATED MODULE: ./js/engine/TProcess.js
/***
 *
 * @param {TProgram} program
 * @constructor
 */
function TProcess(program) {
  this.program = program;
  this.env = {};
  this.program.engine.makeEnvVariables(this);
  this.state = 'READY';
  this.returns = null;
  this.stack = [];
  this.debug = {
    loc: {
      start: -1,
      end: -1,
      row: 0,
      //indexing from 1
      col: 0
    }
  };
}

TProcess.prototype.exec = function () {
  if (this.state !== "READY") return this.returns;
  this.state = 'RUNNING';
  var args = this.program.envArgNames.map(function (nane) {
    return this.env[nane];
  }.bind(this));
  this.returns = this.program.exec.apply(this, args);
  return this.returns;
};

TProcess.prototype.stop = function () {
  if (this.state !== 'RUNNING') return;
  this.state = 'STOP';
  var stack = this.stack.slice();

  while (stack.length > 0) {
    stack.pop().reject();
  }
};

/* harmony default export */ var engine_TProcess = (TProcess);
// CONCATENATED MODULE: ./js/engine/TProgram.js
/***
 *
 * @param {ScriptEngine} engine
 * @param {function} exec
 * @param {string[]} envArgNames
 * @param {{}}info
 * @constructor
 */


function TProgram(engine, exec, envArgNames, info) {
  Object.assign(this, info);
  this.engine = engine;
  this.exec = exec;
  this.envArgNames = envArgNames;
}

TProgram.prototype.ProcessClass = engine_TProcess;
/***
 *
 * @returns {TProcess}
 */

TProgram.prototype.newProcess = function () {
  return new this.ProcessClass(this);
};

/* harmony default export */ var engine_TProgram = (TProgram);
// CONCATENATED MODULE: ./js/engine/TDebug.js
function TDebug(process, args) {
  this.process = process;
  this.args = args;
}

TDebug.prototype.argNames = ['row', 'col', 'start', 'end'];
TDebug.prototype.name = '_db';
TDebug.prototype.type = 'sync';
TDebug.prototype.className = 'TDebug';

TDebug.prototype.exec = function () {
  Object.assign(this.process.debug.loc, this.args);
};

/* harmony default export */ var engine_TDebug = (TDebug);
// CONCATENATED MODULE: ./js/engine/ScriptEngine.js




var traverse = babel.traverse;
var parse = babel.parse;
var babelTypes = babel.types;
var presetEnv = babel.presetEnv;
var generator = babel.generator;

function ScriptEngine() {
  this.asyncCommandClasses = {};
  this.syncCommandClasses = {};
  this.constantClasses = {};
  this.asyncCommandFunctions = {};
  this.syncCommandFunctions = {};
  this.constants = {};
  this.installClass(engine_TDebug);
}

ScriptEngine.prototype.makeModuleTemplate = function (code, argNames) {
  return 'module.exports = async function exec(' + argNames.join(',') + ') {\n' + code + '\nreturn 0;' + '}';
};

ScriptEngine.prototype.awaitInject = function (code, ast) {
  var dict = Object.assign({}, this.asyncCommandClasses, this.asyncCommandFunctions);
  traverse(ast, {
    ExpressionStatement: function ExpressionStatement(path) {
      if (path.node.ignore) return;
      if (path.node.loc.start.line === 1) return;

      var _db = babel.types.callExpression(babel.types.identifier("_db"), [babel.types.numericLiteral(path.node.loc.start.line), babel.types.numericLiteral(path.node.loc.start.column), babel.types.numericLiteral(path.node.start), babel.types.numericLiteral(path.node.end)]);

      _db.ignore = true;
      path.insertBefore(_db);
    },
    CallExpression: function CallExpression(path) {
      var needUpdate = false;

      if (path.parent.type === 'AwaitExpression') {
        needUpdate = true;
      } else {
        var node = path.node;
        var callee = node.callee;
        var calleeName = code.substr(callee.start, callee.end - callee.start);

        if (dict[calleeName]) {
          var newNode = babelTypes.awaitExpression(node);
          path.replaceWith(newNode);
          needUpdate = true;
        }
      }

      if (needUpdate) {
        var p = path;
        var pNode;

        while (p) {
          pNode = p.node;

          if (pNode.type === 'FunctionDeclaration') {
            pNode.async = true;
            dict[pNode.id.name] = true;
            break;
          }

          p = p.parentPath;
        }
      }
    }
  });
  return ast;
};

ScriptEngine.prototype.makeEnvVariable = function (process, name) {
  var clazz = this.asyncCommandClasses[name] || this.syncCommandClasses[name];
  var className;

  if (clazz) {
    if (clazz.attachEnv) {
      clazz.attachEnv(process, process.env);
    } else {
      className = clazz.prototype.className || clazz.name;
      new Function('process', 'env', className, 'env.' + name + ' = function ' + name + '(' + clazz.prototype.argNames.join(', ') + ') {' + 'return new ' + className + '(process, {' + clazz.prototype.argNames.map(function (argName) {
        return argName + ': ' + argName;
      }).concat('arguments: Array.prototype.slice.call(arguments)').join(',\n') + '}).exec();' + '}')(process, process.env, clazz);
    }

    return;
  }

  clazz = this.constantClasses[name];

  if (clazz) {
    if (clazz.attachEnv) {
      clazz.attachEnv(process, process.env);
    } else {
      process.env[name] = new clazz(process, {});
    }

    return;
  }

  var func = this.syncCommandFunctions[name] || this.asyncCommandFunctions[name];

  if (func) {
    process.env[name] = func;
    return;
  }

  if (name in this.constants) {
    process.env[name] = this.constants[name];
  }
};
/***
 *
 * @param {TProcess} process
 * @returns {*}
 */


ScriptEngine.prototype.makeEnvVariables = function (process) {
  process.program.envArgNames.forEach(function (arg) {
    this.makeEnvVariable(process, arg);
  }.bind(this));
};

ScriptEngine.prototype.ProgramClass = engine_TProgram;
/***
 * @returns TProgram
 */

ScriptEngine.prototype.compile = function (code) {
  var argNames = Object.keys(Object.assign({}, this.asyncCommandClasses, this.syncCommandClasses, this.constantClasses, this.syncCommandFunctions, this.asyncCommandFunctions, this.constants));
  code = this.makeModuleTemplate(code, argNames);
  var ast = parse(code);
  this.awaitInject(code, ast);
  var options = {
    presets: [presetEnv]
  };
  var newCode = generator(ast, {}, code).code;
  var transformedCode = babel.transform(newCode, options).code;
  var m = {};
  var execFn = new Function('module', 'regeneratorRuntime', transformedCode);
  execFn(m, runtime_default.a);
  return new this.ProgramClass(this, m.exports, argNames, {
    code: code,
    es6Code: newCode,
    transformedCode: transformedCode
  });
};

ScriptEngine.prototype.installClass = function (clazz) {
  var type = clazz.prototype.type;
  var name = clazz.prototype.name;

  switch (type) {
    case 'async':
      this.asyncCommandClasses[name] = clazz;
      break;

    case 'sync':
      this.syncCommandClasses[name] = clazz;
      break;

    case 'const':
      this.constantClasses[name] = clazz;
      break;
  }

  return this;
};

ScriptEngine.prototype.installFunction = function (name, func, async) {
  if (async) {
    this.asyncCommandFunctions[name] = func;
  } else {
    this.syncCommandFunctions[name] = func;
  }

  return this;
};

ScriptEngine.prototype.installConst = function (name, value) {
  this.constants[name] = value;
};

/* harmony default export */ var engine_ScriptEngine = (ScriptEngine);
// CONCATENATED MODULE: ./js/scriptor/TutorEngine.js



function TutorEngine() {
  engine_ScriptEngine.call(this);
}

OOP["a" /* default */].mixClass(TutorEngine, engine_ScriptEngine);
/* harmony default export */ var scriptor_TutorEngine = (new TutorEngine());
// CONCATENATED MODULE: ./js/scriptor/Explain.js








/***
 * @extends BaseState
 * @constructor
 */

function Explain_StateShowMessage() {
  scriptor_BaseState.apply(this, arguments);
}

OOP["a" /* default */].mixClass(Explain_StateShowMessage, scriptor_BaseState);

Explain_StateShowMessage.prototype.onStart = function () {
  this.command.showTooltip(this.command.elt, this.args.text);
  var until = this.args.until;

  if (!until) {
    this.goto('finish');
    return;
  }

  if (until.depthClone) {
    until.depthClone().exec().then(this.goto.bind(this, 'finish'));
  } else if (until.exec) {
    until.depthClone().exec().then(this.goto.bind(this, 'finish'));
  } else if (until.exec) {
    until.exec().then(this.goto.bind(this, 'finish'));
  } else if (until.then) {
    until.then(this.goto.bind(this, 'finish'));
  } else {
    this.goto('finish');
  }
};
/***
 * @extends {UserBaseAction}
 */


function Explain() {
  scriptor_UserBaseAction.apply(this, arguments);
}

inheritCommand(Explain, scriptor_UserBaseAction);
Explain.prototype.argNames = ['eltPath', 'text', 'until'];
Explain.prototype.name = 'explain';
Explain.prototype.stateClasses.user_begin = Explain_StateShowMessage;
scriptor_TutorEngine.installClass(Explain);
scriptor_TutorNameManager.addAsync('explain');
scriptor_TACData.define('explain', {
  type: 'function',
  args: [{
    name: 'eltPath',
    type: '(string|AElement)'
  }, {
    name: 'text',
    type: 'MarkdownString'
  }, {
    name: 'until',
    type: 'Trigger'
  }]
});
/* harmony default export */ var scriptor_Explain = (Explain);
// CONCATENATED MODULE: ./js/scriptor/Timeout.js




/***
 * @extends {BaseCommand}
 */

function Timeout() {
  scriptor_BaseCommand.apply(this, arguments);
  this._timeoutId = -1;
  this._rejectCb = null;
}

OOP["a" /* default */].mixClass(Timeout, scriptor_BaseCommand);

Timeout.prototype.exec = function () {
  this.start();
  var thisC = this;

  if (thisC._timeoutId > 0) {
    throw new Error("Trigger TIMEOUT is not finish before started again!");
  }

  return new Promise(function (resolve, reject) {
    thisC._timeoutId = setTimeout(function () {
      thisC._rejectCb = null;
      thisC._timeoutId = -1;
      resolve();
    }, thisC.args.millis);
    thisC._rejectCb = reject;
  }).then(this.stop.bind(this));
};

Timeout.prototype.cancel = function () {
  if (this._timeoutId > 0) {
    clearTimeout(this._timeoutId);
    this._timeoutId = -1;
  }

  if (this._rejectCb) {
    this._rejectCb();

    this._rejectCb = null;
  }
};

Timeout.attachEnv = function (tutor, env) {
  env.TIME_OUT = function (millis) {
    return new Timeout(tutor, {
      millis: millis
    });
  };

  env.delayUntil = function (trigger) {
    if (!trigger || !trigger.exec) throw new Error("delayUntil: param " + trigger + " is not a Trigger!");
    trigger = trigger.depthClone();
    return trigger.exec();
  };
};

scriptor_TutorNameManager.addSync('TIME_OUT').addAsync('delay').addAsync('delayUntil');
scriptor_TACData.define('TIME_OUT', {
  type: 'function',
  args: [{
    name: 'millis',
    type: 'number'
  }],
  returns: 'Trigger'
});
/* harmony default export */ var scriptor_Timeout = (Timeout);
// CONCATENATED MODULE: ./js/scriptor/PressAnyKey.js




/***
 * @extends {BaseCommand}
 */

function PressAnyKey() {
  scriptor_BaseCommand.apply(this, arguments);
  this.ev_keyPress = this.ev_keyPress.bind(this);
  this._resolveCb = null;
}

OOP["a" /* default */].mixClass(PressAnyKey, scriptor_BaseCommand);

PressAnyKey.prototype.exec = function () {
  this.start();
  document.addEventListener('keydown', this.ev_keyPress);
  return new Promise(function (rs) {
    this._resolveCb = rs;
  }.bind(this)).then(this.stop.bind(this));
};

PressAnyKey.prototype.cancel = function () {
  document.removeEventListener('keydown', this.ev_keyPress);
};

PressAnyKey.prototype.ev_keyPress = function (event) {
  if (this._resolveCb) {
    this._resolveCb();

    this._resolveCb = null;
  }
};

PressAnyKey.attachEnv = function (tutor, env) {
  env.PRESS_ANY_KEY = new PressAnyKey(tutor, {});
};

scriptor_TutorNameManager.addConst('PRESS_ANY_KEY');
scriptor_TACData.define('PRESS_ANY_KEY', {
  type: 'Trigger'
});
/* harmony default export */ var scriptor_PressAnyKey = (PressAnyKey);
// CONCATENATED MODULE: ./js/scriptor/ClickAnyWhere.js







/***
 * @extends BaseState
 * @constructor
 */

function StateWaitClick() {
  scriptor_BaseState.apply(this, arguments);
}

OOP["a" /* default */].mixClass(StateWaitClick, scriptor_BaseState);

StateWaitClick.prototype.onStart = function () {
  document.addEventListener('click', this.ev_click);
};

StateWaitClick.prototype.ev_click = function (event) {
  this.goto('finish');
};

StateWaitClick.prototype.onStop = function () {
  document.removeEventListener('click', this.ev_click);
};
/***
 * @extends {BaseCommand}
 */


function ClickAnyWhere() {
  scriptor_BaseCommand.apply(this, arguments);
}

inheritCommand(ClickAnyWhere, scriptor_BaseCommand);
ClickAnyWhere.prototype.type = 'const';
ClickAnyWhere.prototype.name = 'CLICK_ANY_WHERE';
ClickAnyWhere.prototype.stateClasses.entry = StateWaitClick;
scriptor_TutorEngine.installClass(ClickAnyWhere);
scriptor_TutorNameManager.addConst('CLICK_ANY_WHERE');
scriptor_TACData.define('CLICK_ANY_WHERE', {
  type: 'Trigger'
});
/* harmony default export */ var scriptor_ClickAnyWhere = (ClickAnyWhere);
// CONCATENATED MODULE: ./js/scriptor/Earliest.js




/***
 * @extends {BaseCommand}
 */

function Earliest() {
  scriptor_BaseCommand.apply(this, arguments);
}

OOP["a" /* default */].mixClass(Earliest, scriptor_BaseCommand);
Earliest.prototype.name = 'EARLIEST';
Earliest.prototype.type = 'sync';
Earliest.prototype.argNames = [];

Earliest.prototype.exec = function () {
  var expressions = this.args.arguments.map(function (e) {
    if (e.depthClone) {
      return e.depthClone().exec();
    } else if (e.then) {
      return e;
    } else if (e.exec) {
      return e.exec();
    }

    return Promise.resolve();
  });
  return Promise.any(expressions);
};

scriptor_TutorEngine.installClass(Earliest);
scriptor_TutorNameManager.addSync('EARLIEST');
/* harmony default export */ var scriptor_Earliest = (Earliest);
// CONCATENATED MODULE: ./js/scriptor/Latest.js



/***
 * @extends {BaseCommand}
 */

function Latest() {
  scriptor_BaseCommand.apply(this, arguments);
}

inheritCommand(Latest, scriptor_BaseCommand);
Latest.prototype.name = 'LATEST';
Latest.prototype.type = 'sync';
Latest.prototype.argNames = [];

Latest.prototype.exec = function () {
  var expressions = this.args.arguments.map(function (e) {
    if (e.depthClone) {
      return e.depthClone().exec();
    } else if (e.then) {
      return e;
    } else if (e.exec) {
      return e.exec();
    }

    return Promise.resolve();
  });
  return Promise.all(expressions);
};

scriptor_TutorEngine.installClass(Latest);
/* harmony default export */ var scriptor_Latest = (Latest);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/Snackbar.js
var Snackbar = __webpack_require__(62);

// CONCATENATED MODULE: ./js/scriptor/ShowSnackBar.js





/***
 * @extends {BaseCommand}
 */

function ShowSnackBar() {
  scriptor_BaseCommand.apply(this, arguments);
}

OOP["a" /* default */].mixClass(ShowSnackBar, scriptor_BaseCommand);

ShowSnackBar.prototype.exec = function () {
  this.start();
  this.preventMouse(true);
  Snackbar["a" /* default */].show(this.args.text);

  if (this.args.until && this.args.until.exec) {
    return this.args.until.depthClone().exec().then(this.stop.bind(this));
  } else {
    this.stop();
    return Promise.resolve();
  }
};

ShowSnackBar.attachEnv = function (tutor, env) {
  env.showSnackBar = function (text, until) {
    return new ShowSnackBar(tutor, {
      text: text,
      until: until
    }).exec();
  };
};

scriptor_TutorNameManager.addAsync('showSnackBar');
scriptor_TACData.define('showSnackBar', {
  type: 'function',
  args: [{
    name: 'title',
    type: 'string'
  }, {
    name: 'text',
    type: 'MarkdownString'
  }, {
    name: 'until',
    type: 'Trigger'
  }]
});
/* harmony default export */ var scriptor_ShowSnackBar = (ShowSnackBar);
// CONCATENATED MODULE: ./js/scriptor/Appear.js






/***
 * @extends BaseState
 * @constructor
 */

function StateWaitEltAppear() {
  scriptor_BaseState.apply(this, arguments);
  this.timeOut = -1;
}
OOP["a" /* default */].mixClass(StateWaitEltAppear, scriptor_BaseState);

StateWaitEltAppear.prototype.onStart = function () {
  this.endTime = new Date().getTime() + (this.args.timeout || 100);
  this.checkElt();
};

StateWaitEltAppear.prototype.onStop = function () {
  if (this.timeOut >= 0) {
    clearTimeout(this.timeOut);
    this.timeOut = -1;
  }
};

StateWaitEltAppear.prototype.isVisibility = function (elt) {
  var eltBound;

  if (elt) {
    eltBound = elt.getBoundingClientRect();

    if (eltBound.width > 0 || eltBound.height > 0) {
      if ($(elt).getComputedStyleValue('visibility') !== 'hidden') {
        return true;
      }
    }
  }

  return false;
};

StateWaitEltAppear.prototype.checkElt = function () {
  var now = new Date().getTime();
  this.timeOut = -1;
  var elt = this.command.findNode(this.args.eltPath, true);

  if (this.isVisibility(elt)) {
    this.command.resolve(true);
  } else if (now > this.endTime) {
    this.command.resolve(false);
  } else {
    this.timeOut = setTimeout(this.checkElt.bind(this), Math.min(100, this.endTime - now));
  }
};
/***
 * @extends {BaseCommand}
 * @constructor
 */


function Appear() {
  scriptor_BaseCommand.apply(this, arguments);
}

inheritCommand(Appear, scriptor_BaseCommand);
Appear.prototype.className = 'Appear';
Appear.prototype.argNames = ['eltPath', 'timeout'];
Appear.prototype.name = 'APPEAR';
Appear.prototype.stateClasses.entry = StateWaitEltAppear;
Appear.prototype.type = 'sync';
scriptor_TutorEngine.installClass(Appear);
/* harmony default export */ var scriptor_Appear = (Appear);
// CONCATENATED MODULE: ./js/scriptor/QuerySelector.js

var QuerySelector = {};

QuerySelector.attachEnv = function (tutor, env) {
  env.querySelector = function (query) {
    var elt = tutor.findNode(query, true);
    if (!elt) throw new Error('Can not query element \"' + query + '"');
    return elt;
  };

  env.$ = env.querySelector;

  env.querySelectorAll = function (query) {
    return tutor.findAllNode(query);
  };

  env.$$ = env.querySelectorAll;
};

scriptor_TutorNameManager.addSync('$').addSync('querySelector').addSync('$$').addSync('querySelectoAllr');
/* harmony default export */ var scriptor_QuerySelector = (QuerySelector);
// CONCATENATED MODULE: ./js/scriptor/UserClick.js







/***
 * @extends BaseState
 * @constructor
 */

function UserClick_StateWaitClick() {
  scriptor_BaseState.apply(this, arguments);
}

OOP["a" /* default */].mixClass(UserClick_StateWaitClick, scriptor_BaseState);

UserClick_StateWaitClick.prototype.onStart = function () {
  this.command.highlightElt(this.command.elt);
  this.command.onlyClickTo(this.command.elt);
  this.command.clickCb = this.ev_clickOut;
  this.command.elt.addEventListener('click', this.ev_click);
};

UserClick_StateWaitClick.prototype.onStop = function () {
  this.command.elt.removeEventListener('click', this.ev_click);
};

UserClick_StateWaitClick.prototype.ev_clickOut = function () {
  if (this.args.wrongMessage) {
    this.command.showTooltip(this.command.elt, this.args.wrongMessage);
  }
};

UserClick_StateWaitClick.prototype.ev_click = function () {
  this.goto('finish');
};
/***
 * @extends UserBaseAction
 * @constructor
 */


function UserClick() {
  scriptor_UserBaseAction.apply(this, arguments);
}

inheritCommand(UserClick, scriptor_UserBaseAction);
UserClick.prototype.name = 'userClick';
UserClick.prototype.argNames = ['eltPath', 'message', 'wrongMessage'];
UserClick.prototype.stateClasses.user_begin = UserClick_StateWaitClick;
scriptor_TutorNameManager.addAsync('userClick');
scriptor_TACData.define('userClick', {
  type: 'function',
  args: [{
    name: 'eltPath',
    type: '(string|AElement)'
  }, {
    name: 'message',
    type: 'string'
  }, {
    name: 'wrongMessage',
    type: 'string'
  }]
});
scriptor_TutorEngine.installClass(UserClick);
/* harmony default export */ var scriptor_UserClick = (UserClick);
// CONCATENATED MODULE: ./js/scriptor/UserCheckbox.js







/****
 * @extends BaseState
 * @constructor
 */

function StateWaitCheck() {
  scriptor_BaseState.apply(this, arguments);
  this.checkTO = -1;
}

OOP["a" /* default */].mixClass(StateWaitCheck, scriptor_BaseState);

StateWaitCheck.prototype.onStart = function () {
  this.command.elt.on('click', this.ev_click);
  this.command.highlightElt(this.command.elt);
  this.command.onlyClickTo(this.command.elt);

  this.command.clickCb = function () {
    this.command.showTooltip(this.command.elt, this.command.args.wrongMessage);
  }.bind(this);
};

StateWaitCheck.prototype.onStop = function () {
  this.command.elt.off('click', this.ev_click);
  clearTimeout(this.checkTO);
};

StateWaitCheck.prototype.delayCheck = function () {
  this.checkTO = setTimeout(function () {
    if (!!this.command.elt.checked === !!this.args.checked) {
      this.goto('finish');
    }
  }.bind(this), 50);
};

StateWaitCheck.prototype.ev_click = function () {
  this.delayCheck();
};
/***
 * @extends UserBaseAction
 * @constructor
 */


function UserCheckbox() {
  scriptor_UserBaseAction.apply(this, arguments);
}

inheritCommand(UserCheckbox, scriptor_UserBaseAction);
UserCheckbox.prototype.name = 'userCheckbox';
UserCheckbox.prototype.stateClasses['user_begin'] = StateWaitCheck;

UserCheckbox.prototype.verifyElt = function () {
  var elt = this.elt;

  if (!elt.hasClass || !(elt.hasClass('absol-checkbox') || elt.hasClass('absol-radio') || elt.hasClass('as-checkbox-input') || elt.hasClass('as-checkbox-input') || elt.hasClass('as-radio-input') || elt.hasClass('absol-switch') || elt.tagName.toLowerCase() === 'input' && (elt.type === 'checkbox' || elt.type === 'radio'))) {
    return new Error('Type error: not a radio or checkbox');
  }

  return null;
};

UserCheckbox.prototype.requestUserAction = function () {
  var thisC = this;
  var elt = this.tutor.findNode(this.args.eltPath);

  this._verifyCheckbox(elt);

  var wrongMessage = this.args.wrongMessage;
  var checked = this.args.checked;
  thisC.highlightElt(elt);

  this._clickCb = function () {
    if (wrongMessage) {
      thisC.showTooltip(elt, wrongMessage);
    }
  };

  this.onlyClickTo(elt);
  return new Promise(function (resolve, reject) {
    var clickTimeout = -1;

    function onChange() {
      if (clickTimeout > 0) {
        clearTimeout(clickTimeout);
        clickTimeout = -1;
      }

      if (elt.checked === checked) {
        elt.off('change', onChange).off('click', onClick);
        resolve();
      }
    }

    function onClick() {
      if (clickTimeout > 0) clearTimeout(clickTimeout);
      setTimeout(function () {
        clickTimeout = -1;

        if (elt.checked === checked) {
          elt.off('change', onChange).off('click', onClick);
          resolve();
        }
      }, 50);
    }

    elt.on('change', onChange).on('click', onClick);

    thisC._rejectCb = function () {
      elt.off('change', onChange).off('click', onClick);
      reject();
    };
  });
};

UserCheckbox.attachEnv = function (tutor, env) {
  env.userCheckbox = function (eltPath, checked, message, wrongMessage) {
    return new UserCheckbox(tutor, {
      eltPath: eltPath,
      checked: checked,
      message: message,
      wrongMessage: wrongMessage
    }).exec();
  };

  env.userSwitch = env.userCheckbox;

  env.userRadio = function (eltPath, checked, message, wrongMessage) {
    return new UserCheckbox(tutor, {
      eltPath: eltPath,
      checked: checked,
      message: message,
      wrongMessage: wrongMessage
    }).exec();
  };
};

scriptor_TutorEngine.installClass(UserCheckbox);
scriptor_TutorNameManager.addAsync('userCheckbox');
scriptor_TutorNameManager.addAsync('userSwitch');
scriptor_TutorNameManager.addAsync('userRadio');
scriptor_TACData.define('userCheckbox', {
  type: 'function',
  args: [{
    name: 'eltPath',
    type: '(string|AElement)'
  }, {
    name: 'checked',
    type: 'boolean'
  }, {
    name: 'message',
    type: 'string'
  }, {
    name: 'wrongMessage',
    type: 'string'
  }]
}).define('userRadio', {
  type: 'function',
  args: [{
    name: 'eltPath',
    type: '(string|AElement)'
  }, {
    name: 'checked',
    type: 'boolean'
  }, {
    name: 'message',
    type: 'string'
  }, {
    name: 'wrongMessage',
    type: 'string'
  }]
});
/* harmony default export */ var scriptor_UserCheckbox = (UserCheckbox);
// CONCATENATED MODULE: ./js/scriptor/UserInputText.js









/***
 * @extends BaseState
 * @constructor
 */

function StateWaitFocus() {
  scriptor_BaseState.apply(this, arguments);
}

OOP["a" /* default */].mixClass(StateWaitFocus, scriptor_BaseState);

StateWaitFocus.prototype.onStart = function () {
  this.command.inputElt = $('input', this.command.elt) || $('textarea', this.command.elt);
  this.command.inputElt.on('focus', this.ev_focus);

  if (document.hasFocus() && document.activeElement === this.command.inputElt) {
    this.goto('user_input');
  }

  this.command.highlightElt(this.command.inputElt);
  this.command.clickCb = this.ev_clickOut;
  if (this.command.hadWrongAction && this.command.args.wrongMessage) this.command.showTooltip(this.command.inputElt, this.command.args.wrongMessage);
  this.command.onlyClickTo(this.command.inputElt);
};

StateWaitFocus.prototype.onStop = function () {
  this.command.inputElt.off('focus', this.ev_focus);
  this.command.clickCb = null;
};

StateWaitFocus.prototype.ev_focus = function () {
  this.goto('user_input');
};

StateWaitFocus.prototype.ev_clickOut = function () {
  this.command.hadWrongAction = true;
  if (this.command.args.wrongMessage) this.command.showTooltip(this.command.inputElt, this.command.args.wrongMessage);
};
/***
 * @extends BaseState
 * @constructor
 */


function StateUserInput() {
  scriptor_BaseState.apply(this, arguments);
  this.chaged = false;
}

OOP["a" /* default */].mixClass(StateUserInput, scriptor_BaseState);

StateUserInput.prototype.onStart = function () {
  this.command.highlightElt(null);
  this.command.inputElt.on('change', this.ev_change).on('blur', this.ev_change).once('change', function () {
    this.changed = true;
  }.bind(this)).once('blur', function () {
    this.changed = true;
  }.bind(this)).on('keydown', this.ev_keyDown).on('keyup', this.ev_keyUp);
};

StateUserInput.prototype.onStop = function () {
  this.command.inputElt.off('change', this.ev_change).off('blur', this.ev_change).off('keydown', this.ev_keyDown).off('keyup', this.ev_keyUp);
  if (this.typingTimeout > 0) clearTimeout(this.typingTimeout);
  if (this.changeTimeout > 0) clearTimeout(this.changeTimeout);
};

StateUserInput.prototype.verify = function verify() {
  var isMatched;
  var matchExpression = this.args.match;
  var elt = this.command.inputElt;
  var wrongMessage = this.args.wrongMessage;
  var text = elt.value || elt.text || '';

  if (matchExpression && matchExpression.test) {
    isMatched = matchExpression.test(elt.value || elt.text || '');
  } else if (typeof matchExpression === "function") {
    isMatched = matchExpression(text);
  } else if (typeof matchExpression === 'string') {
    isMatched = text === matchExpression;
  } else if (typeof matchExpression === 'number') {
    isMatched = parseFloat(text) === matchExpression;
  } else {
    isMatched = text > 0;
  }

  if (!isMatched && wrongMessage) {
    this.command.showTooltip(elt, wrongMessage);
  } else if (isMatched) {
    this.command.closeTooltip();
  }

  return isMatched;
};

StateUserInput.prototype.ev_change = function () {
  var elt = this.command.inputElt;

  if (this.verify()) {
    this.goto('prevent_input');
  } else {
    this.changeTimeout = setTimeout(function () {
      this.changeTimeout = -1;

      if (!AElement["a" /* default */].prototype.isDescendantOf.call(document.activeElement, elt)) {
        elt.focus();
      }
    }.bind(this), 1);
  }
};

StateUserInput.prototype.ev_keyUp = function () {
  if (this.typingTimeout > 0) clearTimeout(this.typingTimeout);
  this.typingTimeout = setTimeout(function () {
    this.typingTimeout = -1;

    if (this.verify()) {
      this.goto('prevent_input');
    }
  }.bind(this), 300);
};

StateUserInput.prototype.ev_keyDown = function (event) {
  this.command.highlightElt(null);

  if (event.key === 'Enter') {
    if (this.verify()) {
      this.goto('prevent_input');
    }
  }
};
/***
 * @extends BaseState
 * @constructor
 */


function StatePreventInput() {
  scriptor_BaseState.apply(this, arguments);
  this.checkItv = -1;
}

OOP["a" /* default */].mixClass(StatePreventInput, scriptor_BaseState);

StatePreventInput.prototype.onStart = function () {
  var elt = this.command.inputElt;
  elt.on('keydown', this.ev_keyDown).once('blur', this.ev_finish);
  this.checkItv = setInterval(function () {
    if (document.activeElement !== elt) {
      elt.off('keydown', this.ev_keyDown).off('blur', this.ev_finish);
      clearInterval(this.checkItv);
    }
  }.bind(this), 100);
  this.goto('finish');
};

StatePreventInput.prototype.ev_finish = function () {
  clearInterval(this.checkItv);
  this.command.inputElt.off('keydown', this.ev_keyDown).off('blur', this.ev_finish);
};

StatePreventInput.prototype.ev_keyDown = function (event) {
  if (event.key.length === 1 && !event.ctrlKey && !event.altKey) {
    event.preventDefault();
  }
};
/***
 * @extends UserBaseAction
 * @constructor
 */


function UserInputText() {
  scriptor_UserBaseAction.apply(this, arguments);
}

OOP["a" /* default */].mixClass(UserInputText, scriptor_UserBaseAction);
UserInputText.prototype.name = 'userInputText';
UserInputText.prototype.stateClasses['user_begin'] = StateWaitFocus;
UserInputText.prototype.stateClasses['user_input'] = StateUserInput;
UserInputText.prototype.stateClasses['prevent_input'] = StatePreventInput;

UserInputText.prototype.verifyElt = function (elt) {
  var res = $('input', elt) || $('textarea', elt);
  if (!res) return new Error('Type invalid: not a text input or not contains text input!');
  return null;
};

UserInputText.prototype.requestUserAction = function () {
  var matchExpression = this.args.match;
  var thisC = this;
  var elt = this.tutor.findNode(this.args.eltPath);
  elt = this._verifyTextInput(elt);
  var wrongMessage = this.args.wrongMessage;
  thisC.highlightElt(elt);
  var changed = false;

  function onClick() {
    thisC.highlightElt(null);
  }

  this._clickCb = function () {
    var result = verify();

    if (!result || !changed) {
      thisC.highlightElt(elt);
    }
  };

  thisC.onlyClickTo(elt);

  function verify() {
    var isMatched;
    var text = elt.value || elt.text || '';

    if (matchExpression && matchExpression.test) {
      isMatched = matchExpression.test(elt.value || elt.text || '');
    } else if (typeof matchExpression === "function") {
      isMatched = matchExpression(text);
    } else if (typeof matchExpression === 'string') {
      isMatched = text === matchExpression;
    } else if (typeof matchExpression === 'number') {
      isMatched = parseFloat(text) === matchExpression;
    } else {
      isMatched = text > 0;
    }

    if (!isMatched && wrongMessage) {
      thisC.showTooltip(elt, wrongMessage);
    } else if (isMatched) {
      thisC.closeTooltip();
    }

    return isMatched;
  }

  return new Promise(function (resolve, reject) {
    var changeTimeout = -1;

    function onKeydown(event) {
      thisC.highlightElt(null);

      if (event.key === 'Enter') {
        if (verify()) {
          elt.off('keyup', verify).off('change', onChange).off('blur', onChange).off('keydown', onKeydown).off('onKeyUp', onKeydown).off('click', onClick);
          if (changeTimeout >= 0) clearTimeout(changeTimeout);
          thisC._rejectCb = null;
          resolve();
        }
      }
    }

    var typingTimout = -1;

    function onKeyUp() {
      if (typingTimout > 0) clearTimeout(typingTimout);
      typingTimout = setTimeout(function () {
        typingTimout = -1;

        if (verify()) {
          var preventKey = function preventKey(event) {
            if (event.key.length === 1 && !event.ctrlKey && !event.altKey) {
              event.preventDefault();
            }
          };

          var finishPrevent = function finishPrevent() {
            elt.off('keydown', preventKey).off('blur', finishPrevent);
            clearInterval(checkIntv);
          };

          var checkIntv = setInterval(function () {
            if (document.activeElement !== elt) finishPrevent();
          }, 100);
          elt.on('keydown', preventKey).on('blur', finishPrevent);
          elt.off('keyup', verify).off('change', onChange).off('blur', onChange).off('keydown', onKeydown).off('onKeyUp', onKeydown).off('click', onClick);
          resolve();
        }
      }, 300);
    }

    function onChange(event) {
      if (verify()) {
        elt.off('keyup', verify).off('change', onChange).off('blur', onChange).off('keydown', onKeydown).off('keyup', onKeyUp).off('click', onClick);
        if (changeTimeout >= 0) clearTimeout(changeTimeout);
        thisC._rejectCb = null;
        resolve();
      } else {
        changeTimeout = setTimeout(function () {
          changeTimeout = -1;

          if (!AElement["a" /* default */].prototype.isDescendantOf.call(document.activeElement, elt)) {
            elt.focus();
          }
        }, 1);
      }
    }

    elt.on('keyup', verify).on('change', onChange).on('blur', onChange).once('change', function () {
      changed = true;
    }).once('blur', function () {
      changed = true;
    }).on('click', onClick).on('keydown', onKeydown).on('keyup', onKeyUp);

    thisC._rejectCb = function () {
      elt.off('keyup', verify).off('change', onChange).off('blur', onChange);
      if (changeTimeout >= 0) clearTimeout(changeTimeout);
      reject();
    };
  });
};

UserInputText.attachEnv = function (tutor, env) {
  env.userInputText = function (eltPath, match, message, wrongMessage) {
    return new UserInputText(tutor, {
      eltPath: eltPath,
      match: match,
      message: message,
      wrongMessage: wrongMessage
    }).exec();
  };
};

scriptor_TutorEngine.installConst('EMAIL_REGEX', /^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/);
scriptor_TutorEngine.installClass(UserInputText);
scriptor_TutorNameManager.addAsync('userInputText').addConst('EMAIL_REGEX');
scriptor_TACData.define('userInputText', {
  type: 'function',
  args: [{
    name: 'eltPath',
    type: '(string|AElement)'
  }, {
    name: 'match',
    type: 'Regex|function(string):bool'
  }, {
    name: 'message',
    type: 'string'
  }, {
    name: 'wrongMessage',
    type: 'string'
  }]
}).define('EMAIL_REGEX', {
  type: 'Regex',
  desc: "Biểu thức kiểm tra email"
});
/* harmony default export */ var scriptor_UserInputText = (UserInputText);
// CONCATENATED MODULE: ./js/TutorPath.js

/***
 * @extends JSPath
 * @constructor
 */

function TutorPath() {
  this.match = TutorPath.prototype.match;
  return this;
}

TutorPath.prototype.match = function (elt, query) {
  var res = JSPath["a" /* default */].prototype.match.call(this, elt, query);
  res = res || query.tagName && elt.getAttribute('data-tutor-id') === query.tagName;
  res = res || query.id && elt.getAttribute('data-tutor-id') === query.id;
  res = res || query.tagName && elt['data-tutor-id'] === query.tagName;
  return res;
};
/****
 *
 * @param query
 * @return {TutorPath}
 */


TutorPath.compile = function (query) {
  var jsPath = JSPath["a" /* default */].compileJSPath(query);
  jsPath = TutorPath.call(jsPath);
  return jsPath;
};

/* harmony default export */ var js_TutorPath = (TutorPath);
// CONCATENATED MODULE: ./js/util/findNode.js



function findNode(query, root) {
  if (Object(Dom["e" /* isDomNode */])(query)) return $(query);
  root = root || document.body;
  if (typeof query != 'string') return null;
  var tutorPath = js_TutorPath.compile(query);
  var res = tutorPath.findFirst(root);
  if (res) $(res);
  return res;
}
// CONCATENATED MODULE: ./js/scriptor/SetRootView.js


var SetRootView = {};

SetRootView.attachEnv = function (tutor, env) {
  env.setRootView = function (eltPath) {
    tutor.$view = findNode(eltPath) || document.body;
  };
};

scriptor_TutorNameManager.addSync('setRootView');
/* harmony default export */ var scriptor_SetRootView = (SetRootView);
// CONCATENATED MODULE: ./js/scriptor/UserSelectMenu.js








/***
 * @extends BaseState
 * @constructor
 */

function StateWaitOpenModal() {
  scriptor_BaseState.apply(this, arguments);
}

OOP["a" /* default */].mixClass(StateWaitOpenModal, scriptor_BaseState);

StateWaitOpenModal.prototype.onStart = function () {
  this.command.elt.on('click', this.ev_click);
  this.command.onlyClickTo(this.command.elt);
  this.command.highlightElt(this.command.elt);
};

StateWaitOpenModal.prototype.onStop = function () {
  this.command.elt.off('click', this.ev_click);
  this.command.highlightElt(null);
  clearTimeout(this._checkTO);
  this.command.onlyClickTo(null);
};

StateWaitOpenModal.prototype.checkSelectBox = function () {
  var selectListBox = this.command.elt.$selectlistBox;

  if (selectListBox.getBoundingClientRect().width > 0) {
    this.goto('user_wait_close_modal');
  }
};

StateWaitOpenModal.prototype.ev_click = function () {
  this._checkTO = setTimeout(this.checkSelectBox.bind(this), 50);
};
/***
 * @extends BaseState
 * @constructor
 */


function StateWaitCloseModal() {
  scriptor_BaseState.apply(this, arguments);
}

OOP["a" /* default */].mixClass(StateWaitCloseModal, scriptor_BaseState);

StateWaitCloseModal.prototype.onStart = function () {
  this.inv = setInterval(this.checkSelectBox.bind(this), 150);
  var elt = this.command.elt;
  this.command.onlyClickTo(elt.$selectlistBox);
  var searchMessage = this.args.searchMessage;

  if (searchMessage && elt.enableSearch) {
    this.command.showTooltip(elt.$selectlistBox.$searchInput, searchMessage);
  }
};

StateWaitCloseModal.prototype.onStop = function () {
  clearInterval(this.inv);
  this.command.showTooltip(null);
};

StateWaitCloseModal.prototype.checkSelectBox = function () {
  var selectListBox = this.command.elt.$selectlistBox;
  var bound = selectListBox.getBoundingClientRect();

  if (bound.width === 0) {
    this.goto('check_value');
  }
};
/***
 * @extends BaseState
 * @constructor
 */


function StateCheckValue() {
  scriptor_BaseState.apply(this, arguments);
}

OOP["a" /* default */].mixClass(StateCheckValue, scriptor_BaseState);

StateCheckValue.prototype.onStart = function () {
  if (this.command.elt.value === this.args.value) {
    this.goto('finish');
  } else {
    this.goto('user_begin');

    if (this.args.wrongMessage) {
      this.command.showTooltip(this.command.elt, this.args.wrongMessage);
    }
  }
};
/***
 * @extends UserBaseAction
 * @constructor
 */


function UserSelectMenu() {
  scriptor_UserBaseAction.apply(this, arguments);
}

inheritCommand(UserSelectMenu, scriptor_UserBaseAction);
UserSelectMenu.prototype.className = 'UserSelectMenu';
UserSelectMenu.prototype.name = 'userSelectMenu';
UserSelectMenu.prototype.argNames = ['eltPath', 'value', 'message', 'wrongMessage', 'searchMessage'];
UserSelectMenu.prototype.stateClasses.user_begin = StateWaitOpenModal;
UserSelectMenu.prototype.stateClasses.user_wait_close_modal = StateWaitCloseModal;
UserSelectMenu.prototype.stateClasses.check_value = StateCheckValue;

UserSelectMenu.prototype.verifyElt = function () {
  var elt = this.elt;

  if (!elt.containsClass || !(elt.containsClass('absol-selectmenu') || elt.containsClass('as-select-menu') || elt.containsClass('as-select-tree-menu'))) {
    return new Error("Type error: not a select-menu!");
  }

  return null;
};

scriptor_TutorEngine.installClass(UserSelectMenu);
scriptor_TACData.define('userSelectMenu', {
  type: 'function',
  args: [{
    name: 'eltPath',
    type: '(string|AElement)'
  }, {
    name: 'value',
    type: '(string|value)'
  }, {
    name: 'message',
    type: 'string'
  }, {
    name: 'wrongMessage',
    type: 'string'
  }, {
    name: 'searchMessage',
    type: 'string'
  }]
});
scriptor_TutorNameManager.addAsync('userSelectMenu');
/* harmony default export */ var scriptor_UserSelectMenu = (UserSelectMenu);
// CONCATENATED MODULE: ./js/scriptor/ShowToastMessage.js








/****
 * @extends BaseState
 * @constructor
 */

function ShowToastMessage_StateShowMessage() {
  scriptor_BaseState.apply(this, arguments);
}

OOP["a" /* default */].mixClass(ShowToastMessage_StateShowMessage, scriptor_BaseState);

ShowToastMessage_StateShowMessage.prototype.onStart = function () {
  var title = this.args.title;
  var text = this.args.text;
  var variant = this.args.variant;
  var avoid = this.args.avoid;
  var disappearTimeout = this.args.disappearTimeout;
  var pos = 'se';

  if (["se", "sw", "ne", "nw"].indexOf(avoid) >= 0) {
    pos = avoid;
  }

  this.command.$toast = Toast["a" /* default */].make({
    class: ['as-variant-background', 'atr-toast-message'],
    props: {
      htitle: title,
      disappearTimeout: disappearTimeout,
      variant: variant,
      timeText: ''
    },
    child: scriptor_BaseCommand.prototype.md2HTMLElements.call({
      $htmlRender: scriptor_BaseCommand.prototype.$htmlRender
    }, text)
  }, pos);
  this.command.avoidOverlay();
  this.goto('wait_until');
};
/****
 * @extends BaseState
 * @constructor
 */


function StateWaitUntil() {
  scriptor_BaseState.apply(this, arguments);
}

OOP["a" /* default */].mixClass(StateWaitUntil, scriptor_BaseState);

StateWaitUntil.prototype.onStart = function () {
  var until = this.args.until;
  if (!until) until = Promise.resolve();

  if (typeof until === 'number') {
    until = new Promise(function (resolve) {
      setTimeout(resolve, until);
    });
  } else if (typeof until === "function") {
    until = until();
  }

  if (until.depthClone) until = until.depthClone();
  if (until.exec) until = until.exec();

  if (until.then) {
    until.then(this.goto.bind(this, 'finish'));
  } else {
    this.goto('finish');
  }
};
/***
 * @extends BaseCommand
 * @constructor
 */


function ShowToastMessage() {
  scriptor_BaseCommand.apply(this, arguments);
  this.$toast = null;
}

inheritCommand(ShowToastMessage, scriptor_BaseCommand);
ShowToastMessage.prototype.argNames = ['title', 'text', 'disappearTimeout', 'until', 'variant', 'avoid'];
ShowToastMessage.prototype.name = 'showToastMessage';
ShowToastMessage.prototype.stateClasses.entry = ShowToastMessage_StateShowMessage;
ShowToastMessage.prototype.stateClasses.wait_until = StateWaitUntil;
/***
 *
 * @protected
 */

ShowToastMessage.prototype.avoidOverlay = function () {
  var thisC = this;
  var avoidElt = null;

  this._toastElts.push(this.$toast);

  if (this.args.avoid) {
    if (["se", "sw", "ne", "nw"].indexOf(this.args.avoid) < 0) {
      avoidElt = this.args.avoid && this.tutor.findNode(this.args.avoid, true);
      if (avoidElt) thisC.assignTarget(avoidElt);
      setTimeout(function () {
        avoidElt = avoidElt || thisC.args.avoid && thisC.tutor.findNode(thisC.args.avoid, true);
        if (avoidElt) thisC.assignTarget(avoidElt);
      }, 3);
    }
  }
};

scriptor_TutorEngine.installClass(ShowToastMessage);
scriptor_TutorEngine.installClass(ShowToastMessage);
scriptor_TutorNameManager.addAsync('showToastMessage');
scriptor_TACData.define('showToastMessage', {
  type: 'function',
  args: [{
    name: 'title',
    type: 'string'
  }, {
    name: 'text',
    type: 'MarkdownString'
  }, {
    name: 'disappearTimeout',
    type: 'number'
  }, {
    name: 'until',
    type: 'Trigger'
  }, {
    name: 'variant',
    type: 'VariantColorNamesMap'
  }, {
    name: 'avoid?',
    type: '(string|AElement)'
  }],
  desc: 'VariantColorNamesMap("primary" | "secondary" | "success" | "info" | "warning" | "error" | "danger" | "light" | "dark" | "link" | "note")'
});
/* harmony default export */ var scriptor_ShowToastMessage = (ShowToastMessage);
// CONCATENATED MODULE: ./js/scriptor/UserCalendarInput.js






/***
 * @extends UserBaseAction
 * @constructor
 */

function UserCalendarInput() {
  scriptor_UserBaseAction.apply(this, arguments);
  this._rejectCb = null;
}

OOP["a" /* default */].mixClass(UserCalendarInput, scriptor_UserBaseAction);

UserCalendarInput.prototype._afterSelectCalendar = function (elt, requestValue, highlight) {
  var thisC = this;
  this.onlyClickTo(elt);
  thisC.highlightElt(elt);
  return new Promise(function (resolve, reject) {
    if (highlight) {
      if (thisC.args.wrongMessage) {
        thisC.showTooltip(elt, thisC.args.wrongMessage);
      }
    }

    var clickTimeout = -1;

    function onCLick() {
      if (clickTimeout >= 0) clearTimeout(clickTimeout);
      thisC.highlightElt(null);
      clickTimeout = setTimeout(function () {
        clickTimeout = -1;

        if (ChromeCalendar["a" /* default */].$calendar && ChromeCalendar["a" /* default */].$calendar.isDescendantOf(document.body)) {
          thisC.onlyClickTo(ChromeCalendar["a" /* default */].$calendar);

          if (highlight) {
            if (thisC.args.wrongMessage) {
              thisC.showTooltip(ChromeCalendar["a" /* default */].$calendar, thisC.args.wrongMessage);
            }
          }
        } else {
          highlight = true;
          thisC.onlyClickTo(elt);
          thisC.highlightElt(elt);

          if (thisC.args.wrongMessage) {
            thisC.showTooltip(elt, thisC.args.wrongMessage);
          }
        }
      }, 30);
    }

    function onChange(event) {
      var value = event.value;

      if (clickTimeout >= 0) {
        clearTimeout(clickTimeout);
        clickTimeout = -1;
      }

      if (Object(datetime["compareDate"])(value, requestValue) === 0) {
        document.body.removeEventListener('click', onCLick);
        elt.off('change', onChange);
        setTimeout(function () {
          thisC._rejectCb = null;
          resolve(true);
        }, 10);
      } else {
        highlight = true;
        thisC.onlyClickTo(elt);
        thisC.highlightElt(elt);

        if (thisC.args.wrongMessage) {
          thisC.showTooltip(elt, thisC.args.wrongMessage);
        }
      }
    }

    elt.on('change', onChange);
    setTimeout(function () {
      document.body.addEventListener('click', onCLick);
    }, 10);

    thisC._rejectCb = function () {
      if (clickTimeout >= 0) {
        clearTimeout(clickTimeout);
        clickTimeout = -1;
      }

      elt.off('change', onChange);
      document.body.removeEventListener('click', onCLick);
      reject();
    };
  });
};

UserCalendarInput.prototype._verityCalendarInput = function (elt) {
  if (!elt.containsClass || !elt.containsClass('absol-calendar-input')) {
    throw new Error("Invalid element type: not a CalendarInput!");
  }
};

UserCalendarInput.prototype.requestUserAction = function () {
  var thisC = this;
  var elt = thisC.tutor.findNode(thisC.args.eltPath);

  this._verityCalendarInput(elt);

  var value = this.args.value;
  return this._afterSelectCalendar(elt, value);
};

UserCalendarInput.attachEnv = function (tutor, env) {
  env.userCalendarInput = function (eltPath, value, message, wrongMessage) {
    return new UserCalendarInput(tutor, {
      eltPath: eltPath,
      value: new Date(value),
      message: message,
      wrongMessage: wrongMessage
    }).exec();
  };
};

scriptor_TutorNameManager.addAsync('userCalendarInput');
scriptor_TACData.define('userCalendarInput', {
  type: 'function',
  args: [{
    name: 'eltPath',
    type: '(string|AElement)'
  }, {
    name: 'value',
    type: 'Date'
  }, {
    name: 'message',
    type: 'string'
  }, {
    name: 'wrongMessage',
    type: 'string'
  }]
});
/* harmony default export */ var scriptor_UserCalendarInput = (UserCalendarInput);
// CONCATENATED MODULE: ./js/scriptor/DateTime.js




var DateTime = {};
DateTime.properties = Object.assign({}, datetime);

DateTime.properties.parseDMY = function (str) {
  return Object(datetime["parseDateString"])(str, 'dd/mm/yyyy');
};

DateTime.properties.formatDateString = datetime["formartDateString"];
DateTime.libs = {};
Object.keys(DateTime.properties).forEach(function (key) {
  Object.defineProperty(DateTime.libs, key, {
    value: DateTime.properties[key],
    configurable: false,
    writable: false
  });
});
scriptor_TutorEngine.installConst('datetime', DateTime.libs);
scriptor_TutorNameManager.addConst('datetime');
/* harmony default export */ var scriptor_DateTime = (DateTime);
// CONCATENATED MODULE: ./js/scriptor/UserQuickMenu.js










/***
 * @extends BaseState
 * @constructor
 */

function StateWaitMenu() {
  scriptor_BaseState.apply(this, arguments);
  this.wcIdx = -1;
}

OOP["a" /* default */].mixClass(StateWaitMenu, scriptor_BaseState);

StateWaitMenu.prototype.onStart = function () {
  this.command.highlightElt(this.command.elt);
  this.command.onlyClickTo(this.command.elt);
  if (this.command.hadWrongAction && this.args.wrongMessage) this.command.showTooltip(this.command.elt, this.args.wrongMessage);
  this.command.elt.on('click', this.ev_click);
  this.command.clickCb = this.ev_clickOut;
};

StateWaitMenu.prototype.onStop = function () {
  clearTimeout(this.wcIdx);
};

StateWaitMenu.prototype.ev_clickOut = function () {
  this.command.hadWrongAction = true;
  if (this.args.wrongMessage) this.command.showTooltip(this.command.elt, this.args.wrongMessage);
};

StateWaitMenu.prototype.checkMenu = function () {
  if (QuickMenu["a" /* default */].$elt && QuickMenu["a" /* default */].$elt.getBoundingClientRect().width > 0) {
    this.goto('wait_click');
  }
};

StateWaitMenu.prototype.ev_click = function () {
  clearTimeout(this.wcIdx);
  this.wcIdx = setTimeout(this.checkMenu.bind(this), 10);
};
/***
 * @extends BaseState
 * @constructor
 */


function UserQuickMenu_StateWaitClick() {
  scriptor_BaseState.apply(this, arguments);
  this.checkMenuIdx = -1;
  this.blindIdx = -1;
}

OOP["a" /* default */].mixClass(UserQuickMenu_StateWaitClick, scriptor_BaseState);

UserQuickMenu_StateWaitClick.prototype.onStart = function () {
  this.command.highlightElt(QuickMenu["a" /* default */].$elt);
  this.itemElt = findNode(this.args.selectId, QuickMenu["a" /* default */].$elt);

  if (!this.itemElt) {
    this.command.reject(new Error("QuickMenu do not contain " + this.args.selectId));
    return;
  }

  this.itemElt.once('click', this.ev_clickItem);
  if (this.command.hadWrongAction && this.args.wrongMessage) this.command.showTooltip(QuickMenu["a" /* default */].$elt, this.args.wrongMessage);
  this.command.onlyClickTo(this.itemElt);
  this.blindIdx = setTimeout(function () {
    this.command.highlightElt(this.itemElt);
  }.bind(this), 400);
  this.checkMenuIdx = setInterval(this.checkMenu.bind(this), 200);
  this.command.clickCb = this.checkMenu.bind(this);
};

UserQuickMenu_StateWaitClick.prototype.onStop = function () {
  clearInterval(this.checkMenuIdx);
  clearInterval(this.blindIdx);
  this.itemElt.off('click', this.ev_clickItem);
  this.command.clickCb = null;
};

UserQuickMenu_StateWaitClick.prototype.checkMenu = function () {
  if (QuickMenu["a" /* default */].$elt.getBoundingClientRect().width === 0) {
    this.goto('user_begin');
  }
};

UserQuickMenu_StateWaitClick.prototype.ev_clickItem = function () {
  this.goto('finish');
};
/***
 * @extends UserBaseAction
 * @constructor
 */


function UserQuickMenu() {
  scriptor_UserBaseAction.apply(this, arguments);
}

inheritCommand(UserQuickMenu, scriptor_UserBaseAction);
UserQuickMenu.prototype.className = 'UserQuickMenu';
UserQuickMenu.prototype.name = 'userQuickMenu';
UserQuickMenu.prototype.argNames = ['eltPath', 'selectId', 'message', 'wrongMessage'];
UserQuickMenu.prototype.stateClasses['user_begin'] = StateWaitMenu;
UserQuickMenu.prototype.stateClasses['wait_click'] = UserQuickMenu_StateWaitClick;

UserQuickMenu.prototype.verifyElt = function () {
  if (!this.elt.classList.contains('as-quick-menu-trigger')) {
    return new Error('Type error: not a quick-menu trigger');
  }

  return null;
};

scriptor_TutorEngine.installClass(UserQuickMenu);
scriptor_TutorEngine.installFunction('getAllQuickMenuTriggers', function () {
  return $$('.as-quick-menu-trigger');
});
scriptor_TutorNameManager.addAsync('userQuickMenu').addSync('getAllQuickMenuTriggers');
scriptor_TACData.define('userQuickMenu', {
  type: 'function',
  args: [{
    name: 'eltPath',
    type: '(string|AElement)'
  }, {
    name: 'selectId',
    type: 'string'
  }, {
    name: 'message',
    type: 'string'
  }, {
    name: 'wrongMessage',
    type: 'string'
  }]
}).define('getAllQuickMenuTriggers', {
  type: 'function',
  args: [],
  returns: 'QuickMenuTriggers[]'
});
/* harmony default export */ var scriptor_UserQuickMenu = (UserQuickMenu);
// CONCATENATED MODULE: ./js/scriptor/UserLevel2Menu.js









/***
 * @extends BaseState
 * @constructor
 */

function StateWaitSelectRoot() {
  scriptor_BaseState.apply(this, arguments);
  this.toIdx = -1;
}

OOP["a" /* default */].mixClass(StateWaitSelectRoot, scriptor_BaseState);

StateWaitSelectRoot.prototype.onStart = function () {
  this.command.menuLevel = 0;
  this.command.highlightElt(this.command.elt);
  var itemElt = findNode(this.args.menuItemPath[0], this.command.elt);
  this.command.menuItemElt = itemElt;
  if (this.command.hadWrongAction && this.args.wrongMessage) this.command.showTooltip(this.command.menuItemElt, this.args.wrongMessage);
  this.command.onlyClickTo(itemElt);
  this.toIdx = setTimeout(function () {
    this.command.highlightElt(itemElt);
  }.bind(this), 400);
  itemElt.on('click', this.ev_click);
  this.command.clickCb = this.ev_clickOut;
};

StateWaitSelectRoot.prototype.onStop = function () {
  clearTimeout(this.toIdx);
  this.command.menuItemElt.off('click', this.ev_click);
  this.command.clickCb = null;
};

StateWaitSelectRoot.prototype.ev_click = function () {
  this.goto('hover_next');
};

StateWaitSelectRoot.prototype.ev_clickOut = function () {
  this.command.hadWrongAction = true;
  if (this.args.wrongMessage) this.command.showTooltip(this.command.menuItemElt, this.args.wrongMessage);
};
/***
 * @extends BaseState
 * @constructor
 */


function StateHoverNext() {
  scriptor_BaseState.apply(this, arguments);
  this.toIdx = -1;
  this.checkInv = -1;
}

OOP["a" /* default */].mixClass(StateHoverNext, scriptor_BaseState);

StateHoverNext.prototype.onStart = function () {
  this.command.menuLevel++;
  this.command.highlightElt(this.command.menuItemElt.$container);
  var itemElt = findNode(this.args.menuItemPath[this.command.menuLevel], this.command.menuItemElt.$container);
  this.command.menuItemElt = itemElt;
  if (this.command.hadWrongAction && (this.args.wrongMessage1 || this.args.wrongMessage)) this.command.showTooltip(this.command.menuItemElt, this.args.wrongMessage1 || this.args.wrongMessage);
  this.command.onlyClickTo(itemElt);
  this.toIdx = setTimeout(function () {
    this.command.highlightElt(itemElt);
  }.bind(this), 100);
  this.command.menuItemElt.once('mouseenter', this.ev_mouseenter);
  this.checkInv = setInterval(this.checkItemVisibility.bind(this), 300);
};

StateHoverNext.prototype.checkItemVisibility = function () {
  var c = this.command.menuItemElt;

  while (c) {
    if (c.getBoundingClientRect().width === 0) return false;

    if (AElement["a" /* default */].prototype.getComputedStyleValue.call(c, 'visibility') !== 'visible') {
      clearInterval(this.checkInv);
      this.command.hadWrongAction = true;
      this.goto('user_begin');
      break;
    }

    c = c.parentElement;
  }
};

StateHoverNext.prototype.onStop = function () {
  this.command.menuItemElt.off('mouseenter', this.ev_mouseenter);
};

StateHoverNext.prototype.ev_mouseenter = function () {
  if (this.command.menuLevel + 1 >= this.args.menuItemPath.length) {
    this.goto('wait_click_current');
  } else {
    this.goto('hover_next');
  }
};
/***
 * @extends BaseState
 * @constructor
 */


function StateWaitClickCurrent() {
  scriptor_BaseState.apply(this, arguments);
  this.checkInv = -1;
}

OOP["a" /* default */].mixClass(StateWaitClickCurrent, scriptor_BaseState);

StateWaitClickCurrent.prototype.onStart = function () {
  this.command.onlyClickTo(this.command.menuItemElt);
  this.command.highlightElt(this.command.menuItemElt);
  this.checkInv = setInterval(this.checkItemVisibility.bind(this), 300);
  this.command.menuItemElt.once('click', this.ev_click);
};

StateWaitClickCurrent.prototype.onStop = function () {
  clearInterval(this.checkInv);
  this.command.menuItemElt.off('click', this.ev_click);
};

StateWaitClickCurrent.prototype.ev_click = function () {
  this.goto('finish');
};

StateWaitClickCurrent.prototype.checkItemVisibility = StateHoverNext.prototype.checkItemVisibility;
/***
 * @extends UserBaseAction
 * @constructor
 */

function UserLevel2Menu() {
  scriptor_UserBaseAction.apply(this, arguments);
}

inheritCommand(UserLevel2Menu, scriptor_UserBaseAction);
UserLevel2Menu.prototype.argNames = ['eltPath', 'menuItemPath', 'message', 'wrongMessage', 'wrongMessage1'];
UserLevel2Menu.prototype.name = 'userLevel2Menu';
UserLevel2Menu.prototype.className = 'UserLevel2Menu';
UserLevel2Menu.prototype.stateClasses.user_begin = StateWaitSelectRoot;
UserLevel2Menu.prototype.stateClasses.hover_next = StateHoverNext;
UserLevel2Menu.prototype.stateClasses.wait_click_current = StateWaitClickCurrent;

UserLevel2Menu.prototype.verifyElt = function () {
  var elt = this.elt;

  if (!elt.containsClass || !elt.containsClass('as-v-root-menu')) {
    return new Error('Type error: not a valid menu!');
  }
};

scriptor_TutorEngine.installClass(UserLevel2Menu);
scriptor_TutorNameManager.addAsync('userLevel2Menu');
scriptor_TACData.define('userLevel2Menu', {
  type: 'function',
  args: [{
    name: 'eltPath',
    type: '(string|AElement)'
  }, {
    name: 'menuItemPath',
    type: 'string[]'
  }, {
    name: 'message',
    type: 'string'
  }, {
    name: 'wrongMessage',
    type: 'string'
  }, {
    name: 'wrongMessage1',
    type: 'string'
  }]
});
/* harmony default export */ var scriptor_UserLevel2Menu = (UserLevel2Menu);
// CONCATENATED MODULE: ./js/scriptor/Delay.js







/***
 * @extends BaseState
 * @constructor
 */

function StateRunTrigger() {
  scriptor_BaseState.apply(this, arguments);
  this.expression = this.args.until;

  if (this.expression && this.expression.depthClone) {
    this.expression = this.expression.depthClone();
  }

  this.toId = -1;
}

OOP["a" /* default */].mixClass(StateRunTrigger, scriptor_BaseState);

StateRunTrigger.prototype.onStart = function () {
  this.command.preventKeyBoard(true);
  this.command.preventMouse(true);

  if (typeof this.expression === "number") {
    this.toId = setTimeout(this.goto.bind(this, 'finish'), this.expression);
  } else if (this.expression && this.expression.then) {
    this.expression.then(this.goto.bind(this, 'finish'));
  } else if (this.expression && this.expression.exec) {
    this.expression.exec().then(this.goto.bind(this, 'finish'));
  } else {
    throw new Error("\"until\" argument is not valid!");
  }
};

StateRunTrigger.prototype.onStop = function () {
  if (this.toId > 0) {
    clearTimeout(this.toId);
  }

  this.command.preventKeyBoard(false);
  this.command.preventMouse(false);
};
/***
 * @extends BaseCommand
 * @constructor
 */


function Delay() {
  scriptor_BaseCommand.apply(this, arguments);
}

inheritCommand(Delay, scriptor_BaseCommand);
Delay.prototype.argNames = ['until'];
Delay.prototype.className = 'Delay';
Delay.prototype.name = 'delay';
Delay.prototype.stateClasses.entry = StateRunTrigger;
scriptor_TutorEngine.installClass(Delay);
scriptor_TutorNameManager.addAsync('delay');
scriptor_TACData.define('delay', {
  type: 'function',
  args: [{
    name: 'trigger',
    type: 'Trigger|number'
  }],
  desc: "Chờ trong khoảng thời gian hoặc trigger kích hoạt"
});
/* harmony default export */ var scriptor_Delay = (Delay);
// CONCATENATED MODULE: ./js/scriptor/UserSwitchTabIfNeed.js




/***
 * @extends UserBaseAction
 * @constructor
 */

function UserSwitchTabIfNeed() {
  scriptor_UserBaseAction.apply(this, arguments);
}

OOP["a" /* default */].mixClass(UserSwitchTabIfNeed, scriptor_UserBaseAction);
/***
 *
 * @param {HTMLElement} elt
 */

UserSwitchTabIfNeed.prototype.findTabView = function (elt) {
  var tabFrameElt = null;
  var tabViewElt = null;

  while (elt) {
    if (elt.classList.contains('absol-tab-frame')) {
      tabViewElt = null;
      tabFrameElt = elt;
    } else if (elt.classList.contains('absol-tabview')) {
      tabViewElt = elt;
      break;
    }

    elt = elt.parentElement;
  }

  return tabFrameElt && tabViewElt && {
    tabFrameElt: tabFrameElt,
    tabViewElt: tabViewElt
  };
};

UserSwitchTabIfNeed.prototype.exec = function () {
  this.start();
  var thisC = this;
  var elt = this.tutor.findNode(this.args.eltPath);
  var message = this.args.message;
  var wrongMessage = this.args.wrongMessage;
  var tabInfo = this.findTabView(elt);

  if (!tabInfo) {
    this.stop();
    return Promise.resolve();
  }

  var tabViewElt = tabInfo.tabViewElt;
  var tabFrameElt = tabInfo.tabFrameElt;
  var activeTabId = tabViewElt.historyOfTab[tabViewElt.historyOfTab.length - 1];

  if (activeTabId === tabFrameElt.id) {
    return new Promise(function (resolve, reject) {
      if (!thisC.args.notNeedMessage) {
        resolve();
        return;
      }

      thisC.showToast(thisC.args.notNeedMessage);
      var timeoutId = setTimeout(function () {
        timeoutId = -1;
        thisC.stop();
        resolve();
      }, 2000);

      thisC._rejectCb = function () {
        if (timeoutId >= 0) {
          clearTimeout(timeoutId);
          timeoutId = -1;
          reject();
        }
      };
    });
  }

  var tabButton = tabViewElt.$tabbar.getButtonByIdent(tabFrameElt.id);
  tabButton.addClass('atr-tab-button-disabled-close');
  this.highlightElt(tabButton);
  this.showToast(message);
  return new Promise(function (resolve, reject) {
    function onClick() {
      tabButton.removeClass('atr-tab-button-disabled-close');
      tabButton.off('click', onClick);
      resolve();
    }

    thisC._rejectCb = function () {
      tabButton.removeClass('atr-tab-button-disabled-close');
      tabButton.off('click', onClick);
      reject();
    };

    thisC._clickCb = function () {
      if (wrongMessage) thisC.showTooltip(tabButton, wrongMessage);
      thisC.highlightElt(tabButton);
    };

    thisC.onlyClickTo(tabButton);
    tabButton.on('click', onClick);
  }).then(this.stop.bind(this));
};

UserSwitchTabIfNeed.attachEnv = function (tutor, env) {
  env.userSwitchTabIfNeed = function (eltPath, message, wrongMessage, notNeedMessage) {
    return new UserSwitchTabIfNeed(tutor, {
      eltPath: eltPath,
      message: message,
      wrongMessage: wrongMessage,
      notNeedMessage: notNeedMessage
    }).exec();
  };
};

scriptor_TutorNameManager.addAsync('userSwitchTabIfNeed');
scriptor_TACData.define('userSwitchTabIfNeed', {
  type: 'function',
  args: [{
    name: 'eltPath',
    type: '(string|AElement)'
  }, {
    name: 'message',
    type: 'string'
  }, {
    name: 'wrongMessage',
    type: 'string'
  }, {
    name: 'notNeedMessage',
    type: 'string'
  }],
  desc: "eltPath: phần tử bất kì trong tab cần bật, nếu đang mở đúng tab hiện tại, sử dụng notNeedMessage, delay 2s và nhảy lệnh " + "tiếp theo, nếu không có tab nào, lệnh không được thực hiện"
});
/* harmony default export */ var scriptor_UserSwitchTabIfNeed = (UserSwitchTabIfNeed);
// CONCATENATED MODULE: ./js/scriptor/UserSwitchTab.js





/***
 * @extends UserSwitchTabIfNeed
 * @constructor
 */

function UserSwitchTab() {
  scriptor_UserSwitchTabIfNeed.apply(this, arguments);
}

OOP["a" /* default */].mixClass(UserSwitchTab, scriptor_UserSwitchTabIfNeed);

UserSwitchTab.prototype.requestUserAction = function () {
  var thisC = this;
  var elt = this.tutor.findNode(this.args.eltPath);
  var wrongMessage = this.args.wrongMessage;
  var tabInfo = this.findTabView(elt);

  if (!tabInfo) {
    throw Error(this.args.eltPath + ' is not a element of any tab!');
  }

  var tabViewElt = tabInfo.tabViewElt;
  var tabFrameElt = tabInfo.tabFrameElt;
  var tabButton = tabViewElt.$tabbar.getButtonByIdent(tabFrameElt.id);
  tabButton.addClass('atr-tab-button-disabled-close');
  thisC.highlightElt(tabButton);
  return new Promise(function (resolve, reject) {
    function onClick() {
      thisC._clickCb = null;
      tabButton.removeClass('atr-tab-button-disabled-close');
      resolve();
    }

    thisC._rejectCb = function () {
      tabButton.removeClass('atr-tab-button-disabled-close');
      tabButton.off('click', onClick);
      reject();
    };

    thisC._clickCb = function () {
      if (wrongMessage) thisC.showTooltip(tabButton, wrongMessage);
    };

    thisC.onlyClickTo(tabButton);
    tabButton.on('click', onClick);
  });
};

UserSwitchTab.prototype.exec = scriptor_UserBaseAction.prototype.exec;

UserSwitchTab.attachEnv = function (tutor, env) {
  env.userSwitchTab = function (eltPath, message, wrongMessage) {
    return new UserSwitchTab(tutor, {
      eltPath: eltPath,
      message: message,
      wrongMessage: wrongMessage
    }).exec();
  };
};

scriptor_TutorNameManager.addAsync('userSwitchTab');
scriptor_TACData.define('userSwitchTab', {
  type: 'function',
  args: [{
    name: 'eltPath',
    type: '(string|AElement)'
  }, {
    name: 'message',
    type: 'string'
  }, {
    name: 'wrongMessage',
    type: 'string'
  }],
  desc: "eltPath: phần tử bất kì trong tab cần bật, nếu đang mở đúng tab hiện tại, nếu đang mở đúng tab hiện tại thì người" + "dùng vẫn phải bấm bút tab dù nó không có tác dụng gì"
});
/* harmony default export */ var scriptor_UserSwitchTab = (UserSwitchTab);
// CONCATENATED MODULE: ./js/scriptor/UserScrollIfNeed.js












/***
 * @extends BaseState
 * @constructor
 */

function StateBeforeScroll() {
  scriptor_BaseState.apply(this, arguments);
}

OOP["a" /* default */].mixClass(StateBeforeScroll, scriptor_BaseState);

StateBeforeScroll.prototype.onStart = function () {
  this.command.scrollerElt = this.command.findVScroller(this.command.elt);

  if (!this.command.scrollerElt) {
    this.goto('finish');
    return;
  }

  this.scrollDir = this.command.findScrollDir(this.command.elt, this.command.scrollerElt);

  if (this.scrollDir.dy === 0) {
    this.goto('finish');
    return;
  }

  this.command.highlightElt(this.command.elt);
  this.goto('begin_scrolling');
};
/***
 * @extends BaseState
 * @constructor
 */


function StateBeginScrolling() {
  scriptor_BaseState.apply(this, arguments);
  this.checkIdx = -1;
  this.pointerLock = false;
  this.currentDir = 0;
}

OOP["a" /* default */].mixClass(StateBeginScrolling, scriptor_BaseState);

StateBeginScrolling.prototype.onStart = function () {
  this.command.scrollerElt.addEventListener('scroll', this.ev_scroll);
  document.addEventListener('scroll', this.ev_scroll);
  this.command.scrollerElt.classList.add('atr-scroll-only');
  document.body.addEventListener('pointerdown', this.ev_pointerDown);
  document.body.addEventListener('touchstart', this.ev_pointerDown);
  document.body.addEventListener('pointerup', this.ev_pointerUp);
  document.body.addEventListener('pointercancel', this.ev_pointerUp);
  document.body.addEventListener('touchend', this.ev_pointerUp);
  this.scrollDir = this.command.findScrollDir(this.command.elt, this.command.scrollerElt);
  this.prevScrollTop = this.command.scrollerElt.scrollTop;

  this.command._showScroll(this.command.scrollerElt, this.scrollDir);

  this.command.onlyClickTo(this.command.scrollerElt);
};

StateBeginScrolling.prototype.onStop = function () {
  this.command.scrollerElt.removeEventListener('scroll', this.ev_scroll);
  document.removeEventListener('scroll', this.ev_scroll);
  this.command.scrollerElt.classList.remove('atr-scroll-only');
  if (this.checkIdx > 0) clearTimeout(this.checkIdx);
  document.body.removeEventListener('pointerdown', this.ev_pointerDown);
  document.body.removeEventListener('touchstart', this.ev_pointerDown);
  document.body.removeEventListener('pointerup', this.ev_pointerUp);
  document.body.removeEventListener('pointercancel', this.ev_pointerUp);
  document.body.removeEventListener('touchend', this.ev_pointerUp);
};

StateBeginScrolling.prototype.delayCheck = function () {
  if (this.checkIdx > 0) {
    clearTimeout(this.checkIdx);
  }

  var thisC = this.command;
  var vScroller = this.command.scrollerElt;
  this.checkIdx = setTimeout(function () {
    this.checkIdx = -1;
    var currentDir = thisC.findScrollDir(this.command.elt, vScroller);
    this.currentDir = currentDir;
    var pointerLock = this.pointerLock;

    if (currentDir.dy === 0 || !vScroller) {
      thisC._showScrollTooltip(null);

      thisC._prevTootipDir.dy = 0;

      if (!pointerLock) {
        this.goto('finish');
      }
    } else {
      thisC._showScroll(vScroller, currentDir);

      if (thisC._prevTootipDir.dy !== currentDir.dy) {
        thisC._showScrollTooltip(vScroller, currentDir.dy > 0 ? this.command.args.scrollUpMessage : this.command.args.scrollDownMessage, currentDir);
      }

      thisC._prevTootipDir.dy = currentDir.dy;
    }
  }.bind(this), 100);
};

StateBeginScrolling.prototype.ev_scroll = function (event) {
  this.command._updateToastPosition();

  this.currentDir = this.command.findScrollDir(this.command.elt, this.command.scrollerElt);
  var vScroller = this.command.scrollerElt;

  if (vScroller.scrollTop > this.prevScrollTop) {
    if (this.currentDir.dy > 0) {
      this.command.hadWrongAction = true;
    }
  } else if (vScroller.scrollTop < this.prevScrollTop) {
    if (this.currentDir.dy < 0) {
      this.command.hadWrongAction = true;
    }
  }

  this.prevScrollTop = this.command.scrollerElt.scrollTop;
  this.delayCheck();
};

StateBeginScrolling.prototype.ev_pointerUp = function () {
  this.pointerLock = true;
};

StateBeginScrolling.prototype.ev_pointerDown = function () {
  this.pointerLock = false;
};
/***
 * @extends BaseCommand
 * @constructor
 */


function UserScrollIfNeed() {
  scriptor_BaseCommand.apply(this, arguments);
  this._prevTootipDir = {
    dy: 0,
    dx: 0
  };
}

inheritCommand(UserScrollIfNeed, scriptor_UserBaseAction);
UserScrollIfNeed.prototype.name = 'userScrollIfNeed';
UserScrollIfNeed.prototype.argNames = ['eltPath', 'message', 'scrollUpMessage', 'scrollDownMessage', 'offset', 'delta'];
UserScrollIfNeed.prototype.stateClasses['user_begin'] = StateBeforeScroll;
UserScrollIfNeed.prototype.stateClasses['begin_scrolling'] = StateBeginScrolling;
UserScrollIfNeed.prototype.$scrollBarIcon = $(ScrollBarIco.cloneNode(true));
UserScrollIfNeed.prototype.$scrollBarIconCtn = Core_({
  class: 'atr-scroll-icon-ctn',
  child: UserScrollIfNeed.prototype.$scrollBarIcon
});
/***
 * @type {Tooltip}
 */

UserScrollIfNeed.prototype.$scrollTooltip = Core_({
  tag: Tooltip["a" /* default */].tag,
  class: 'atr-scroll-tooltip',
  child: {
    class: 'atr-explain-text'
  }
});
UserScrollIfNeed.prototype.$scrollTooltipText = $('.atr-explain-text', UserScrollIfNeed.prototype.$scrollTooltip);

UserScrollIfNeed.prototype._showScroll = function (elt, dir) {
  this.$scrollBarIcon.removeClass('atr-down').removeClass('atr-up').removeStyle('transform');
  this.$scrollBarIconCtn.removeStyle('left').removeStyle('top');
  if (elt && !this.$scrollBarIconCtn.parentElement) document.body.appendChild(this.$scrollBarIconCtn);else if (!elt && this.$scrollBarIconCtn.parentElement) {
    this.$scrollBarIconCtn.remove();
    return;
  }
  if (!dir) return;
  var bound = elt.getBoundingClientRect();
  var iconBound = this.$scrollBarIconCtn.getBoundingClientRect();

  if (dir.dy) {
    this.$scrollBarIconCtn.addStyle('left', bound.right - 17 - iconBound.width - 5 + 'px');

    if (dir.dy > 0) {
      this.$scrollBarIcon.addClass('atr-up');
      this.$scrollBarIconCtn.addStyle('top', bound.top + 'px');
    } else {
      this.$scrollBarIcon.addClass('atr-down');
      this.$scrollBarIconCtn.addStyle('top', bound.bottom - iconBound.height - 5 + 'px');
    }
  }
};

UserScrollIfNeed.prototype._showScrollTooltip = function (scroller, message, dir) {
  if (!message || !scroller || !dir || !dir.dy) {
    this.$scrollTooltip.remove();
    return;
  }

  if (!this.$scrollTooltip.parentElement) document.body.appendChild(this.$scrollTooltip);
  var sBound = scroller.getBoundingClientRect();
  var messageElt = this.md2HTMLElements(message);
  this.$scrollTooltipText.clearChild().addChild(messageElt);
  this.$scrollTooltip.addStyle('visibility', 'hidden');
  var tBound = this.$scrollTooltip.getBoundingClientRect();

  if (dir.dy > 0) {
    this.$scrollTooltip.removeClass('top').addClass('bottom');
    this.$scrollTooltip.addStyle({
      left: sBound.left + sBound.width / 2 - tBound.width / 2 + 'px',
      top: sBound.top + 'px',
      visibility: 'visible'
    });
  } else {
    this.$scrollTooltip.removeClass('bottom').addClass('top');
    this.$scrollTooltip.addStyle({
      left: sBound.left + sBound.width / 2 - tBound.width / 2 + 'px',
      top: sBound.bottom - tBound.height - 40 + 'px',
      visibility: 'visible'
    });
  }
};

UserScrollIfNeed.prototype.findVScroller = function (elt, dY) {
  var parent = elt.parentElement;
  var overflowStyle;

  while (parent) {
    overflowStyle = window.getComputedStyle(parent)['overflow'];

    if ((overflowStyle === 'auto' || overflowStyle === 'hidden auto' || overflowStyle === 'scroll' || parent.tagName === 'HTML') && parent.clientHeight < parent.scrollHeight) {
      return parent;
    }

    parent = parent.parentElement;
  }
};

UserScrollIfNeed.prototype.findScrollDir = function (elt, scroller) {
  var outBound;

  if (scroller) {
    outBound = scroller.getBoundingClientRect();
  } else {
    outBound = Object(Dom["f" /* traceOutBoundingClientRect */])(elt);
  }

  var bound = elt.getBoundingClientRect();
  var dx = 0;
  var dy = 0;

  if (outBound.height < bound.height * 1.2 && ( true || false)) {
    var delta = outBound.height * this.args.delta;
    var outStart = outBound.top + delta;
    var outEnd = outBound.bottom - delta;
    var outX = outStart + this.args.offset * (outEnd - outStart);
    var x = bound.top + this.args.offset * bound.height;

    if (Math.abs(x - outX) > delta) {
      if (outX < x) {
        dy = -1;
      } else {
        dy = 1;
      }
    }
  } else if (outBound.bottom < bound.bottom !== outBound.top > bound.top) {
    if (outBound.bottom < bound.bottom) {
      dy = -1;
    } else if (outBound.top > bound.top) {
      dy = 1;
    }
  }

  if (outBound.right < bound.right !== outBound.left > bound.left) {
    if (outBound.right < bound.right) {
      dx = -1;
    } else if (outBound.left > bound.left) {
      dx = 1;
    }
  }

  return {
    dx: dx,
    dy: dy
  };
};

UserScrollIfNeed.prototype.onStop = function () {
  this._showScroll(null);

  scriptor_BaseCommand.prototype.onStop.apply(this, arguments);
  this.$scrollBarIconCtn.remove();
  this.$scrollTooltip.remove();
};

scriptor_TutorEngine.installClass(UserScrollIfNeed);
scriptor_TutorNameManager.addAsync('userScrollIfNeed');
scriptor_TACData.define('userScrollIfNeed', {
  type: 'function',
  args: [{
    name: 'eltPath',
    type: '(string|AElement)'
  }, {
    name: 'message',
    type: 'string'
  }, {
    name: 'scrollUpMessage',
    type: 'string'
  }, {
    name: 'scrollDownMessage',
    type: 'string'
  }, {
    name: 'offset',
    type: 'number(0->1)'
  }, {
    name: 'delta',
    type: 'number(0->1)'
  }],
  desc: "Yêu cầu người dùng scroll, hiện giờ chỉ hỗ trợ scroll dọc"
});
/* harmony default export */ var scriptor_UserScrollIfNeed = (UserScrollIfNeed);
// CONCATENATED MODULE: ./js/scriptor/Net.js



var Net = {};
Net.properties = {};

Net.properties.downloadText = function (rqi) {
  return fetch(rqi).then(function (res) {
    return res.text();
  });
};

scriptor_TutorEngine.installFunction('downloadText', Net.properties.downloadText, true);
scriptor_TutorNameManager.addAsync('downloadText');
scriptor_TACData.define('downloadText', {
  type: 'function',
  args: [{
    name: 'rqi',
    type: 'string|RequestInfo'
  }],
  returns: 'string',
  desc: "Tải file về và trả ra string"
});
/* harmony default export */ var scriptor_Net = (Net);
// CONCATENATED MODULE: ./js/scriptor/Logger.js



var Logger = {};
Logger.properties = {};
Logger.properties.log = console.log.bind(console);
scriptor_TutorEngine.installFunction('log', Logger.properties.log, false);
scriptor_TutorNameManager.addAsync('log');
scriptor_TACData.define('log', {
  type: 'function',
  args: [{
    name: '...arg',
    type: 'any'
  }],
  returns: 'void',
  desc: "in ra console để debug"
});
/* harmony default export */ var scriptor_Logger = (Logger);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/MultiSelectMenu.js
var MultiSelectMenu = __webpack_require__(34);

// CONCATENATED MODULE: ./js/scriptor/UserMultiSelectMenu.js









/***
 * @extends UserBaseAction
 * @constructor
 */

function UserMultiSelectMenu() {
  scriptor_UserBaseAction.apply(this, arguments);
  this.emitter = new EventEmitter["b" /* default */]();
  this.ifCancel(function () {
    this.emitter.emit('cancel');
  }.bind(this));
  Object.keys(this.state2fName).forEach(function (name) {
    this.emitter.on(name, this[this.state2fName[name]].bind(this));
  }.bind(this));
}

OOP["a" /* default */].mixClass(UserMultiSelectMenu, scriptor_UserBaseAction);
UserMultiSelectMenu.prototype.state2fName = {
  entry: 'onStateEntry',
  open_dropdown: 'onStateOpenDropDown'
};

UserMultiSelectMenu.prototype.nextActionState = function (stateName) {
  this.actionState = stateName;
  this.emitter.emit.apply(this.emitter, arguments);
};

UserMultiSelectMenu.prototype._verifyMultiSelectMenu = function (elt) {
  if (!elt.containsClass || !elt.containsClass("as-multi-select-menu")) {
    throw new Error("Type error: not a MultiSelectMenu(SelectBox)");
  }
}; //10p


UserMultiSelectMenu.prototype.onStateEntry = function () {
  var thisC = this;
  this.onlyClickTo(this.elt);
  this.ifClickModal(function () {
    thisC.hadWrongAction = true;
    thisC.highlightElt(this.elt);
  });

  function onClick() {
    if (thisC.elt.isFocus) {
      thisC.elt.off('click', onClick);
      thisC.ifClickModal(null);
      thisC.highlightElt(null);
      thisC.nextActionState('open_dropdown');
    }
  }

  this.elt.on('click', onClick);
};

UserMultiSelectMenu.prototype.onStateOpenDropDown = function () {
  var thisC = this;
  this.onlyClickTo(this.elt.$selectlistBox);

  function onMouseUp() {
    setTimeout(function () {
      if (thisC.elt.isFocus) {} else {
        document.removeEventListener('mouseup', onMouseUp);
      }
    }, 100);
  }

  document.addEventListener('mouseup', onMouseUp);
};

UserMultiSelectMenu.prototype.requestUserAction = function () {
  var thisC = this;
  this.elt = this.findNode(this.args.eltPath);

  this._verifyMultiSelectMenu(this.elt);

  return new Promise(function (resolve, reject) {
    function clear() {
      thisC.emitter.off('finish', onFinish).off('cancel', onCancel);
    }

    var onCancel = function onCancel() {
      clear();
      reject();
    };

    var onFinish = function onFinish() {
      clear();
      resolve();
    };

    thisC.nextActionState('entry');
  });
};

UserMultiSelectMenu.attachEnv = function (tutor, env) {
  env.userMultiSelectMenu = function (eltPath, values, message, wrongMessage) {
    return new UserMultiSelectMenu(tutor, {
      eltPath: eltPath,
      values: values,
      message: message,
      wrongMessage: wrongMessage
    }).exec();
  };
};

scriptor_TutorNameManager.addAsync('userMultiSelectMenu');
scriptor_TACData.define('userMultiSelectMenu', {
  type: 'function',
  args: [{
    name: 'eltPath',
    type: '(string|AElement)'
  }, {
    name: 'values',
    type: '(string|value)[]'
  }, {
    name: 'message',
    type: 'string'
  }, {
    name: 'wrongMessage',
    type: 'string'
  }, {
    name: 'searchMessage',
    type: 'string'
  }]
});
/* harmony default export */ var scriptor_UserMultiSelectMenu = (UserMultiSelectMenu);
// CONCATENATED MODULE: ./js/scriptor/ShowConfirmToast.js









/***
 * @extends BaseState
 * @constructor
 */

function ShowConfirmToast_StateShowMessage() {
  scriptor_BaseState.apply(this, arguments);
}

OOP["a" /* default */].mixClass(ShowConfirmToast_StateShowMessage, scriptor_BaseState);

ShowConfirmToast_StateShowMessage.prototype.onStart = function () {
  var command = this.command;
  console.log(this);
  var title = this.args.title;
  var text = this.args.text;
  var buttonText = this.args.buttonText;
  var variant = this.args.variant;
  var avoid = this.args.avoid;
  var pos = 'se';

  if (["se", "sw", "ne", "nw"].indexOf(this.args.avoid) >= 0) {
    pos = avoid;
  }

  var self = this;
  var child = scriptor_BaseCommand.prototype.md2HTMLElements.call({
    $htmlRender: scriptor_BaseCommand.prototype.$htmlRender
  }, text);
  if (!(child instanceof Array)) child = [child];
  child.push({
    class: 'atr-confirm-toast-footer',
    child: {
      tag: 'flexiconbutton',
      props: {
        text: buttonText
      },
      on: {
        click: function click() {
          command.$toast.disappear();
          self.goto('finish');
        }
      }
    }
  });
  command.$toast = Toast["a" /* default */].make({
    class: ['as-variant-background', 'atr-toast-message'],
    props: {
      htitle: title,
      disappearTimeout: 0,
      variant: variant,
      timeText: ''
    },
    child: child
  }, pos);
  command.$toast.$closeBtn.on('click', function () {
    self.goto('finish');
  });
  command.preventMouse(true);
  command.preventKeyBoard(true);
  command.avoidOverlay();
};

ShowConfirmToast_StateShowMessage.prototype.onStop = function () {
  this.command.$toast.disappear();
};
/***
 * @extends ShowToastMessage
 * @constructor
 */


function ShowConfirmToast() {
  scriptor_ShowToastMessage.apply(this, arguments);
}

inheritCommand(ShowConfirmToast, scriptor_ShowToastMessage);
ShowConfirmToast.prototype.argNames = ['title', 'text', 'buttonText', 'variant', 'avoid'];
ShowConfirmToast.prototype.name = 'showConfirmToast';
ShowConfirmToast.prototype.stateClasses.entry = ShowConfirmToast_StateShowMessage;
scriptor_TutorEngine.installClass(ShowConfirmToast);
scriptor_TutorNameManager.addAsync('showConfirmToast');
scriptor_TACData.define('showConfirmToast', {
  type: 'function',
  args: [{
    name: 'title',
    type: 'string'
  }, {
    name: 'text',
    type: 'MarkdownString'
  }, {
    name: 'buttonText',
    type: 'string'
  }, {
    name: 'variant',
    type: 'VariantColorNamesMap'
  }, {
    name: 'avoid?',
    type: '(string|AElement)'
  }],
  desc: 'VariantColorNamesMap("primary" | "secondary" | "success" | "info" | "warning" | "error" | "danger" | "light" | "dark" | "link" | "note")'
});
/* harmony default export */ var scriptor_ShowConfirmToast = (ShowConfirmToast);
// CONCATENATED MODULE: ./js/scriptor/UserDateInput.js










/***
 * @extends BaseState
 * @param {BaseCommand} command
 * @constructor
 */

function StateWaitCalendar(command) {
  scriptor_BaseState.call(this, command);
  this.blindIdx = -1;
  this.checkIdx = -1;
}

OOP["a" /* default */].mixClass(StateWaitCalendar, scriptor_BaseState);

StateWaitCalendar.prototype.onStart = function () {
  var elt = this.command.elt;
  var message = this.args.message;
  var wrongMessage = this.args.wrongMessage;
  var inputTextHintFunc = this.args.inputTextHint && new Function('return ' + TemplateString["a" /* default */].parse(this.args.inputTextHint).toJSCode());

  inputTextHintFunc = inputTextHintFunc || function () {
    return null;
  };

  if (this.command.hadWrongAction && wrongMessage) this.command.showTooltip(this.command.elt, wrongMessage);
  this.command.onlyClickTo(elt.$calendarBtn);
  this.command.elt.$calendarBtn.on('click', this.ev_click);
  this.command.highlightElt(elt);
  this.command.clickCb = this.ev_clickOut;
  this.blindIdx = setTimeout(function () {
    this.blindIdx = -1;
    this.command.highlightElt(elt.$calendarBtn);
  }.bind(this), 400);
};

StateWaitCalendar.prototype.onStop = function () {
  clearTimeout(this.blindIdx);
  clearTimeout(this.checkIdx);
  this.command.elt.$calendarBtn.off('click', this.ev_click);
};

StateWaitCalendar.prototype.checkCalendar = function () {
  var elt = this.command.elt;
  var isOn = !!(elt.share.$calendar && elt.share.$calendar.isDescendantOf(document.body));

  if (isOn) {
    this.goto('choose_date');
  }
};

StateWaitCalendar.prototype.ev_click = function () {
  this.checkIdx = setTimeout(this.checkCalendar.bind(this), 50);
};

StateWaitCalendar.prototype.ev_clickOut = function () {
  this.command.hadWrongAction = true;
  if (this.args.wrongMessage) this.command.showTooltip(this.command.elt, this.args.wrongMessage);
};
/***
 * @extends BaseState
 * @param {BaseCommand} command
 * @constructor
 */


function StateChooseDate(command) {
  scriptor_BaseState.call(this, command);
  this.blindIdx = -1;
  this.checkIdx = -1;
}

OOP["a" /* default */].mixClass(StateChooseDate, scriptor_BaseState);

StateChooseDate.prototype.onStart = function () {
  this.calendarElt = this.command.elt.share.$calendar;
  this.command.highlightElt(this.calendarElt);
  this.blindIdx = setTimeout(this.highlightTarget.bind(this), 400);
  this.command.onlyClickTo(this.calendarElt);
  document.addEventListener('click', this.ev_click);
};

StateChooseDate.prototype.onStop = function () {
  document.removeEventListener('click', this.ev_click);
  clearTimeout(this.blindIdx);
  clearTimeout(this.checkIdx);
};

StateChooseDate.prototype.highlightTarget = function () {
  var calendar = this.calendarElt;
  var value = this.args.value;
  var thisC = this.command;
  var viewDate = calendar._viewDate;
  if (!viewDate) return;
  var dM = Object(datetime["compareMonth"])(value, viewDate);

  if (dM === 0) {
    $('.absol-chrome-calendar-week-in-month>div', calendar, function (dateElt) {
      if (dateElt.__date__ && datetime["compareDate"](dateElt.__date__, value) === 0 && !dateElt.hasClass('absol-chrome-calendar-not-in-month')) {
        thisC.highlightElt(dateElt);
      }
    });
  } else if (dM < 0) {
    thisC.highlightElt(calendar.$prevBtn);
  } else if (dM > 0) {
    thisC.highlightElt(calendar.$nextBtn);
  }
};

StateChooseDate.prototype.checkCalendar = function () {
  var elt = this.command.elt;
  var isOn = !!(elt.share.$calendar && elt.share.$calendar.isDescendantOf(document.body));

  if (isOn) {
    this.highlightTarget();
  } else {
    this.goto('check_value');
  }
};

StateChooseDate.prototype.ev_click = function () {
  this.checkIdx = setTimeout(this.checkCalendar.bind(this), 50);
};
/***
 * @extends BaseState
 * @param {BaseCommand} command
 * @constructor
 */


function UserDateInput_StateCheckValue(command) {
  scriptor_BaseState.call(this, command);
}

OOP["a" /* default */].mixClass(UserDateInput_StateCheckValue, scriptor_BaseState);

UserDateInput_StateCheckValue.prototype.onStart = function () {
  var value = this.args.value;
  var inputValue = this.command.elt.value;

  if (value === inputValue) {
    this.goto('finish');
  } else if (value && inputValue) {
    if (Object(datetime["compareDate"])(value, inputValue) === 0) {
      this.goto('finish');
    } else {
      this.command.hadWrongAction = true;
      this.goto('user_begin');
    }
  }
}; //To do: user focus to input

/***
 * @extends UserBaseAction
 * @constructor
 */


function UserDateInput() {
  scriptor_UserBaseAction.apply(this, arguments);
}

inheritCommand(UserDateInput, scriptor_UserBaseAction);
UserDateInput.prototype.name = 'userDateInput';
UserDateInput.prototype.argNames = ['eltPath', 'value', 'message', 'wrongMessage', 'inputTextHint'];
UserDateInput.prototype.stateClasses['user_begin'] = StateWaitCalendar;
UserDateInput.prototype.stateClasses['choose_date'] = StateChooseDate;
UserDateInput.prototype.stateClasses['check_value'] = UserDateInput_StateCheckValue;

UserDateInput.prototype._isFocus = function (elt) {
  return document.hasFocus() && document.activeElement === elt;
};

UserDateInput.prototype.verifyElt = function () {
  if (!this.elt.hasClass && !this.elt.hasClass('as-date-time-input')) {
    return new Error('Type error: not a date-input!');
  }
};

UserDateInput.prototype.requestUserAction = function () {
  var thisC = this;
  /***
   *
   * @type {DateInput2}
   */

  var elt = thisC.tutor.findNode(thisC.args.eltPath);
  this.assignTarget(elt);
  var message = this.args.message;
  var wrongMessage = this.args.wrongMessage;
  var inputTextHintFunc = this.args.inputTextHint && new Function('return ' + _TemplateString.default.parse(this.args.inputTextHint).toJSCode());

  inputTextHintFunc = inputTextHintFunc || function () {
    return null;
  };

  var inputTextHint;
  var value = this.args.value;
  return new Promise(function (resolve, reject) {
    thisC.onlyClickTo(elt);
    thisC.highlightElt(elt);
    var calendarOn = !!(elt.share.$calendar && elt.share.$calendar.isDescendantOf(document.body));
    /***
     * @type {ChromeCalendar}
     */

    var calendar;
    var lastKey;

    function onClick(event) {
      lastKey = null;
      checkCalendar();
      checkInput();
    }

    function onCalendarOpen() {
      calendar = elt.share.$calendar;
      thisC.onlyClickTo(elt.share.$calendar);
      thisC.highlightElt(elt.share.$calendar);
      onCalendarStep();
    }

    function onCalendarClose() {
      thisC.onlyClickTo(elt);
      thisC.highlightElt(elt);

      if (datetime["compareDate"](elt.value, value) === 0) {
        clearListener();
        resolve();
      }
    }

    function onCalendarStep() {
      var viewDate = calendar._viewDate;
      if (!viewDate) return;
      var dM = Object(datetime["compareMonth"])(value, viewDate);

      if (dM === 0) {
        $('.absol-chrome-calendar-week-in-mounth>div', calendar, function (dateElt) {
          if (dateElt.__date__ && datetime["compareDate"](dateElt.__date__, value) === 0 && !dateElt.containsClass('absol-chrome-calendar-not-in-month')) {
            thisC.highlightElt(dateElt);
          }
        });
      } else if (dM < 0) {
        thisC.highlightElt(calendar.$prevBtn);
      } else if (dM > 0) {
        thisC.highlightElt(calendar.$nextBtn);
      }
    }

    function checkCalendar() {
      setTimeout(function () {
        var isDisplay = !!(elt.share.$calendar && elt.share.$calendar.isDescendantOf(document.body));

        if (calendarOn !== isDisplay) {
          calendarOn = isDisplay;

          if (calendarOn) {
            onCalendarOpen();
          } else {
            onCalendarClose();
          }
        } else if (calendarOn) {
          onCalendarStep();
        }
      }, 10);
    }

    function onKeyUp(event) {
      lastKey = event.key;
      checkInput();
    }

    var prevented = false;

    function checkInput() {
      setTimeout(function () {
        inputTextHint = inputTextHintFunc.call(elt);

        if (thisC._isFocus(elt.$input) && lastKey !== 'Enter') {
          thisC.highlightElt(null);
          var text = elt.$input.value;

          try {
            var expectedValue = Object(datetime["parseDateString"])(text, elt.format || 'dd/mm/yyyy');

            if (!prevented && expectedValue && Object(datetime["compareDate"])(expectedValue, value) === 0) {
              var preventKey = function preventKey(event) {
                if (event.key.length === 1 && !event.ctrlKey && !event.altKey) {
                  event.preventDefault();
                }
              };

              var finishPrevent = function finishPrevent() {
                elt.$input.off('keydown', preventKey).off('blur', finishPrevent);
                clearInterval(checkIntv);
              };

              var checkIntv = setInterval(function () {
                if (document.activeElement !== elt.$input) finishPrevent();
              }, 100);
              elt.$input.on('keydown', preventKey).on('blur', finishPrevent);
              resolve();
            } else {
              if (inputTextHint) thisC.showTooltip(elt.$input, inputTextHint);
            }
          } catch (error) {
            if (inputTextHint) thisC.showTooltip(elt.$input, inputTextHint);
          }
        } else {
          if (Object(datetime["compareDate"])(elt.value, value) !== 0) {
            if (wrongMessage) thisC.showTooltip(elt, wrongMessage);
            if (lastKey !== 'Enter' && !(elt.share.$calendar && elt.share.$calendar.isDescendantOf(document.body))) thisC.highlightElt(elt);

            if (lastKey === 'Enter') {
              elt.$input.focus();
              elt.$input.select && elt.$input.select();
            }
          } else {
            clearListener();
            resolve();
          }
        }
      }, 10);
    }

    function clearListener() {
      document.body.removeEventListener('click', onClick);
      document.body.removeEventListener('keyup', onKeyUp);
    }

    thisC._rejectCb = function () {
      clearListener();
      reject();
    };

    document.body.addEventListener('click', onClick);
    document.body.addEventListener('keyup', onKeyUp);
  });
};

UserDateInput.attachEnv = function (tutor, env) {
  env.userDateInput = function (eltPath, value, message, wrongMessage, inputTextHint) {
    if (!value || !value.toDateString) throw new Error("Invalid value, value must be a DateTime!");
    return new UserDateInput(tutor, {
      eltPath: eltPath,
      value: value,
      message: message,
      wrongMessage: wrongMessage,
      inputTextHint: inputTextHint
    }).exec();
  };
};

scriptor_TutorEngine.installClass(UserDateInput);
scriptor_TutorNameManager.addAsync('userDateInput');
/* harmony default export */ var scriptor_UserDateInput = (UserDateInput);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/DateInYearInput.js
var DateInYearInput = __webpack_require__(87);

// CONCATENATED MODULE: ./js/scriptor/UserDateInYearInput.js







/***
 * @extends UserBaseAction
 * @constructor
 */

function UserDateInYearInput() {
  scriptor_UserBaseAction.apply(this, arguments);
}

OOP["a" /* default */].mixClass(UserDateInYearInput, scriptor_UserBaseAction);

UserDateInYearInput.prototype._isFocus = function (elt) {
  return document.hasFocus() && document.activeElement === elt;
};

UserDateInYearInput.prototype._waitOpenPicker = function () {
  var self = this;
  var elt = this.elt;
  return new Promise(function (resolve, reject) {
    function onClick() {
      setTimeout(function () {
        if (elt.share.$picker && elt.share.$picker.isDescendantOf(document.body)) {
          document.removeEventListener('click', onClick);
          self._rejectCb = null;
          resolve();
        }
      }, 10);
    }

    document.addEventListener('click', onClick);

    self._rejectCb = function () {
      document.removeEventListener('click', onClick);
      reject();
    };
  });
};

UserDateInYearInput.prototype._blinkCalendar = function () {
  var self = this;

  this._lockPicker();

  return new Promise(function (resolve, reject) {
    self.highlightElt(self.elt.share.$picker);
    self.onlyClickTo(self.elt.share.$picker);
    setTimeout(resolve, 500);

    self._rejectCb = function () {
      self._unlockPicker();

      reject();
    };
  });
};

UserDateInYearInput.prototype._lockPicker = function () {
  document.removeEventListener('click', this.elt.eventHandler.clickOut);
};

UserDateInYearInput.prototype._unlockPicker = function () {
  document.addEventListener('click', this.elt.eventHandler.clickOut);
};

UserDateInYearInput.prototype._waitChooseMonth = function () {
  var self = this;
  var value = this.args.value;
  return new Promise(function (resolve, reject) {
    self.highlightElt(null);
    self.elt.share.$picker.$months[value.month - 1 + 12].scrollIntoView();
    self.highlightElt(self.elt.share.$picker.$months[value.month - 1 + 12]);
    self.onlyClickTo(self.elt.share.$picker.$months[value.month - 1 + 12]);

    self._clickCb = function () {
      self.showTooltip(self.elt.share.$picker.$months[value.month - 1 + 12], self.args.wrongMessage);
    };

    function onClick() {
      self._clickCb = null;
      resolve();
    }

    self.elt.share.$picker.$months[value.month - 1 + 12].once('click', onClick);

    self._rejectCb = function () {
      self.elt.share.$picker.$months[value.month - 1 + 12].off('click', onClick);

      self._unlockPicker();

      reject();
    };
  });
};

UserDateInYearInput.prototype._waitChooseDate = function () {
  var self = this;
  var value = this.args.value;
  return new Promise(function (resolve, reject) {
    var dateElt = self.elt.share.$picker.$days[value.date - 1];
    self.highlightElt(dateElt);
    self.onlyClickTo(dateElt);

    function onClick() {
      resolve();
    }

    dateElt.once('click', onClick);

    self._rejectCb = function () {
      self._unlockPicker();

      dateElt.off('click', onClick);
      self.highlightElt(null);
      reject();
    };
  });
};

UserDateInYearInput.prototype._waitClose = function () {
  var self = this;
  return new Promise(function (resolve, reject) {
    self.highlightElt(self.elt);
    self.onlyClickTo(self.elt);
    var notNull = self.elt.notNull;
    self.elt.notNull = true;

    function onCLick(event) {
      self.elt.eventHandler.clickOut(event);
      self.elt.notNull = notNull;
      resolve();
    }

    self._clickCb = function () {
      self.showTooltip(self.elt, self.args.finishMessage || "Nhấn vào đây để xác nhận giá trị vừa chọn");
    };

    self.elt.once('click', onCLick);

    self._rejectCb = function () {
      self.elt.off('click', onCLick);
      self.elt.notNull = notNull;
      reject();
    };
  });
};

UserDateInYearInput.prototype.requestUserAction = function () {
  var thisC = this;
  /***
   *
   * @type {DateInYearInput}
   */

  var elt = thisC.tutor.findNode(thisC.args.eltPath);
  this.elt = elt;
  this.assignTarget(elt);
  var message = this.args.message;
  var wrongMessage = this.args.wrongMessage;
  this.highlightElt(elt);
  this.onlyClickTo(elt);

  this._clickCb = function () {
    this.showTooltip(elt, wrongMessage);
  }.bind(this);

  return this._waitOpenPicker().then(this._blinkCalendar.bind(this)).then(this._waitChooseMonth.bind(this)).then(this._waitChooseDate.bind(this)).then(this._waitClose.bind(this));
};

UserDateInYearInput.attachEnv = function (tutor, env) {
  env.userDateInYearInput = function (eltPath, value, message, wrongMessage, finishMessage) {
    return new UserDateInYearInput(tutor, {
      eltPath: eltPath,
      value: value,
      message: message,
      wrongMessage: wrongMessage,
      finishMessage: finishMessage
    }).exec();
  };
};

scriptor_TutorNameManager.addAsync('userDateInYearInput');
/* harmony default export */ var scriptor_UserDateInYearInput = (UserDateInYearInput);
// CONCATENATED MODULE: ./js/scriptor/UserFileInputBox.js




/***
 * @extends UserBaseAction
 * @constructor
 */

function UserFileInputBox() {
  scriptor_UserBaseAction.apply(this, arguments);
}

OOP["a" /* default */].mixClass(UserFileInputBox, scriptor_UserBaseAction);

UserFileInputBox.prototype._verifyInput = function (elt) {
  if (!elt.containsClass || !elt.containsClass('as-file-input-box')) {
    throw new Error('Type error: not a FileInputBox');
  } else if (!elt.allowUpload) {
    throw new Error('Element error: element is not allow upload(allowUpload=false)');
  }
};

UserFileInputBox.prototype._waitFile = function () {
  var self = this;
  var elt = this.elt;
  return new Promise(function (resolve, reject) {
    self.highlightElt(elt);
    self.onlyClickTo(elt);

    if (self.hadWrongAction && self.args.wrongMessage) {
      self.showTooltip(elt, self.args.wrongMessage);
    }

    var timeout = -1;

    function onClick() {
      self.highlightElt(null);
      self.onlyClickTo(null);
      timeout = setTimeout(waitFocus, 500);
    }

    elt.once('click', onClick);

    function waitFocus() {
      if (document.hasFocus()) {
        if (self.elt.value) {
          resolve(true);
        } else {
          resolve(false);
        }
      } else {
        timeout = setTimeout(waitFocus, 500);
      }
    }

    self._rejectCb = function () {
      elt.off('click', onClick);
      reject();
    };
  }).then(function (ok) {
    if (!ok) {
      self.hadWrongAction = true;
      return self._waitFile();
    }

    return true;
  });
};

UserFileInputBox.prototype.requestUserAction = function () {
  this.elt = this.tutor.findNode(this.args.eltPath);
  this.assignTarget(this.elt);

  this._verifyInput(this.elt);

  return this._waitFile();
};

UserFileInputBox.attachEnv = function (tutor, env) {
  env.userFileInputBox = function (eltPath, message, wrongMessage) {
    return new UserFileInputBox(tutor, {
      eltPath: eltPath,
      message: message,
      wrongMessage: wrongMessage
    }).exec();
  };
};

scriptor_TutorNameManager.addAsync('userFileInputBox');
scriptor_TACData.define('userFileInputBox', {
  type: 'function',
  args: [{
    name: 'eltPath',
    type: '(string|AElement)'
  }, {
    name: 'message',
    type: 'string'
  }, {
    name: 'wrongMessage',
    type: 'string'
  }]
});
/* harmony default export */ var scriptor_UserFileInputBox = (UserFileInputBox);
// CONCATENATED MODULE: ./js/scriptor/UserFileListInput.js




/***
 * @extends UserBaseAction
 * @constructor
 */

function UserFileListInput() {
  scriptor_UserBaseAction.apply(this, arguments);
}

OOP["a" /* default */].mixClass(UserFileListInput, scriptor_UserBaseAction);

UserFileListInput.prototype._verifyInput = function (elt) {
  if (!elt.containsClass || !elt.containsClass('as-file-list-input')) {
    throw new Error('Type error: not a FileInputBox');
  } else if (elt.readOnly) {
    throw new Error('Element error: element is not allow upload(allowUpload=false)');
  }
};

UserFileListInput.prototype._blinkInput = function () {
  var self = this;
  return new Promise(function (resolve, reject) {
    var timeout = setTimeout(function () {
      resolve();
    }, 500);

    self._rejectCb = function () {
      clearTimeout();
    };
  });
};

UserFileListInput.prototype._waitFile = function () {// var self = this;
  // var elt = this.elt;
  // return new Promise(function (resolve, reject) {
  //     self.highlightElt(elt);
  //     self.onlyClickTo(elt);
  //     var timeout = -1;
  //
  //     function onClick() {
  //         self.highlightElt(null);
  //         self.onlyClickTo(null);
  //         timeout = setTimeout(waitFocus, 500);
  //     }
  //
  //     elt.once('click', onClick);
  //
  //     function waitFocus() {
  //         if (document.hasFocus()) {
  //             if (self.elt.value) {
  //                 resolve(true);
  //             } else {
  //                 resolve(false);
  //             }
  //         } else {
  //             timeout = setTimeout(waitFocus, 500);
  //         }
  //     }
  //
  //     self._rejectCb = function () {
  //         elt.off('click', onClick);
  //         reject();
  //     }
  // }).then(function (ok) {
  //     if (!ok) return self._waitFile();
  //     return true;
  // });
};

UserFileListInput.prototype.requestUserAction = function () {
  this.elt = this.tutor.findNode(this.args.eltPath);
  this.assignTarget(this.elt);

  this._verifyInput(this.elt);

  return this._waitFile();
};

UserFileListInput.attachEnv = function (tutor, env) {
  env.userFileListInput = function (eltPath, fileCount, message, wrongMessage) {
    return new UserFileListInput(tutor, {
      eltPath: eltPath,
      fileCount: fileCount,
      message: message,
      wrongMessage: wrongMessage
    }).exec();
  };
};

scriptor_TutorNameManager.addAsync('userFileListInput');
scriptor_TACData.define('userFileListInput', {
  type: 'function',
  args: [{
    name: 'eltPath',
    type: '(string|AElement)'
  }, {
    name: 'fileCount',
    type: 'number'
  }, {
    name: 'message',
    type: 'string'
  }, {
    name: 'wrongMessage',
    type: 'string'
  }]
});
/* harmony default export */ var scriptor_UserFileListInput = (UserFileListInput);
// CONCATENATED MODULE: ./js/scriptor/Disappear.js







/***
 * @extends StateWaitEltAppear
 * @constructor
 */

function StateWaitEltDisappear() {
  StateWaitEltAppear.apply(this, arguments);
}

OOP["a" /* default */].mixClass(StateWaitEltDisappear, StateWaitEltAppear);

StateWaitEltDisappear.prototype.checkElt = function () {
  var now = new Date().getTime();
  this.timeOut = -1;
  var elt = this.command.findNode(this.args.eltPath, true);

  if (!this.isVisibility(elt)) {
    this.command.resolve(true);
  } else if (now > this.endTime) {
    this.command.resolve(false);
  } else {
    this.timeOut = setTimeout(this.checkElt.bind(this), Math.min(100, this.endTime - now));
  }
};
/***
 * @extends {BaseCommand}
 */


function Disappear() {
  scriptor_BaseCommand.apply(this, arguments);
}

inheritCommand(Disappear, scriptor_BaseCommand);
Disappear.prototype.className = 'Disappear';
Disappear.prototype.argNames = ['eltPath', 'timeout'];
Disappear.prototype.stateClasses.entry = StateWaitEltDisappear;
Disappear.prototype.name = 'DISAPPEAR';
Disappear.prototype.type = 'sync'; //it will return Promise

scriptor_TutorEngine.installClass(Disappear);
scriptor_TutorNameManager.addAsync('DISAPPEAR');
scriptor_TACData.define('DISAPPEAR', {
  type: 'function',
  args: [{
    name: 'eltPath',
    type: '(string|AElement)'
  }, {
    name: 'timeout',
    type: 'number'
  }],
  desc: "Trigger chờ element biến mất"
});
/* harmony default export */ var scriptor_Disappear = (Disappear);
// CONCATENATED MODULE: ./js/scriptor/expressionList.js
































var commandList = [scriptor_SetRootView, scriptor_Explain, scriptor_Timeout, scriptor_DateTime, scriptor_PressAnyKey, scriptor_ClickAnyWhere, scriptor_Earliest, scriptor_Latest, scriptor_ShowSnackBar, scriptor_Appear, scriptor_Disappear, scriptor_QuerySelector, scriptor_UserClick, scriptor_UserCheckbox, scriptor_UserInputText, scriptor_UserSelectMenu, scriptor_ShowToastMessage, scriptor_ShowConfirmToast, scriptor_UserCalendarInput, scriptor_UserDateInput, scriptor_UserQuickMenu, scriptor_UserLevel2Menu, scriptor_UserSwitchTabIfNeed, scriptor_UserSwitchTab, scriptor_Delay, scriptor_UserScrollIfNeed, scriptor_UserMultiSelectMenu, scriptor_UserDateInYearInput, scriptor_UserFileInputBox, scriptor_UserFileListInput, scriptor_Net, scriptor_Logger];
/* harmony default export */ var expressionList = (commandList);
// CONCATENATED MODULE: ./js/buildTutorJavaScript.js


var buildTutorJavaScript_traverse = babel.traverse;
var buildTutorJavaScript_parse = babel.parse;
var buildTutorJavaScript_babelTypes = babel.types;
var buildTutorJavaScript_presetEnv = babel.presetEnv;
var buildTutorJavaScript_generator = babel.generator;

function moduleTemplate(code, argNames) {
  return 'module.exports = async function exec(' + argNames.join(',') + ') {\n' + code + '\nreturn 0;' + '}';
}

function awaitInject(code, ast, asyncFunctionNames) {
  var dict = asyncFunctionNames.reduce(function (ac, cr) {
    ac[cr] = true;
    return ac;
  }, {});
  buildTutorJavaScript_traverse(ast, {
    ExpressionStatement: function ExpressionStatement(path) {
      if (path.node.ignore) return;
      if (path.node.loc.start.line === 1) return;

      var _db = babel.types.callExpression(babel.types.identifier("_db"), [babel.types.numericLiteral(path.node.loc.start.line), babel.types.numericLiteral(path.node.loc.start.column), babel.types.numericLiteral(path.node.start), babel.types.numericLiteral(path.node.end)]);

      _db.ignore = true;
      path.insertBefore(_db);
    },
    CallExpression: function CallExpression(path) {
      var needUpdate = false;

      if (path.parent.type === 'AwaitExpression') {
        needUpdate = true;
      } else {
        var node = path.node;
        var callee = node.callee;
        var calleeName = code.substr(callee.start, callee.end - callee.start);

        if (dict[calleeName]) {
          var newNode = buildTutorJavaScript_babelTypes.awaitExpression(node);
          path.replaceWith(newNode);
          needUpdate = true;
        }
      }

      if (needUpdate) {
        var p = path;
        var pNode;

        while (p) {
          pNode = p.node;

          if (pNode.type === 'FunctionDeclaration') {
            pNode.async = true;
            dict[pNode.id.name] = true;
            break;
          }

          p = p.parentPath;
        }
      }
    }
  });
  return ast;
}

function buildTutorJavaScript(code) {
  var argNames = scriptor_TutorNameManager.getAll();
  code = moduleTemplate(code, argNames);
  var ast = buildTutorJavaScript_parse(code);
  awaitInject(code, ast, scriptor_TutorNameManager.getAllAsync());
  var options = {
    presets: [buildTutorJavaScript_presetEnv]
  };
  var newCode = buildTutorJavaScript_generator(ast, {}, code).code;
  var transformedCode = babel.transform(newCode, options).code;
  var m = {};
  var execFn = new Function('module', 'regeneratorRuntime', transformedCode);
  execFn(m, runtime_default.a);
  return {
    argNames: argNames,
    exec: m.exports,
    code: code,
    es6Code: newCode,
    transformedCode: transformedCode
  };
}
// CONCATENATED MODULE: ./js/util/findAllNode.js



function findAllNode(query, root) {
  if (Object(Dom["e" /* isDomNode */])(query)) return $(query);
  root = root || document.body;
  if (typeof query != 'string') return null;
  var tutorPath = js_TutorPath.compile(query);
  var res = tutorPath.findAll(root);
  if (res && res.length > 0) res.forEach(function (e) {
    $(e);
  });
  return res;
}
// CONCATENATED MODULE: ./node_modules/absol/src/String/stringUtils.js
function stringHashCode(st) {
    var hash = 0, i, chr;
    if (st.length === 0) return hash;
    for (i = 0; i < st.length; i++) {
        chr = st.charCodeAt(i);
        hash = ((hash << 5) - hash) + chr;
        hash |= 0; // Convert to 32bit integer
    }
    return hash;
}
// CONCATENATED MODULE: ./js/Tutor.js










/***
 * @augments Context
 * @param view
 * @param script
 * @param option
 * @constructor
 */

function Tutor(view, script, option) {
  EventEmitter["b" /* default */].call(this);
  AppPattern_Context.call(this);
  this.$view = view;
  /***
   *
   * @type {*|TProgram}
   */

  this.prorgram = this.programCache[stringHashCode(script)] || scriptor_TutorEngine.compile(script);
  /***
   *
   * @type {TProcess}
   */

  this.process = this.prorgram.newProcess();
  this.process.tutor = this;
  this.option = Object.assign({
    messageDelay: 300
  }, option);
  this.debug.status = 'NOT_START';
}

OOP["a" /* default */].mixClass(Tutor, EventEmitter["b" /* default */], AppPattern_Context);
Tutor.prototype.programCache = {};

Tutor.prototype.exec = function () {
  this.debug.status = "RUNNING";
  return this.process.exec().then(function (result) {
    this.debug.status = "FINISH";
    return result;
  }.bind(this)).catch(function (error) {
    Object(safeThrow["a" /* default */])(error);

    if (error instanceof Error) {
      this.debug.status = "ERROR";
      throw error;
    }
  }.bind(this));
};

Tutor.prototype.stop = function () {
  this.process.stop();
};

Tutor.prototype.findNode = function (query, unsafe) {
  var elt = findNode(query, this.$view);
  if (!elt && !unsafe) throw new Error('Can not find element with query="' + query + '"');
  return elt;
};

Tutor.prototype.findAllNode = function (query) {
  return findAllNode(query, this.$view);
};

Tutor.prototype.getStatus = function () {
  if (this.debug.status === "NOT_START") return {
    status: "NOT_START"
  };
  if (this.debug.status === "RUNNING" || this.debug.status === "ERROR") return {
    status: this.debug.status,
    code: this.process.program.code.substr(this.debug.loc.start, this.debug.loc.end - this.debug.loc.start),
    row: this.debug.loc.row - 1,
    col: this.debug.loc.col
  };
  return {
    status: "FINISH"
  };
};

Object.defineProperty(Tutor.prototype, 'debug', {
  get: function get() {
    return this.process.debug;
  }
});
/* harmony default export */ var js_Tutor = (Tutor);
// CONCATENATED MODULE: ./js/runScriptFromUrl.js

function runScriptFromUrl(url, elt) {
  return fetch(url).then(function (res) {
    return res.text();
  }).then(function (text) {
    elt = elt || document.body;
    var tutor = new js_Tutor(elt, text);
    return tutor.exec();
  });
}
;
// EXTERNAL MODULE: ./node_modules/absol-brace/index.js + 10 modules
var absol_brace = __webpack_require__(81);

// EXTERNAL MODULE: ./css/spliteditor.css
var spliteditor = __webpack_require__(340);

// EXTERNAL MODULE: ./node_modules/absol-form/css/cmdtool.css
var cmdtool = __webpack_require__(342);

// EXTERNAL MODULE: ./css/ace.css
var css_ace = __webpack_require__(344);

// CONCATENATED MODULE: ./js/scriptor/TutorACECompleter.js
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }





function TutorACECompleter() {
  this.name = 'absol';
  this.spaceRex = /\s+/;
  this.structIdent = {
    identifier: true,
    'variable.language': true,
    'support.constant': true
  };
}

TutorACECompleter.prototype._getArgs = function (func) {
  var args = (func.toString().match(/function\s.*?\(([^)]*)\)/) || ['', ''])[1];
  return args.split(',').map(function (arg) {
    return arg.replace(/\/\*.*\*\//, '').trim();
  }).filter(function (arg) {
    return arg;
  });
};

TutorACECompleter.prototype._jsTrackStruct = function (session, pos, prefix) {
  var res = [];
  var track = [];
  var tokenIto = new ace.TokenIterator(session, pos.row, pos.column);
  var firstToken;

  while (true) {
    var token = tokenIto.getCurrentToken();
    if (token == undefined) break;

    if (!this.spaceRex.test(token.value)) {
      if (token.value != '.' && !this.structIdent[token.type]) break;
      if (!firstToken) firstToken = token.value;

      if (this.structIdent[token.type]) {
        track.push(token.value);
      }
    }

    tokenIto.stepBackward();
  }

  if (firstToken !== '.' && track.length > 0 && prefix === track[0]) track.shift();
  var currentKey;
  var currentObj = scriptor_TACData;

  for (var i = track.length - 1; i >= 0; --i) {
    currentKey = track[i];
    currentObj = currentObj.properties && currentObj.properties[currentKey];
    if (!currentObj) break;
  }

  if (currentObj) {
    var keyHolders = Object.keys(currentObj.properties).map(function (key) {
      var score = 0;

      if (key.startsWith(prefix)) {
        score += 1 + prefix.length / (key.length + 1);
      }

      if (prefix.length > 0) score += Object(stringMatching["wordLike"])(key, prefix);
      return {
        key: key,
        score: score
      };
    });
    keyHolders.sort(function (a, b) {
      return b.score - a.score;
    });
    keyHolders.forEach(function (holder) {
      var item = {
        name: holder.key,
        value: holder.key,
        score: 1000000 + holder.score * 100,
        meta: 'tutor'
      };
      var propertyDesc = currentObj.properties && currentObj.properties[holder.key];

      if (propertyDesc) {
        item.type = propertyDesc.type;

        if (item.type === 'function') {
          item.args = propertyDesc.args;
          item.returns = propertyDesc.returns;
          item.desc = propertyDesc.desc;
        }
      }

      res.push(item);
    });
  }

  return res;
};

TutorACECompleter.prototype._jsTrackLocalValue = function (session, pos, prefix) {
  var res = [];
  var tokenIto = new ace.TokenIterator(session, pos.row, pos.column);
  var currentToken = tokenIto.getCurrentToken();

  if (currentToken && currentToken.value === prefix || pos.column == 0) {
    tokenIto.stepBackward();
    currentToken = tokenIto.getCurrentToken();
  }

  if (currentToken && currentToken.value === '.') return res;
  var lastIdentifier = false;

  while (currentToken) {
    if (currentToken.type === "identifier") {
      lastIdentifier = currentToken.value;
    } else if (currentToken.type === 'storage.type') {
      if (lastIdentifier) {
        var item = {
          value: lastIdentifier,
          meta: currentToken.value,
          score: 1000001
        };
        res.push(item);
        lastIdentifier = false;
      }
    } else if (!this.spaceRex.test(currentToken.value)) {
      lastIdentifier = false;
    }

    tokenIto.stepBackward();
    currentToken = tokenIto.getCurrentToken();
  }

  return res;
};

TutorACECompleter.prototype.getCompletions = function (editor, session, pos, prefix, callback) {
  if (session.getMode().$id !== "ace/mode/javascript") {
    callback(null, []);
    return;
  }

  var completions = [];
  completions.push.apply(completions, this._jsTrackStruct(session, pos, prefix));
  completions.push.apply(completions, this._jsTrackLocalValue(session, pos, prefix));
  completions.sort(function (a, b) {
    if (a.score !== b.score) return a.score - b.score;
    var x = a.value.toUpperCase();
    var y = b.value.toUpperCase();
    return x === y ? 0 : x > y ? 1 : -1;
  });
  callback(null, completions);
};

TutorACECompleter.prototype.getDocTooltip = function (item) {
  if (item.type === "function" && !item.docHTML) {
    var html = ['<div class="atr-ace-tooltip-define">', '<span class="ace_storage ace_type">function</span>', '<span class="ace_paren ace_lparen">(</span>'].concat([item.args.map(function (arg) {
      if (_typeof(arg) === "object") {
        arg = arg.name + ':' + arg.type;
      }

      return '<span class="ace_identifier">' + arg + '</span>';
    }).join('<span class="ace_punctuation ace_operator">, </span>')]).concat(['<span class="ace_paren ace_rparen">)</span>']);

    if (item.returns) {
      html.push('<span>:' + item.returns + '</span>');
    }

    html.push('</div>');

    if (item.desc) {
      html.push('<p class="atr-ace-tooltip-desc">' + item.desc + '</p>');
    }

    item.docHTML = html.join("");
  }
};

if (window.ace) {
  var langTools = ace.acequire('ace/ext/language_tools');
  ace.TokenIterator = ace.TokenIterator || ace.acequire("ace/token_iterator").TokenIterator;
  if (langTools) langTools.addCompleter(new TutorACECompleter()); // data stub:

  var sqlTables = [{
    name: 'users',
    description: 'Users in the system'
  }, {
    name: 'userGroups',
    description: 'User groups to which users belong'
  }, {
    name: 'customers',
    description: 'Customer entries'
  }, {
    name: 'companies',
    description: 'Legal entities of customers'
  }, {
    name: 'loginLog',
    description: 'Log entries for user log-ins'
  }, {
    name: 'products',
    description: 'Products offered in the system'
  }, {
    name: 'productCategories',
    description: 'Different product categories'
  }];
}

/* harmony default export */ var scriptor_TutorACECompleter = (TutorACECompleter);
// CONCATENATED MODULE: ./js/app/SplitEditor.js







/***
 * @augments Fragment
 * @param channel
 * @param id
 * @constructor
 */

function SplitEditor(channel, id) {
  AppPattern_Fragment.call(this);
}

OOP["a" /* default */].mixClass(SplitEditor, AppPattern_Fragment);

SplitEditor.prototype.createView = function () {
  this.$view = Core_({
    class: "atr-split-editor",
    child: ['p.atr-split-editor-ace']
  });
  this.$editor = $('p.atr-split-editor-ace', this.$view);
  this.editor = absol_brace["a" /* default */].ace.edit(this.$editor);
  this.editor.getSession().setMode("ace/mode/javascript");
  this.editor.setOptions({
    enableBasicAutocompletion: true,
    enableSnippets: true,
    enableLiveAutocompletion: false
  });

  if (window['TUTOR_LOCAL_SAVE']) {
    this.editor.on('change', this.localSaveDelay.bind(this));
  }
};

SplitEditor.prototype.localSaveDelay = function () {
  var thisSE = this;

  if (this._saveTimeout >= 0) {
    clearTimeout(this._saveTimeout);
  }

  this._saveTimeout = setTimeout(function () {
    var script = thisSE.editor.getValue();
    localStorage.setItem('TUTOR_MASTER_SCRIPT', script);
  }, 1000);
};

SplitEditor.prototype.setValue = function (data) {
  this.editor.setValue(data);
};

SplitEditor.prototype.getValue = function () {
  return this.editor.getValue();
};

/* harmony default export */ var app_SplitEditor = (SplitEditor);
// EXTERNAL MODULE: ./css/tutormaster.css
var tutormaster = __webpack_require__(346);

// EXTERNAL MODULE: ./css/fragmanager.css
var fragmanager = __webpack_require__(348);

// EXTERNAL MODULE: ./node_modules/absol-form/css/propertyeditor.css
var propertyeditor = __webpack_require__(350);

// EXTERNAL MODULE: ./node_modules/absol-acomp/js/OnsScreenWindow.js
var OnsScreenWindow = __webpack_require__(55);

// CONCATENATED MODULE: ./js/app/FlagManager.js






/***
 * @extends Fragment
 * @constructor
 */

function FlagManager_FlagManager() {
  AppPattern_Fragment.call(this);
  this.flag = {};
  this.readSetting();
}

OOP["a" /* default */].mixClass(FlagManager_FlagManager, AppPattern_Fragment);
FlagManager_FlagManager.prototype.STORE_KEY = "ABSOL_FLAG";

FlagManager_FlagManager.prototype.readSetting = function () {
  var flagText = localStorage.getItem(this.STORE_KEY) || '{}';
  var newFlag = {};

  try {
    newFlag = JSON.parse(flagText);
  } catch (err) {}

  this.applyFlag(newFlag);
};

FlagManager_FlagManager.prototype.applyFlag = function (newFlag, save) {
  Object.keys(Object.assign({}, this.flag, newFlag)).forEach(function (key) {
    if (key in window) {
      if (key in newFlag) {
        window[key] = newFlag[key];
      } else {
        delete window[key];
      }
    } else {
      if (key in newFlag) {
        window[key] = newFlag[key];
      }
    }
  });
  this.flag = newFlag;
  if (save) this.saveSetting();
};

FlagManager_FlagManager.prototype.saveSetting = function () {
  localStorage.setItem(this.STORE_KEY, JSON.stringify(this.flag));
};

FlagManager_FlagManager.prototype.createView = function () {
  /****
   * @type {OnScreenWindow}
   */
  this.$view = Core_({
    tag: 'onscreenwindow',
    class: 'atr-flag-manager',
    style: {
      width: '400px',
      height: '400px',
      top: '20px',
      left: 'calc(100vw - 420px)'
    },
    props: {
      windowTitle: "Flag Manager"
    },
    child: [{
      class: ['as-property-editor', 'as-bscroller'],
      style: {
        width: '100%',
        height: '100%',
        overflow: 'auto'
      },
      child: {
        tag: 'table',
        style: {
          width: '100%'
        },
        child: ['<thead><tr><td>key</td><td>value</td><td></td></tr></thead>', {
          tag: 'tbody',
          child: [{
            tag: 'tr',
            class: 'atr-add-flag-row',
            child: [{
              tag: 'td',
              attr: {
                colspan: '3'
              },
              style: {
                textAlign: 'center'
              },
              child: 'span.mdi.mdi-plus'
            }]
          }]
        }]
      }
    }]
  });
  this.$tbody = $('.as-property-editor tbody', this.$view);
  this.$addRow = $('.atr-add-flag-row', this.$view).on('click', this._addRow.bind(this, '', false));

  for (var key in this.flag) {
    this._addRow(key, this.flag[key]);
  }

  this.$view.$minimizeBtn.addStyle('display', 'none');
  this.$view.$dockBtn.addStyle('display', 'none');
  this.$view.$closeBtn.on('click', this.stop.bind(this));
};

FlagManager_FlagManager.prototype.onResume = function () {
  var view = this.getView();

  if (!view.isDescendantOf(document.body)) {
    document.body.appendChild(view);
  }
};

FlagManager_FlagManager.prototype._updateInputColor = function () {
  var dict = {};
  $('input.atr-flag-name', this.$tbody, function (inputELt) {
    var value = inputELt.value.trim();

    if (value) {
      if (dict[value]) {
        inputELt.addStyle('border-color', 'red');
      } else {
        inputELt.removeStyle('border-color');
        dict[value] = true;
      }
    } else {
      inputELt.addStyle('border-color', 'rgb(150, 255, 0)');
    }
  });
};

FlagManager_FlagManager.prototype._getFlagFromInput = function () {
  var res = {};
  $('.atr-flag-row', this.$tbody, function (rowElt) {
    var p = rowElt.getFlag && rowElt.getFlag();

    if (p) {
      res[p.key] = p.value;
    }
  });
  return res;
};

FlagManager_FlagManager.prototype._addRow = function (key, value) {
  var thisFM = this;

  var newRow = Core_({
    tag: 'tr',
    class: 'atr-flag-row',
    child: ['td', 'td', 'td']
  });

  var name = Core_('input.atr-flag-name').addTo(newRow.childNodes[0]);

  name.value = key || '';

  var value = Core_({
    tag: 'selectmenu',
    props: {
      items: [{
        text: 'TRUE',
        value: true
      }, {
        text: 'FALSE',
        value: false
      }],
      value: !!value
    }
  }).addStyle('width', '50px').addTo(newRow.childNodes[1]);

  value.on('change', function () {
    thisFM.applyFlag(thisFM._getFlagFromInput(), true);
  });

  var deleteBtn = Core_('span.mdi.mdi-trash-can-outline').addTo(newRow.childNodes[2]).on('click', function () {
    newRow.remove();
    thisFM.applyFlag(thisFM._getFlagFromInput(), true);
  });

  name.on('change', function () {
    thisFM.applyFlag(thisFM._getFlagFromInput(), true);
  }).on('keyup', function (event) {
    if (event.key === 'Enter') {
      this.blur();
    }

    thisFM._updateInputColor();
  });
  this.$tbody.addChildBefore(newRow, this.$addRow);

  newRow.getFlag = function () {
    if (name.value) return {
      key: name.value,
      value: value.value
    };
  };

  this._updateInputColor();
};

FlagManager_FlagManager.prototype.onPause = function () {
  var view = this.getView();

  if (view.isDescendantOf(document.body)) {
    view.remove();
  }
};
/***
 *
 * @param {string} key
 * @param {boolean=} value
 */


FlagManager_FlagManager.prototype.add = function (key, value) {
  if (!key || typeof key != 'string') return;
  if (key in this.flag) return;

  if (typeof value != "boolean") {
    value = !!window[key];
  }

  window[key] = value;
  this.flag[key] = value;
  this.saveSetting();
  if (this.$view) this._addRow(key, value);
};

/* harmony default export */ var app_FlagManager = (new FlagManager_FlagManager());
// EXTERNAL MODULE: ./css/inspector.css
var inspector = __webpack_require__(352);

// CONCATENATED MODULE: ./node_modules/absol-form/js/core/BaseEditor.js




/***
 *
 * @constructor
 * @augments Fragment
 * @augments EventEmitter
 */
function BaseEditor() {
    EventEmitter["b" /* default */].call(this);
    AppPattern_Fragment.call(this);
    this.cmdRunner = new CMDRunner["a" /* default */](this);
    this.cmdBindKeys = {};
    this.loadConfig();
}


Object.defineProperties(BaseEditor.prototype, Object.getOwnPropertyDescriptors(EventEmitter["b" /* default */].prototype));
Object.defineProperties(BaseEditor.prototype, Object.getOwnPropertyDescriptors(AppPattern_Fragment.prototype));
BaseEditor.prototype.constructor = BaseEditor;

BaseEditor.prototype.CONFIG_STORE_KEY = "AS_BaseEditor_config";
BaseEditor.prototype.config = {};//share width differentInstance

BaseEditor.prototype.loadConfig = function () {
    var raw = localStorage.getItem(this.CONFIG_STORE_KEY);
    if (raw) {
        try {
            Object.assign(this.config, JSON.parse(raw));
        }
        catch (error) {
            console.error("Config fail:", error);
        }
    }
};


BaseEditor.prototype.saveConfig = function () {
    if (this._saveConfigTimeOut > 0) {
        clearTimeout(this._saveConfigTimeOut);
        this._saveConfigTimeOut = -1;
    }
    var self = this;
    setTimeout(function () {
        var raw = JSON.stringify(self.config);
        localStorage.setItem(self.CONFIG_STORE_KEY, raw);
    }, 2000);
};


BaseEditor.prototype.setData = function (data) {
    throw new Error('Not implement!');
};

BaseEditor.prototype.getData = function () {
    throw new Error('Not implement!');
};

BaseEditor.prototype.getComponentTool = function () {
    return undefined;
};

BaseEditor.prototype.getOutlineTool = function () {
    return undefined;
};

BaseEditor.prototype.notifyDataChange = function () {
    this.emit('datachange', { type: 'datachange', target: this }, this);
};



BaseEditor.prototype.execCmd = function () {
    return this.cmdRunner.invoke.apply(this.cmdRunner, arguments);
};


BaseEditor.prototype.getCmdNames = function () {
    return [];
};


BaseEditor.prototype.getCmdDescriptors = function () {
    var self = this;
    return this.getCmdNames().reduce(function (ac, name) {
        ac[name] = self.getCmdDescriptor(name);
        return ac;
    }, {});
};


BaseEditor.prototype.getCmdDescriptor = function (name) {
    return {
        type: 'trigger',
        args: [],
        desc: '',
        bindKey: undefined
    };
};

BaseEditor.prototype.notifyCmdDescriptorsChange = function () {
    this.emit('cmddescriptorschange', { type: 'cmddescriptorschange' }, this);
};

BaseEditor.prototype.notifyCmdChange = function(){
    this.emit('cmdchange', { type: 'cmdchange' }, this);
};


BaseEditor.prototype.getCmdGroupTree = function () {
    return [];
};

BaseEditor.prototype.bindKeyToCmd = function (key, cmd) {
    this.cmdBindKeys[key] = cmd;
};


BaseEditor.prototype._isInputSupportedKey = function (target, key){
    if (target.tagName && target.tagName.toLowerCase().match(/input|textarea/)){
        if (['Ctrl-A','Ctrl-C', 'Ctrl-X','Ctrl-V', 'Ctrl-Z', 'Ctrl-Y', 'Delete', 'Backspace',
            'Esc', 'Enter', 'Alt-Enter', 'Ctrl-Enter'].indexOf(key)>=0){
            return true;
        }
    }
    return false;
}

/**
 * @param {KeyboardEvent}event
 */
BaseEditor.prototype.ev_cmdKeyDown = function (event) {
    var specKeys = [];
    if (event.ctrlKey)
        specKeys.push('Ctrl');
    if (event.shiftKey)
        specKeys.push('Shift');
    if (event.altKey)
        specKeys.push('Alt');
    var key = event.key;
    if (key.length == 1) key = key.toUpperCase();
    var key1 = specKeys.concat([key]).join('-');
    var key2 = specKeys.concat([event.keyCode]).join('-');
    var cmd = this.cmdBindKeys[key1] || this.cmdBindKeys[key2];
    if (cmd && !this._isInputSupportedKey(event.target, key1)) {
        this.execCmd(cmd, event);
        event.preventDefault();
    }
};


/* harmony default export */ var core_BaseEditor = (BaseEditor);
// EXTERNAL MODULE: ./node_modules/absol-acomp/js/ExpTree.js
var ExpTree = __webpack_require__(22);

// CONCATENATED MODULE: ./js/app/Inspector.js












/***
 * @extends BaseEditor
 * @constructor
 */

function Inspector() {
  core_BaseEditor.call(this);
  this.ev_mouseenter = this.ev_mouseenter.bind(this);

  this._createBox();

  this._createTreeWindow();
}

OOP["a" /* default */].mixClass(Inspector, core_BaseEditor);
Inspector.prototype.CONFIG_STORE_KEY = "TUTOR_INSPECTOR_SETTING";
Inspector.prototype.config = {
  inspectedTreeWindow: {
    x: 1,
    y: 58,
    width: 15,
    height: 40
  }
};

Inspector.prototype.onResume = function () {
  document.body.addEventListener('mouseover', this.ev_mouseenter);
  this.$treeWindow.addTo(document.body);
};

Inspector.prototype.onPause = function () {
  document.body.removeEventListener('mouseover', this.ev_mouseenter);
  this.$box.remove();
  this.$treeWindow.remove();
};

Inspector.prototype._createBox = function () {
  this.$box = Core_({
    class: 'atr-inspector-rect',
    child: {
      class: 'atr-inspector-rect-text',
      child: {
        text: ''
      }
    }
  });
  this.$text = $('.atr-inspector-rect-text', this.$box);
};

Inspector.prototype._createTreeWindow = function () {
  this.$treeWindow = Core_({
    tag: OnsScreenWindow["a" /* default */].tag,
    style: {
      zIndex: 1900000000,
      top: this.config.inspectedTreeWindow.y + 'vh',
      left: this.config.inspectedTreeWindow.x + 'vw',
      width: this.config.inspectedTreeWindow.width + 'vw',
      height: this.config.inspectedTreeWindow.height + 'vh'
    },
    props: {
      windowTitle: 'Inspected Tree'
    },
    child: [{
      class: 'atr-inspector-tree-ctn',
      child: {
        tag: ExpTree["c" /* default */].tag,
        props: {
          name: ':root',
          icon: 'span.mdi.mdi-source-commit-start-next-local',
          status: 'open'
        }
      }
    }, {
      class: 'atr-inspector-tree-footer',
      child: {
        text: 'Tip: click to copy path'
      }
    }]
  });
  /***
   *
   * @type {ExpTree}
   */

  this.$tree = $('exptree', this.$treeWindow);
};

Inspector.prototype.tag2Icon = {
  'default': 'span.mdi.mdi-source-commit-start-next-local',
  'selectmenu': 'span.mdi.mdi-menu-open',
  'quickmenutrigger': 'span.mdi.mdi-dots-vertical-circle-outline',
  'checkbox': 'span.mdi.mdi-check-box-outline',
  'text-input': 'span.mdi.mdi-form-textbox'
};
/**
 *
 * @param {Array<string>} path
 * @param {string} tagName
 */

Inspector.prototype.addNode = function (path, tagName) {
  var current = this.$tree;
  var prev = null;

  for (var i = 0; i < path.length; ++i) {
    prev = current;
    prev.status = 'open';
    current = prev.accessByPath([path[i]]);

    if (!current) {
      current = Core_({
        tag: ExpTree["c" /* default */].tag,
        extendEvent: 'contextmenu',
        props: {
          name: path[i]
        },
        on: {
          press: function press(event) {
            var path = this.getPath();
            path.shift();
            copyText(JSON.stringify(path.join(' ')));
            Snackbar["a" /* default */].show('Copy: ' + JSON.stringify(path.join(' ')));
          }
        }
      });

      if (i + 1 === path.length) {
        current.icon = this.tag2Icon[tagName] || this.tag2Icon.default;
      } else {
        current.icon = this.tag2Icon.default;
      }

      prev.addChild(current);
    }

    if (i + 1 === path.length) {
      if (this.$lastActiveNode) {
        this.$lastActiveNode.active = false;
      }

      this.$lastActiveNode = current;
      this.$lastActiveNode.active = true;
      Object(utils["vScrollIntoView"])(this.$lastActiveNode.getNode());
    }
  }
};

Inspector.prototype.ev_mouseenter = function (event) {
  if (!event.ctrlKey) return;
  var target = event.target;
  var elt;
  var idPath = [];
  var tooltipText = [];

  while (target) {
    if (target.classList.contains('absol-selectlist-item') && !(target.parentElement && target.parentElement.classList.contains('absol-selectmenu-holder-item'))) {
      elt = target;
      break;
    }

    var tutorId = target.getAttribute('data-tutor-id') || target['data-tutor-id'] || target['data-tutor-id'];

    if (tutorId) {
      if (!elt) elt = target;
      idPath.unshift(tutorId);
    }

    target = target.parentElement;
  }

  target = elt;
  var tagName = 'default';

  if (target) {
    if (idPath.length > 0) {
      tooltipText.push('id = ' + JSON.stringify(idPath[idPath.length - 1]));
      if (idPath.length > 1) tooltipText.push('path = ' + JSON.stringify(idPath.join(' ')));
      if (target.classList.contains('absol-selectmenu')) tagName = 'selectmenu';
      if (target.classList.contains('as-quick-menu-trigger')) tagName = 'quickmenutrigger';
      if (target.classList.contains('absol-checkbox')) tagName = 'checkbox';
      if (target.tagName === 'INPUT' && target.type === 'text') tagName = 'text-input';
      this.addNode(idPath, tagName);
    }

    if (target.classList.contains('absol-selectlist-item') || target.classList.contains('absol-selectmenu')) {
      if (target.value === 0 || target.value) tooltipText.push('value= <strong>' + target.value + '</strong>');
    }

    if (tooltipText.length > 0) {
      this.$text.innerHTML = tooltipText.join('  ');
      var bound = target.getBoundingClientRect();
      this.$box.addStyle({
        width: bound.width + 2 + 'px',
        height: bound.height + 2 + 'px',
        left: bound.left - 1 + 'px',
        top: bound.top - 1 + 'px'
      }).addTo(document.body);
      var textBound = this.$text.getBoundingClientRect();
      var screen = Object(Dom["d" /* getScreenSize */])();

      if (bound.top < textBound.height) {
        this.$box.addClass('atr-bottom');
      } else {
        this.$box.removeClass('atr-bottom');
      }

      if (bound.left + textBound.width > screen.width) {
        this.$box.addClass('atr-left');
      } else {
        this.$box.removeClass('atr-left');
      }
    }
  }

  if (!target) {
    this.$box.remove();
  }
};

/* harmony default export */ var app_Inspector = (Inspector);
// CONCATENATED MODULE: ./js/app/TutorMaster.js














var dependentSrc = $('script', false, function (elt) {
  if (elt.src && elt.src.indexOf('absol.dependents.js') >= 0) {
    return true;
  }
});
dependentSrc = dependentSrc && dependentSrc.src;
var tutorSrc = document.currentScript.src;
app_FlagManager.add('TUTOR_LOCAL_SAVE', true);
/***
 * @extends BaseEditor
 * @constructor
 */

function TutorMaster() {
  core_BaseEditor.call(this);
  this.script = window['TUTOR_LOCAL_SAVE'] && localStorage.getItem('TUTOR_MASTER_SCRIPT') || '';
  this.inspector = new app_Inspector();
  this.splitEditor = new app_SplitEditor();
}

OOP["a" /* default */].mixClass(TutorMaster, core_BaseEditor);
TutorMaster.prototype.CONFIG_STORE_KEY = 'TUTOR_MASTER_SETTING';
TutorMaster.prototype.config = {
  editor: {
    width: 48,
    height: 48,
    x: 2,
    y: 50
  },
  toolbar: {
    x: 0.999,
    y: 0.999
  }
};

TutorMaster.prototype.createView = function () {
  this.$view = Core_({
    style: {
      '--tutor-master-x': this.config.toolbar.x,
      '--tutor-master-y': this.config.toolbar.y
    },
    class: 'atr-tutor-master',
    child: [{
      tag: 'hanger',
      class: 'atr-tutor-master-head',
      child: TutorIco.cloneNode(true),
      on: {
        dragstart: this.ev_headerDragStart.bind(this),
        drag: this.ev_headerDrag.bind(this)
      }
    }, {
      tag: 'button',
      attr: {
        title: 'Import File Script'
      },
      class: ['as-from-tool-button', 'atr-import-btn'],
      child: 'span.mdi.mdi-file-import'
    }, {
      tag: 'button',
      attr: {
        title: 'Edit Script'
      },
      class: ['as-from-tool-button', 'atr-edit-script-btn'],
      child: 'span.mdi.mdi-script-text-outline'
    }, {
      tag: 'button',
      attr: {
        title: 'Play'
      },
      class: ['as-from-tool-button', 'atr-play-btn'],
      child: 'span.mdi.mdi-play'
    }, {
      tag: 'button',
      class: ['as-from-tool-button', 'atr-stop-btn'],
      child: 'span.mdi.mdi-stop'
    }, {
      tag: 'button',
      attr: {
        title: 'Download Script'
      },
      class: ['as-from-tool-button', 'atr-download-btn'],
      child: 'span.mdi.mdi-cloud-download'
    }, {
      tag: 'button',
      attr: {
        title: 'Inspector'
      },
      class: ['as-from-tool-button', 'atr-inspector-btn'],
      child: 'span.mdi.mdi-auto-fix'
    }, {
      tag: 'a',
      class: 'atr-download-link',
      attr: {
        download: 'tutor_script.js'
      },
      style: {
        display: 'none'
      }
    }]
  });
  this.$importBtn = $('.atr-import-btn', this.$view).on('click', this.importFromFileDialog.bind(this));
  this.$editScriptBtn = $('.atr-edit-script-btn', this.$view).on('click', this.ev_clickEditScript.bind(this));
  this.$playBtn = $('.atr-play-btn', this.$view).on('click', this.ev_clickPlayBtn.bind(this));
  this.$stopBtn = $('.atr-stop-btn', this.$view).on('click', this.ev_clickStopBtn.bind(this));
  this.$stopBtn.disabled = true;
  this.$downloadBtn = $('.atr-download-btn', this.$view).on('click', this.downloadScript.bind(this));
  this.$downloadLink = $('a.atr-download-link', this.$view);
  this.$inspectorBtn = $('.atr-inspector-btn', this.$view).on('click', this.ev_clickInspectorBtn.bind(this));
  /***
   * @type {OnScreenWindow}
   */

  this.$editWindow = Core_('onscreenwindow').addStyle({
    width: this.config.editor.width + 'vw',
    height: this.config.editor.height + 'vh',
    left: this.config.editor.x + 'vw',
    top: this.config.editor.y + 'vh',
    visibility: 'hidden',
    opacity: '0'
  }).addClass('attr-split-editor-window');
  this.$editWindow.on('relocation', this.ev_editWindowPositionChange.bind(this)).on('sizechange', this.ev_editWindowPositionChange.bind(this));
  this.$editWindow.windowTitle = 'Tutor';
  this.$editWindow.addChild(this.splitEditor.getView());
  this.$editWindow.addTo(document.body);
  this.$editWindow.$closeBtn.on('click', this.ev_clickCloseScript.bind(this));
  this.splitEditor.setValue(this.script);
};

TutorMaster.prototype.importFromFileDialog = function () {
  var thisTM = this;
  Object(utils["openFileDialog"])({
    accept: ".js"
  }).then(function (files) {
    if (files.length > 0) {
      var fileReader = new FileReader();

      fileReader.onload = function (event) {
        thisTM.setScript(event.target.result);
      };

      fileReader.readAsText(files[0]);
    }
  });
};

TutorMaster.prototype.onResume = function () {
  document.body.classList.add('atr-has-tutor-master');
};

TutorMaster.prototype.onPause = function () {
  document.body.classList.remove('atr-has-tutor-master');
};

TutorMaster.prototype.onStart = function () {
  var view = this.getView();

  if (window.data_module && window.data_module.exportDatabase) {
    this.$databaseBtn = Core_({
      tag: 'button',
      attr: {
        title: 'ExportDatabase'
      },
      class: ['as-from-tool-button', 'atr-inspector-btn'],
      child: 'span.mdi.mdi-database',
      on: {
        click: window.data_module.exportDatabase.bind(window.data_module)
      }
    }).addTo(this.$view);
  }

  if (!view.parentElement) {
    view.addTo(document.body);
    var bound = view.getBoundingClientRect();
    view.addStyle({
      '--tutor-master-width': bound.width + 'px',
      '--tutor-master-height': bound.height + 'px'
    });
  }
};

TutorMaster.prototype.onDestroy = function () {
  this.$editWindow.remove();
};

TutorMaster.prototype.setScript = function (script) {
  this.script = script || '';
  this.splitEditor.setValue(this.script);
};

TutorMaster.prototype.downloadScript = function () {
  var thisTM = this;
  var blob = new Blob([this.splitEditor.getValue()], {
    type: 'text/plain'
  });
  thisTM.$downloadLink.href = URL.createObjectURL(blob);
  thisTM.$downloadLink.click();
};

TutorMaster.prototype.ev_clickEditScript = function () {
  if (this.$editScriptBtn.containsClass('as-active')) {
    this.$editScriptBtn.removeClass('as-active');
    this.$editWindow.addStyle('visibility', 'hidden');
    this.$editWindow.addStyle('opacity', '0');
  } else {
    this.$editWindow.removeStyle('visibility');
    this.$editWindow.addStyle('opacity', '1');
    this.$editScriptBtn.addClass('as-active');
  }
};

TutorMaster.prototype.ev_clickCloseScript = function () {
  if (this.$editScriptBtn.containsClass('as-active')) {
    this.$editScriptBtn.removeClass('as-active');
    this.$editWindow.addStyle('visibility', 'hidden');
    this.$editWindow.addStyle('opacity', '0');
  }
};

TutorMaster.prototype.ev_clickPlayBtn = function () {
  this.script = this.splitEditor.getValue();
  this.$editWindow.addStyle('visibility', 'hidden').addStyle('opacity', '0');
  this.$playBtn.disabled = true;

  var onFinish = function (err) {
    if (err instanceof Error) {
      var status = this.tutor.getStatus();
      Toast["a" /* default */].make({
        class: 'atr-toast-message',
        props: {
          variant: 'error',
          htitle: "Tutor Runtime Error!",
          disappearTimeout: 20000
        },
        child: [{
          tag: 'strong',
          child: {
            text: '[Ln ' + status.row + (status.col > 0 ? ', Col ' + status.col : '') + '] '
          }
        }, {
          tag: 'code',
          child: {
            text: status.code
          }
        }, {
          tag: 'div',
          child: {
            text: err.message
          }
        }]
      });
      console.error(err);
    } else if (typeof err === 'number' || err === undefined) {
      if (err === 0) {
        Toast["a" /* default */].make({
          props: {
            message: "Script finish successfully!",
            variant: 'success',
            htitle: "Success",
            disappearTimeout: 6000
          }
        });
      } else {
        Toast["a" /* default */].make({
          props: {
            message: 'Script is interrupted!',
            variant: 'warning',
            htitle: "",
            disappearTimeout: 6000
          }
        });
      }
    }

    this.$playBtn.disabled = false;
    this.$stopBtn.disabled = true;

    if (this.$editScriptBtn.containsClass('as-active')) {
      this.$editWindow.removeStyle('visibility').addStyle('opacity', '1');
    }

    this.tutor = null;
  }.bind(this);

  try {
    this.tutor = new js_Tutor(document.body, this.script);
    this.$stopBtn.disabled = false;
    return this.tutor.exec().then(onFinish).catch(onFinish);
  } catch (err) {
    this.$playBtn.disabled = false;

    if (this.$editScriptBtn.containsClass('as-active')) {
      this.$editWindow.removeStyle('visibility').addStyle('opacity', '1');
    }

    Toast["a" /* default */].make({
      props: {
        variant: 'error',
        htitle: 'Script Error!',
        message: err.message,
        disappearTimeout: 10000
      }
    });
    console.error(err);
    this.$stopBtn.disabled = true;
    this.tutor = null;
  }
};

TutorMaster.prototype.ev_clickStopBtn = function () {
  if (this.tutor) {
    this.tutor.stop();
  }
};

TutorMaster.prototype.ev_clickInspectorBtn = function () {
  if (this.$inspectorBtn.containsClass('as-active')) {
    this.$inspectorBtn.removeClass('as-active');
    this.inspector.stop();
  } else {
    this.$inspectorBtn.addClass('as-active');
    this.inspector.start();
  }
};

TutorMaster.prototype.ev_editWindowPositionChange = function () {
  var screenSize = Object(Dom["d" /* getScreenSize */])();
  var bound = this.$editWindow.getBoundingClientRect();
  this.config.editor.x = bound.left / screenSize.width * 100;
  this.config.editor.y = bound.top / screenSize.height * 100;
  this.config.editor.width = bound.width / screenSize.width * 100;
  this.config.editor.height = bound.height / screenSize.height * 100;
  this.saveConfig();
};

TutorMaster.prototype.ev_headerDragStart = function () {
  var bound = this.$view.getBoundingClientRect();
  var screenSize = Object(Dom["d" /* getScreenSize */])();
  this._headerDragData = {
    bound: bound,
    screenSize: screenSize,
    initPos: new Vec2["a" /* default */](bound.left, bound.top)
  };
};

TutorMaster.prototype.ev_headerDrag = function (event) {
  var d = event.currentPoint.sub(event.startingPoint);

  var newPos = this._headerDragData.initPos.add(d);

  var x = (newPos.x - 2) / (this._headerDragData.screenSize.width - this._headerDragData.bound.width - 4);
  var y = (newPos.y - 2) / (this._headerDragData.screenSize.height - this._headerDragData.bound.height - 4);
  x = Math.max(0, Math.min(0.98, x));
  y = Math.max(0, Math.min(0.98, y));
  this.$view.addStyle({
    '--tutor-master-x': x,
    '--tutor-master-y': y
  });
  this.config.toolbar.x = x;
  this.config.toolbar.y = y;
  this.saveConfig();
};

/* harmony default export */ var app_TutorMaster = (TutorMaster);
// CONCATENATED MODULE: ./js/index.js













/* harmony default export */ var js = ({
  FlagManager: app_FlagManager,
  Tutor: js_Tutor,
  runScriptFromUrl: runScriptFromUrl,
  SplitEditor: app_SplitEditor,
  TutorMaster: app_TutorMaster,
  findNode: findNode,
  UserBaseAction: scriptor_UserBaseAction,
  BaseCommand: scriptor_BaseCommand,
  TACData: scriptor_TACData,
  TutorNameManager: scriptor_TutorNameManager,
  expressionList: expressionList,
  Core: dom_Core,
  installToCore: install_install
});
// CONCATENATED MODULE: ./dev.js









install_install(absol.coreDom);
absol.tutor = js;
absol.FlagManager = app_FlagManager;
app_FlagManager.add('FLAG_MANAGER_STARTUP');
app_FlagManager.add('TUTOR_STARTUP');
Dom["b" /* default */].documentReady.then(function () {
  if (window.FLAG_MANAGER_STARTUP && window.self === window.top) app_FlagManager.start();

  if (window.TUTOR_STARTUP && window.self === window.top && !BrowserDetector["a" /* default */].isMobile) {
    var tutorMaster = new app_TutorMaster();
    tutorMaster.start();
  }
});

/***/ })
/******/ ]);

VaKeR 2022